3

I am trying to debug a C project in mint Linux using eclipse Galileo IDE. When I try to run the project in the DEBUG mode, the process terminates as it says- debugging information is missing.

In the eclipse console following messages appear

No source available for "main() " 

and 

Reading symbols from /home/project/netconf/target/bin/netconfd...(no debugging symbols found)...done. 

I am using the custom build command

make DEBUG=1 STATIC=1 [eclipse >project >properties > c/c++ build > builder settings]

it builds and runs fine in RELEASE mode.

I am able to build the same application using normal command line build using command terminal, using the same build options

> sudo make DEBUG=1 STATIC=1

now I can start a command line gdb session, as the debugging info is generated, but it is very difficult to debug that way.


I need to know if there is any other setting that needs to be changed, so that I can start debugging in eclipse.
Thanks in advance.

3
  • 1
    what error exactly are you getting? Commented May 9, 2012 at 12:06
  • I am getting a message "No source available for "main() " and in the console Reading symbols from /home/project/netconf/target/bin/netconfd...(no debugging symbols found)...done. Commented May 9, 2012 at 12:46
  • Is it CMake based project? I've noticed such behavior for CMake generated projects with default settings. I had to explicitly set CMAKE_DEBUG_TYPE to Debug before configuring and generating a project with cmake-gui. After that everything is fine in Eclipse CDT. Commented Dec 2, 2012 at 19:51

1 Answer 1

1

Add -d (or probably -g) to your command line. I think DEBUG=1 is defining a macro rather than generating debug info

Sign up to request clarification or add additional context in comments.

2 Comments

-g more likely, with maybe -DDEBUG
I have tried with both -g and -d , but still the debug info is not generated.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.