Build on Fedora core 3 on AMD64

Adrian Harvey ajharvey at myrealbox.com
Fri Feb 25 19:47:25 CST 2005


I am having trouble getting wine (latest CVS) to build on my AMD64 box
runngin Fedora core3, and I was hoping some autoconf wizard might be
able to help.  To begin at the beginning, the issue that occurs during
build is:

gcc -m32 -c -I. -I. -I../../include -I../../include -I/usr/X11R6/include
-D__WINESRC__   -D_REENTRANT -fPIC -Wall -pipe -mpreferred-stack-
boundary=2 -fno-strict-aliasing -gstabs+ -Wpointer-arith  -g -O2 -o
ddraw.dll.dbg.o ddraw.dll.dbg.c
.../../tools/winegcc/winegcc -B../../tools/winebuild -shared ./ddraw.spec
convert.o dclipper/main.o ddraw/hal.o ddraw/main.o ddraw/thunks.o
ddraw/user.o dpalette/hal.o dpalette/main.o dsurface/dib.o
dsurface/fakezbuffer.o dsurface/gamma.o dsurface/hal.o dsurface/main.o
dsurface/thunks.o dsurface/user.o dsurface/wndproc.o helper.o main.o
regsvr.o struct_convert.o  ddraw.dll.dbg.o version.res  -o ddraw.dll.so
-L../../dlls  -lole32 -luser32 -lgdi32 -ladvapi32 -lkernel32 -
L../../libs/wine -lwine -ldxguid -luuid  -L/usr/X11R6/lib64  -lXext -
lX11   -L../../libs/port -lwine_port 
/usr/bin/ld: skipping incompatible /usr/X11R6/lib64/libXext.so when
searching for -lXext
/usr/bin/ld: skipping incompatible /usr/X11R6/lib64/libXext.a when
searching for -lXext
/usr/bin/ld: cannot find -lXext
collect2: ld returned 1 exit status
winegcc: gcc failed.
make[2]: *** [ddraw.dll.so] Error 2
make[2]: Leaving directory `/home/adrian/wine/dlls/ddraw'
make[1]: *** [ddraw] Error 2
make[1]: Leaving directory `/home/adrian/wine/dlls'
make: *** [dlls] Error 2

So it seems that ld is finding the 64-bit version and failing to link
it.  It seems that the reason for this is that configure uses
xmkmf/imake to locate the X11 library directory and that this is always
returning the .../lib64 version.  I have split out the Imakefile that
configure generates, and tried various methods to prevent it seeing the
system as 64 bit and handing out the lib64 directory instead of the lib
one, but to no avail.

running:
setarch i386 imake -v -DUseInstalled -I/usr/X11R6/lib/X11/config
(to emulate an xmkmf, but with verbosity, which xmkmf doesn't do)
gives:
gcc -I. -D__amd64__ -D__amd64__ -traditional -Dlinux -DUseInstalled -
I/usr/X11R6/lib/X11/config -E -v Imakefile.c
Reading specs from /usr/lib/gcc/x86_64-redhat-linux/3.4.2/specs
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --
infodir=/usr/share/info --enable-shared --enable-threads=posix --
disable-checking --with-system-zlib --enable-__cxa_atexit --disable-
libunwind-exceptions --enable-languages=c,c++,objc,java,f77 --enable-
java-awt=gtk --host=x86_64-redhat-linux
Thread model: posix
gcc version 3.4.2 20041017 (Red Hat 3.4.2-6.fc3)
 /usr/libexec/gcc/x86_64-redhat-linux/3.4.2/cc1 -E -traditional-cpp -
quiet -v -I. -I/usr/X11R6/lib/X11/config -D__amd64__ -D__amd64__ -Dlinux
-DUseInstalled Imakefile.c -mtune=k8
ignoring nonexistent directory "/usr/lib/gcc/x86_64-redhat-
linux/3.4.2/../../../../x86_64-redhat-linux/include"
#include "..." search starts here:
#include <...> search starts here:
 .
 /usr/X11R6/lib/X11/config
 /usr/local/include
 /usr/lib/gcc/x86_64-redhat-linux/3.4.2/include
 /usr/include
End of search list.

I can see that gcc is being passed -D__amd64__ but I can't trace where
this is coming from... 

Am I hunting on the right lines, or is there somthing much simpler I
have missed?  Also, what do we need to change in the autoconf stuff to
allow wine to build correctly on x86_64 multi-arch systems? (assuming
that it is not just my system being broken somehow)

Thanks for any help,
	Adrian





More information about the wine-devel mailing list