cannot debug root process

General questions regarding the usage of CodeLite
liqing
CodeLite Curious
Posts: 1
Joined: Tue Oct 21, 2014 4:53 am
Genuine User: Yes
IDE Question: c++
Contact:

cannot debug root process

Post by liqing »

when I using 5.4 version, I can debug root programe by reference "http://codelite.org/LiteEditor/Debugging"
chmod u+s /usr/bin/gdb, but when i Upgrade 6.1 version, it is not work. when I start program I got an error:

here is debug output:

Code: Select all

DEBUG>>00000014^done,bkpt={number="6",type="breakpoint",disp="keep",enabled="y",addr="0x000000000047a0bc",func="_on_segment_end_cb",file="task/task.c",fullname="/home/li/workspace/mv.git/mv_daemon/xvs/task/task.c",line="698",thread-groups=["i1"],times="0",original-location="/home/li/workspace/mv.git/mv_daemon/xvs/task/task.c:698"}
Found the breakpoint ID!
Storing debugger breakpoint Id=6
Successfully set breakpoint 6 at: /home/li/workspace/mv.git/mv_daemon/xvs/task/task.c:698
DEBUG>>00000015^done
[color=#FF0000]DEBUG>>&"/tmp/pts29: Permission denied.[/color]\n"
>> Debuggee process ID: 11359
DEBUG>>=thread-group-started,id="i1",pid="11359"
=thread-group-started,id="i1",pid="11359"
DEBUG>>=thread-created,id="1",group-id="i1"
=thread-created,id="1",group-id="i1"
DEBUG>>=thread-exited,id="1",group-id="i1"
=thread-exited,id="1",group-id="i1"
DEBUG>>=thread-group-exited,id="i1"
=thread-group-exited,id="i1"
DEBUG>>00000016^error,msg="During startup program exited with code 1."
[color=#FF0000]Debug session ended
During startup program exited with code 1.[/color]
version 6.0 is same, 5.4 don't have the problem. please help me.
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: cannot debug root process

Post by eranif »

Thanks for reporting this. This is now fixed in git master.

For now, you will need to remove the 'suid' bit from your /usr/bin/gdb
and instead, launch another instance of codelite (under root) for debugging purposes

Another solution will be to build codelite from sources according to this:
http://codelite.org/Developers/Linux

Eran
Make sure you have read the HOW TO POST thread
Post Reply