[Fwd: Re: [Fwd: Linker problems]]

Ian Lance Taylor iant@google.com
Sat Apr 17 17:53:00 GMT 2010


"Andrei B" <baie0668@scs.ubbcluj.ro> writes:

> ld -T link.ld -o kernel.bin start.o main.o scrn.o gdt.o idt.o isrs.o irq.o
> timer.o kb.o

> start.o is assembled by NASM and is a:
> start.o: Linux/i386 impure executable (OMAGIC)
> All other objects compiled with GCC.

I suppose I don't see how this could work.  The linker is only able to
link object files, not executable files.  I've never looked at NASM in
detail; does it have any option to emit an object file rather than an
executable file?  Why is NASM involved here anyhow?

Ian



More information about the Binutils mailing list