Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » Debug DLL loaded by external application
Debug DLL loaded by external application [message #1798794] Sun, 25 November 2018 12:50 Go to next message
Jochen Woidich is currently offline Jochen WoidichFriend
Messages: 2
Registered: November 2018
Junior Member
Hi all,

I'm trying to debug a DLL loaded as a plugin by an external application, but breakpoints don't work.

The DLL is build from source with a Makefile in my workspace using the MinGW GCC toolchain (provided via MSYS2/MinGW64). It compiles without optimizations and contains debugging symbols (gcc -I.. -O0 -g ..)

I've imported the external application as existing C++ Application, added my plugin project as project reference and created a launch configuration that passes my plugin as argument.

Starting the application this way is fine and I can see my plugin working, but setting breakpoints in my plugin code doesn't work. In the debugger console I can see:
Thread 17 received signal SIGINT, Interrupt.
[Switching to Thread 7452.0x21dc]
0x0000000076c74bf2 in KERNEL32!CtrlRoutine () from C:\Windows\system32\kernel32.dll
No symbol table is loaded.  Use the "file" command.
[Thread 7452.0x21dc exited with code 0]

Any hints?

Workspace:
MyPlugin (Makefile project)

ExternalApplicaion (C++ Application)
  Project References: MyPlugin
  Launch Config: 
    C/C++ Application: ExternalApp.exe
    Arguments: MyPlugin.dll
    Working Dir: Build Directory of MyPlugin


Versions:

Eclipse IDE for C/C++ Developers
Version: 2018-09 (4.9.0)
Build id: 20180917-1800

$ gdb --version
GNU gdb (GDB) 8.2

$ gcc --version
gcc.exe (Rev3, Built by MSYS2 project) 8.2.0
Re: Debug DLL loaded by external application [message #1798940 is a reply to message #1798794] Tue, 27 November 2018 17:24 Go to previous message
Jochen Woidich is currently offline Jochen WoidichFriend
Messages: 2
Registered: November 2018
Junior Member
Hello,

This turned out to be a bug in the makefile. The linker stripped out the symbol table even when compiling in debug (-s was passed)

D'oh!
Previous Topic:Unable to start language server: C/C++ Language Server
Next Topic:Arduino ESP32 project can not be build
Goto Forum:
  


Current Time: Fri Apr 19 20:39:12 GMT 2024

Powered by FUDForum. Page generated in 0.03164 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top