I'm trying to use Eclipse with CDT to debug a 64 bit binary. The binary is built outside of Eclipse, and runs fine. I start up the binary outside of eclipse, and then attempt to attach to the process using the 'C/C++ Attach to Application' debug configuration type.
I can choose the process from the list that pops up when you run the debug configuration, however, I get the following error message:
Error in final launch sequence
Failed to execute MI command:
attach 22014
Error message from debugger back end:
"program.x64": not in executable format: File format not recognized
Everything works fine if I build for an i386 target.
I'm not quite sure where to go with this, I've read that it might have something to do with the binary parsers in Eclipse:
This link mentions parsers, and this link describes a bug with the PE parser that is fixed.
I am running Eclipse Indigo with Eclipse CDT 8.0.0 on Linux x64. I have tried the 'Elf Parser' and 'GNU Elf Parser' under project_properties/c++_build/settings with no luck.
File information:
hostmachinea:file program.x64
programs.x64: ELF 64-bit LSB executable, AMD x86-64, version 1 (SYSV), for GNU/Linux 2.6.9, dynamically linked (uses shared libs), for GNU/Linux 2.6.9, not stripped
GDB and gdbinit files are the Eclipse defaults