Strange error: incompatible with i386 output

Chad J gamerChad at _spamIsBad_gmail.com
Fri Apr 25 22:38:07 PDT 2008


I am trying to get D working on my latest Linux install, but I am 
running into this error.


module main;

import tango.io.Stdout;

void main()
{
         Stdout("Hello world!").newline;
}

Trying to compile it:
<chad|~/c/dprojects/test> rebuild main.d
gcc ./_main.o -o main -m32 -Xlinker --start-group -ltango-base-dmd 
-lDD-tango-io -lDD-tango-sys -lDD-tango-stdc -lDD-tango-sys-linux 
-lDD-tango-stdc -lDD-tango-io -lDD-tango-text -lDD-tango-io -Xlinker 
-L/usr/lib -Xlinker -L/usr/lib -ltango-base-dmd -lpthread -lm
collect2: ld terminated with signal 11 [Segmentation fault]
/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.2/../../../../x86_64-pc-linux-gnu/bin/ld: 
i386:x86-64 architecture of input file 
`/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.2/../../../libtango-base-dmd.a(monitor.o)' 
is incompatible with i386 output
/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.2/../../../../x86_64-pc-linux-gnu/bin/ld: 
i386:x86-64 architecture of input file 
`/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.2/../../../libtango-base-dmd.a(critical.o)' 
is incompatible with i386 output
--- errorlevel 1

Has anyone else run into this?

I am running a 64bit OS on a 64bit processor, but it has 32 bit 
emulation and all of this should be done in that.  I am not trying to 
compile 64 bit programs.  This compilation should be done with DMD 
1.027, and Tango was compiled with DMD 1.027.

Given Tango was compiled by DMD, I find it odd that gcc/ld would be 
saying that the tango libs are 64bit files.


More information about the Digitalmars-d-learn mailing list