GDB and 64-bit executable

General questions regarding the usage of CodeLite
foxmuldr
CodeLite Expert
Posts: 120
Joined: Sun May 10, 2009 6:56 am
Contact:

GDB and 64-bit executable

Post by foxmuldr »

I have a project I've created which uses MinGW-w64-4.9.2. When I compile it and go to run it in Codelite I get the error:

Code: Select all

Debugger exited with the following error string:
"No executable specified, use 'target exec'."
When I use the same settings for a 32-bit build using MinGW 4.8.1 with it works properly.

Is there something special I need to do to debug 64-bit programs in Codelite with GDB?

You can see my project settings and what I'm doing by cloning this repository to c:\, and then loading this project:

Code: Select all

C:\WINDOWS> cd \
C:\> git clone https://github.com/RickCHodgin/libsf.git libsf

// And then open:
C:\libsf\source\vjr\projects\mingw_gcc_codelite\vjr64.workspace
If you try to compile it you'll need to create the output directory structure (at least C:\libsf_offline\source\vjr\bin\64-bit) and possibly others, or to install other software. I'm not sure of its current "new install and compile" stability (as I appear to be the only one using this project it hasn't been an issue to date :-)).

Thank you in advance for any assistance.
Best regards,
Rick C. Hodgin
www.Visual-FreePro.org
www.LibSF.org
foxmuldr
CodeLite Expert
Posts: 120
Joined: Sun May 10, 2009 6:56 am
Contact:

Re: GDB and 64-bit executable

Post by foxmuldr »

Okay ... I was able to get it to launch by changing the debugger to:

Code: Select all

c:\mingw-w64-4.9.2\mingw64\bin\gdb.exe
When it launches now it immediate throws:

Code: Select all

Program received signal
SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
Program Received signal SIGSEGV
Not sure the cause. In 32-bit GCC it works properly, and in 32-bit and 64-bit Visual Studio 2010 compilations. 64-bit g++ doesn't throw any errors, and only one warning which is a non-issue.

Any advice is appreciated. Thank you in advance.
Best regards,
Rick C. Hodgin
www.Visual-FreePro.org
www.LibSF.org
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: GDB and 64-bit executable

Post by eranif »

Like I mentioned in another post this is now fixed in git head
Eran
Make sure you have read the HOW TO POST thread
foxmuldr
CodeLite Expert
Posts: 120
Joined: Sun May 10, 2009 6:56 am
Contact:

Re: GDB and 64-bit executable

Post by foxmuldr »

eranif wrote:Like I mentioned in another post this is now fixed in git head
Eran
Does this mean the 64-bit signal fault I was getting was due to something in Codelite and not the result of my code, or compiler or gdb settings?
Best regards,
Rick C. Hodgin
www.Visual-FreePro.org
www.LibSF.org
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: GDB and 64-bit executable

Post by eranif »

foxmuldr wrote:Does this mean the 64-bit signal fault I was getting was due to something in Codelite and not the result of my code, or compiler or gdb settings?
No, this means that codelite (in git master) will detect the proper gdb so you wont need to alter your settings to switch gdb(s)

Eran
Make sure you have read the HOW TO POST thread
foxmuldr
CodeLite Expert
Posts: 120
Joined: Sun May 10, 2009 6:56 am
Contact:

Re: GDB and 64-bit executable

Post by foxmuldr »

eranif wrote:No, this means that codelite (in git master) will detect the proper gdb so you wont need to alter your settings to switch gdb(s)
Eran
Well ... there was always hope. :-)

BTW, I think Codelite looks really fantastic. You're doing excellent work, Eran.
Best regards,
Rick C. Hodgin
www.Visual-FreePro.org
www.LibSF.org
Post Reply