Page 1 of 1
Debugger error: could not launch terminal for debugger
Posted: Wed Sep 21, 2016 1:10 pm
by derkomai
Hi everyone. I'm using CodeLite 9.2.0 over elementary OS 0.4 Loki (based on Ubuntu 16.04) and I seem unable to make the debugger work since updated to this version of CodeLite. Even for the simplest project: I create a new project on the workspace and try to debug the Hello World basic example that is included in it. Once I launch the debugger, ColdeLite seems not to respond for several seconds and then I get the message "could not launch terminal for debugger". The code can be build and run without any issue, but not the debugger. I can even debug with gdb (version 7.11.1) from terminal.
So far I've tried enabling the debugger log with no result and checked that the -g option is added in the debug configuration as seen here:
http://stackoverflow.com/questions/1271 ... n-codelite.
Anyone can point me in the right direction? Thank you.
Edit: I've also noticed that the keyboard shortcut I've assigned to "start debuger" is not working. Every other shortcut I configured work flawlessly.
Re: Debugger error: could not launch terminal for debugger
Posted: Wed Sep 21, 2016 4:55 pm
by DavidGH
Hi,
I seem unable to make the debugger work since updated to this version of CodeLite
Which version were you previous using?
The common reason for this is not having a suitable terminal installed e.g. konsole or xterm. Try installing xterm if it isn't already.
Regards,
David
Re: Debugger error: could not launch terminal for debugger
Posted: Wed Sep 21, 2016 8:19 pm
by derkomai
I'm not entirely sure but I think it was 9.1 or 9.0. But i fresh installed my OS so I downloaded the latest stable. Xterm is already installed. Any recommendation on which console should I be using in Settings->Preferences->Terminal? I've tried both Codelite built in terminal emulator and codelite_xterm.
Re: Debugger error: could not launch terminal for debugger
Posted: Wed Sep 21, 2016 10:56 pm
by DavidGH
But i fresh installed my OS
I see, so it's more likely to be that than the CodeLite version change.
which console should I be using in Settings->Preferences->Terminal?
IIRC that's to do with running your program in a terminal, not debugging it.
I suspect that Loki's default terminal is one that will not work in this situation. To find out what it is, please post the output of doing, in a terminal:
sudo update-alternatives --config x-terminal-emulator
If that is not set to xterm, try following the instructions to change it. While xterm isn't my favourite terminal, it's known to work here.
Re: Debugger error: could not launch terminal for debugger
Posted: Thu Sep 22, 2016 11:29 am
by derkomai
I think you nailed it!
The output for "sudo update-alternatives --config x-terminal-emulator" is:
Selección Ruta Prioridad Estado
------------------------------------------------------------
* 0 /usr/lib/user-specific-alternatives/user-specific-alternatives 500 modo automático
1 /usr/bin/koi8rxterm 20 modo manual
2 /usr/bin/lxterm 30 modo manual
3 /usr/bin/pantheon-terminal 35 modo manual
4 /usr/bin/uxterm 20 modo manual
5 /usr/bin/xterm 20 modo manual
6 /usr/lib/user-specific-alternatives/user-specific-alternatives 500 modo manual
It was set as indicated. Once I set it to xterm, the debugger started working. Thank you!
Re: Debugger error: could not launch terminal for debugger
Posted: Fri Oct 14, 2016 8:35 pm
by Xin
I have the same problem with Kubuntu 16.04 and KDE:
I previously used the version delivered with ubuntu. After that I downloaded the weekly build today which version is 9.2.5.
Code: Select all
xin@trinity:~$ sudo update-alternatives --config x-terminal-emulator
Es gibt 6 Auswahlmöglichkeiten für die Alternative x-terminal-emulator (welche /usr/bin/x-terminal-emulator bereitstellen).
Auswahl Pfad Priorität Status
------------------------------------------------------------
0 /usr/bin/konsole 40 automatischer Modus
1 /usr/bin/gnome-terminal.wrapper 40 manueller Modus
2 /usr/bin/koi8rxterm 20 manueller Modus
* 3 /usr/bin/konsole 40 manueller Modus
4 /usr/bin/lxterm 30 manueller Modus
5 /usr/bin/uxterm 20 manueller Modus
6 /usr/bin/xterm 20 manueller Modus
Drücken Sie die Eingabetaste, um die aktuelle Wahl[*] beizubehalten,
oder geben Sie die Auswahlnummer ein: 6
update-alternatives: /usr/bin/xterm wird verwendet, um /usr/bin/x-terminal-emulator (x-terminal-emulator) im manuellen Modus bereitzustellen
Using xterm helps me to start the debugger.