SDL2 and Codelite GDB

CodeLite installation/troubleshooting forum
CodeLite Enthusiast
Posts: 23
Joined: Fri Mar 23, 2018 7:12 am
Genuine User: Yes
IDE Question: C++

SDL2 and Codelite GDB

Post by shadoww »

Linux Mint

There has been then bug where when after running GDB to debug a SDL2 application my window manger stops working correctly or I get blank SDL2 windows. I finally narrowed down to Codelite its self.
I originally thought it was compiz but after trying on KDE and seeing the same bug I was just amazed.

When it does NOT happen:

  1. If XFCE is doing the window composition aka no 3d this bug does not happen. I like wobbly windows to much.
  2. If running GDB under clion this bug does NOT happen.
  3. Also does not happen under nvim, this was hard to test...
  4. If running LLDB debugger under codelite it also does NOT happen.
  5. If just running GDB from the command line it doe NOT happen.

It seems like Codelite is interfering with SDL2 somehow when initializing the window when debugging under GDB.
How to reproduce (one of the most annoying bugs to reproduce)

  1. It will not happen right away, you have to keep rerunning the debugger for about 20 minutes. (just hit f5 over and over) This would be same as developing something for a few days.
  2. The source code: ... /index.php
  3. Just keep running and eventually a blank window will appear or no window. and when you try to debug it again it will work for awhile then after a few more debugs it will not but once you hit this first occurrence it seems to be easier to reporduce.

This is a very annoying bug because it crashed KDE and Compiz will eventually become non functioning but handles it better than KDE.