$ gcc -o first asm_io.o first.o /usr/bin/ld: i386 architecture of input file `asm_io.o' is incompatible with i386:x86-64 output /usr/bin/ld: i386 architecture of input file `first.o' is incompatible with i386:x86-64 output /usr/lib/gcc/x86_64-linux-gnu/4.3.2/../../../../lib/crt1.o: In function `_start': (.text+0x20): undefined reference to `main' collect2: ld returned 1 exit status
What is the problem here? I assembled first.o using NASM on an x86-64 machine. My computer has an AMD64 processor, which uses x86-64. How can I get it to assemble into an x86-64 format? My NASM docs don't address this issue.


Sign In
Create Account


Back to top









