Page 1 of 1

CodeLite Failed to locate gdb

Posted: Wed Jun 03, 2009 1:54 am
by Pecan
Image

I cannot figure out why CodeLite cannot find gdb.exe event when I navigate to it via the debugger dialog.

Image

When CodeLite is sitting at c:\usr\proj\CodeLite\CodeLite.exe, I get the error message.(version 2847)

If I execute from c:\user\programs\CodeLite\CodeLite.exe I do *not* get the message.(version 2785)

Image

Windows XP SP2, CodeLite 2847

What am I missing here?
Path is

Thanks in advance

Re: CodeLite Failed to locate gdb

Posted: Wed Jun 03, 2009 11:43 am
by eranif
Hi Pecan!

The message 'Failed to locate the ...' is coming from a source file named exelocator.cpp, which uses the 'which' command to locate an executabled. I suspect that you have another version of which.exe on your machine which produces a different output than the one codelite expects.

When you open a CMD.EXE and type 'which gdb' - what is the output that you receive?

Note: codelite installs a which.exe at the installation directory

Eran

Re: CodeLite Failed to locate gdb

Posted: Wed Jun 03, 2009 2:52 pm
by Pecan
eranif wrote:Hi Pecan!

The message 'Failed to locate the ...' is coming from a source file named exelocator.cpp, which uses the 'which' command to locate an executabled. I suspect that you have another version of which.exe on your machine which produces a different output than the one codelite expects.

When you open a CMD.EXE and type 'which gdb' - what is the output that you receive?

Note: codelite installs a which.exe at the installation directory

Eran
That's it. I had which.exe version 2.4 in the path ahead of CodeLite which.exe version 2.16.

Code: Select all

C:\>which --version
GNU which v2.4, Copyright (C) 1999 Carlo Wood.
GNU which comes with ABSOLUTELY NO WARRANTY;
This program is free software; your freedom to use, change
and distribute this program is covered by the GPL.

C:\>
C:\>
C:\>cd \user\Programs\CodeLite

C:\User\Programs\CodeLite>which --version
GNU which v2.16, Copyright (C) 1999 - 2003 Carlo Wood.
GNU which comes with ABSOLUTELY NO WARRANTY;
This program is free software; your freedom to use, change
and distribute this program is protected by the GPL.

C:\User\Programs\CodeLite>cd \usr\mingw345\bin

C:\Usr\mingw345\bin>which gdb.exe
C:/Usr/mingw345/bin/gdb.exe

C:\Usr\mingw345\bin>cd \user\Programs\CodeLite

C:\User\Programs\CodeLite>which c:\usr\mingw345\bin\gdb.exe
c:/usr/mingw345/bin/gdb.exe

C:\User\Programs\CodeLite>cd \

C:\>which c:\usr\mingw345\bin\gdb.exe
which: no gdb.exe in (./c:\usr\mingw345\bin)
Thanks

Re: CodeLite Failed to locate gdb

Posted: Wed Jun 03, 2009 3:02 pm
by eranif
Also, I added a fix to the 'execlocator.cpp' file so in case a full path is provided, it will only check that the file actually exists rather then using the WHICH command ( not committed yet )

Eran