Debugger on windows 7 not working

CodeLite installation/troubleshooting forum
joecode
CodeLite Curious
Posts: 5
Joined: Sat Jul 16, 2016 3:37 am
Genuine User: Yes
IDE Question: c++
Contact:

Debugger on windows 7 not working

Post by joecode »

Am getting lost trying to make the debugger work. Just installed the latest version hoping that would help but didn't do anything. I'm looking at Settings->GDB Settings thinking something in here not configured right. But I don't know what that might be. Please see attached. Is there some kind of detailed logging get turned onto shed some light? Thanks for any help.

Win7 Professional 64 bit Service Pack1; CodeLite IDE 9.2.0

Am able to run a simple program but when I set a breakpoint and run the debugger F5 something is happening but it's not breaking.

Code: Select all

int main() {
    time_t now = time(0);
    char* dt = ctime(&now);
    std::cout << "The local date and time is: " << dt << std::endl;
}
Debug build

Code: Select all

C:\Windows\system32\cmd.exe /C C:/TDM-GCC-64/bin/mingw32-make.exe -j4 SHELL=cmd.exe -e -f  Makefile
"----------Building project:[ PassString2 - Debug ]----------"
mingw32-make.exe[1]: Entering directory 'C:/Users/joe/Documents/CodeLite1/PassString2'
C:/TDM-GCC-64/bin/g++.exe -o ./Debug/PassString2 @"PassString2.txt" -L.
mingw32-make.exe[1]: Leaving directory 'C:/Users/joe/Documents/CodeLite1/PassString2'
====0 errors, 0 warnings====
After a few seconds a WerFault.exe window pops up:
[Window Title]
gdb.exe
[Main Instruction]
gdb.exe has stopped working
[Content]
A problem caused the program to stop working correctly. Windows will close the program and notify you if a solution is available.

Path to gdb.exe C:\Program Files\TDM-GCC-64\bin\gdb.exe

Here is process tree when the WerFault.exe pops up:

Code: Select all

Name                             Pid Pri Thd  Hnd      VM      WS    Priv
  codelite                      9556   8  29  446  368852   88048   49624
    node                        6668   8   8  177   96372   24308   21460
    codelite_indexer           10196   8   3   76   83768    6668    2672
    gdb                        10576   8   1   44    9172    2084     828
      gdb                       8176   8   3   96  123816   21096   15672
        PassString2             1508   8   1   43   10272    1916     444
You do not have the required permissions to view the files attached to this post.
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Debugger on windows 7 not working

Post by eranif »

Looks like your GDB crashed... I am not sure what can we do about it
Which build of GCC are you using? ( I am using TDM-GCC-4.9.3/64 bit)

Eran
Make sure you have read the HOW TO POST thread
joecode
CodeLite Curious
Posts: 5
Joined: Sat Jul 16, 2016 3:37 am
Genuine User: Yes
IDE Question: c++
Contact:

Re: Debugger on windows 7 not working

Post by joecode »

Hopefully there has been no offense by this very long delay in a response. Or at most just a slight offense? Had too many other projects going on at once.

Version is tdm64-gcc-5.1.0-2.exe from http://tdm-gcc.tdragon.net/download.

Was hoping for find a lightweight compiler for C++ learning.
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Debugger on windows 7 not working

Post by eranif »

joecode wrote:Hopefully there has been no offense by this very long delay in a response
Non taken

Did you try using a different version of GCC?

Eran
Make sure you have read the HOW TO POST thread
joecode
CodeLite Curious
Posts: 5
Joined: Sat Jul 16, 2016 3:37 am
Genuine User: Yes
IDE Question: c++
Contact:

Re: Debugger on windows 7 not working

Post by joecode »

Gave it a try with
https://sourceforge.net/projects/tdm-gc ... e/download but still same results.

MIght have missed something with the CodeLite where a re-configuration is needed after uninstalling and reinstalling the debugger.
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Debugger on windows 7 not working

Post by eranif »

Once you install a new compiler, you need to "tell" CodeLite about it from:
Settings->Build Settings, and click on the "Scan for new compilers on this machine" button

CodeLite should pick you new compiler.

Next, right click on the project settings->general page, and under "Compiler" field, select the newly installed compiler.
(The gdb is part of the compiler toolchain, so when changing the compiler for the project you are also changing the compiler that it will use)

Eran
Make sure you have read the HOW TO POST thread
joecode
CodeLite Curious
Posts: 5
Joined: Sat Jul 16, 2016 3:37 am
Genuine User: Yes
IDE Question: c++
Contact:

Re: Debugger on windows 7 not working

Post by joecode »

Uninstalled CodeLite and GCC and then reinstalled both. When running in debug it hangs for about 15 seconds then dies. No visible feedback that something went wrong. Took a look at eventviewer and saw lots of errors. I'm thinking these errors were being logged all along. It says something about the exception happening at offset 00000000001ecd1f.

My machine has a full blown C++ Visual Studio 2015 on it. Maybe this is messing up the CodeLite debugger? I originally tried working with VS 2015 C++ IDE but it was just too confusing to figure out how to make a simple stripped down bare bones C++ program.

##### EVENTVIEWER #####
Fault bucket , type 0
Event Name: APPCRASH
Response: Not available
Cab Id: 0

Problem signature:
P1: gdb.exe
P2: 0.0.0.0
P3: 6c6c6163
P4: gdb.exe
P5: 0.0.0.0
P6: 6c6c6163
P7: 40000015
P8: 00000000001ecd1f
P9:
P10:

Attached files:

These files may be available here:
C:\Users\joe\AppData\Local\Microsoft\Windows\WER\ReportQueue\AppCrash_gdb.exe_488fc55ace39d56fe7860c131af36be5457891_43284460

### CONTENTS OF THE CRASH FILE:
### AppCrash_gdb.exe_488fc55ace39d56fe7860c131af36be5457891_43284460
Version=1
EventType=APPCRASH
EventTime=131147461379242752
ReportType=2
Consent=1
UploadTime=131147461379562770
ReportIdentifier=16590d3d-59df-11e6-9990-c81f660f1bc6
IntegratorReportIdentifier=16590d3c-59df-11e6-9990-c81f660f1bc6
Response.type=4
Sig[0].Name=Application Name
Sig[0].Value=gdb.exe
Sig[1].Name=Application Version
Sig[1].Value=0.0.0.0
Sig[2].Name=Application Timestamp
Sig[2].Value=6c6c6163
Sig[3].Name=Fault Module Name
Sig[3].Value=gdb.exe
Sig[4].Name=Fault Module Version
Sig[4].Value=0.0.0.0
Sig[5].Name=Fault Module Timestamp
Sig[5].Value=6c6c6163
Sig[6].Name=Exception Code
Sig[6].Value=40000015
Sig[7].Name=Exception Offset
Sig[7].Value=00000000001ecd1f
DynamicSig[1].Name=OS Version
DynamicSig[1].Value=6.1.7601.2.1.0.256.48
DynamicSig[2].Name=Locale ID
DynamicSig[2].Value=1033
DynamicSig[22].Name=Additional Information 1
DynamicSig[22].Value=a953
DynamicSig[23].Name=Additional Information 2
DynamicSig[23].Value=a953ee83a28be1f063cea55833098379
DynamicSig[24].Name=Additional Information 3
DynamicSig[24].Value=a4a5
DynamicSig[25].Name=Additional Information 4
DynamicSig[25].Value=a4a5cd3a76722c4efabf27f81c461678
UI[2]=C:\TDM-GCC-64\gdb64\bin\gdb.exe
UI[3]=gdb.exe has stopped working
UI[4]=Windows can check online for a solution to the problem.
UI[5]=Check online for a solution and close the program
UI[6]=Check online for a solution later and close the program
UI[7]=Close the program
LoadedModule[0]=C:\TDM-GCC-64\gdb64\bin\gdb.exe
LoadedModule[1]=C:\Windows\SYSTEM32\ntdll.dll
LoadedModule[2]=C:\Windows\system32\kernel32.dll
LoadedModule[3]=C:\Windows\system32\KERNELBASE.dll
LoadedModule[4]=C:\TDM-GCC-64\gdb64\bin\python27.dll
LoadedModule[5]=C:\Windows\system32\USER32.dll
LoadedModule[6]=C:\Windows\system32\GDI32.dll
LoadedModule[7]=C:\Windows\system32\LPK.dll
LoadedModule[8]=C:\Windows\system32\USP10.dll
LoadedModule[9]=C:\Windows\system32\msvcrt.dll
LoadedModule[10]=C:\Windows\system32\ADVAPI32.dll
LoadedModule[11]=C:\Windows\SYSTEM32\sechost.dll
LoadedModule[12]=C:\Windows\system32\RPCRT4.dll
LoadedModule[13]=C:\Windows\system32\SHELL32.dll
LoadedModule[14]=C:\Windows\system32\SHLWAPI.dll
LoadedModule[15]=C:\Windows\WinSxS\amd64_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.6161_none_08e61857a83bc251\MSVCR90.dll
LoadedModule[16]=C:\Windows\system32\WS2_32.dll
LoadedModule[17]=C:\Windows\system32\NSI.dll
LoadedModule[18]=C:\Windows\system32\IMM32.DLL
LoadedModule[19]=C:\Windows\system32\MSCTF.dll
LoadedModule[20]=C:\Windows\system32\psapi.dll
LoadedModule[21]=C:\Windows\system32\apphelp.dll
FriendlyEventName=Stopped working
ConsentKey=APPCRASH
AppName=gdb.exe
AppPath=C:\TDM-GCC-64\gdb64\bin\gdb.exe
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Debugger on windows 7 not working

Post by eranif »

You should report this to the GDB team, it's useless to report it here

Eran
Make sure you have read the HOW TO POST thread
joecode
CodeLite Curious
Posts: 5
Joined: Sat Jul 16, 2016 3:37 am
Genuine User: Yes
IDE Question: c++
Contact:

Re: Debugger on windows 7 not working

Post by joecode »

Ok will see if I can taker it to GDB team. Thanks for your responses.
Post Reply