Author Topic: Having problem linking debugable files  (Read 16807 times)

nobody

  • Guest
Having problem linking debugable files
« on: September 27, 2007, 12:59:54 AM »
I am using the following commands to make a debugable object file with NASM

nasm -t -g -f elf64 FILE.asm

I then use the following command to link my main c program with the NASM debugable object file.

gcc -g main.c FILE.o

..and I get the following error message from the linker:

/usr/bin/ld: FILE.o(.stab+0x0): Stabs entry has invalid string index.
FILE.o: could not read symbols: Bad value
collect2: ld returned 1 exit status

I was wondering what I am doing wrong and how to fix it. Any help would be greatly appreciated.

Chris