Page 1 of 1

ld of gcc 64

Posted: Sun Jun 07, 2009 7:47 pm
by digo_rp
at my attemp of compile digos, I got this error, how do I compile my digos of 32bits kernel using 64 bits gcc under ubuntu 9.04 64bits ?

ld: i386 architecture of input file `strtoul.o' is incompatible with i386:x86-64 output
ld: i386 architecture of input file `pci32.o' is incompatible with i386:x86-64 output
ld: i386 architecture of input file `cmd.o' is incompatible with i386:x86-64 output
ld: i386 architecture of input file `svga.o' is incompatible with i386:x86-64 output
ld: i386 architecture of input file `svgalib.o' is incompatible with i386:x86-64 output
ld: i386 architecture of input file `gui.o' is incompatible with i386:x86-64 output
ld: i386 architecture of input file `guiapp1.o' is incompatible with i386:x86-64 output
ld: i386 architecture of input file `dia.o' is incompatible with i386:x86-64 output
ld: i386 architecture of input file `kstart.o' is incompatible with i386:x86-64 output
ld: i386 architecture of input file `lib.o' is incompatible with i386:x86-64 output
ld: i386 architecture of input file `pci32a.o' is incompatible with i386:x86-64 output
?? any help please?

Re: ld of gcc 64

Posted: Sun Jun 07, 2009 9:48 pm
by Troy Martin
-m32

EDIT: specifically on GCC.

Re: ld of gcc 64

Posted: Mon Jun 08, 2009 2:56 am
by pcmattman

Re: ld of gcc 64

Posted: Mon Jun 08, 2009 7:44 am
by whowhatwhere
For any multilib setup, CFLAGS += -m32 and LDFLAGS += -m elf_i386. This will compile correctly.
Otherwise you will need a crosscompiler.