linux-sparc to linux-sparc64 cross compiler
Sean Callanan
sc843@bard.edu
Fri Mar 16 00:40:00 GMT 2001
Dear mailing list,
On March 14th, I downloaded the latest CVS of GNU binutils, GCC, and glibc.
I have tried to compile binutils, with great success. I configured it just
as in the crossgcc-HOWTO, with $PREFIX=/usr/local.
However, gcc has more difficulties, and it seems to be a problem with the
linker. Exact error messages are shown at the end of this message.
This is a disturbing (!) set of error messages. Specifically, since when
did we need libc.so.6? According to cross-gcc-HOWTO, glibc is built after
gcc! But that may not be the problem. I noticed that the only parameter to
the last xgcc command that even mentions libc is [-Dinhibit_libc], which
indicated to me that someone knew libc would cause a problem. However, this
message didn't get through to sparc64-linux-ld, and therein (I would guess)
lies the problem.
I run a Sun Ultra 5 under Linux. The standard gcc is 2.95.2 (32-bit). I
have a 360MHz UltraSparc IIi processor, and 128MB RAM. The distro is SuSE 7.0.
Sincerely,
Sean Callanan
--
... obviously lots more stuff, but here it actually gets interesting ...
make GCC_FOR_TARGET="/usr/local/src/build-gcc/gcc/xgcc
-B/usr/local/src/build-gcc/gcc/ -B/usr/local/sparc64-linux/bin/
-B/usr/local/sparc64-linux/lib/ -isystem/usr/local/sparc64-linux/include" \
HOST_PREFIX="" HOST_PREFIX_1="loser-" \
AR_FOR_TARGET="sparc64-linux-ar" \
AR_CREATE_FOR_TARGET="sparc64-linux-ar rc" \
AR_FLAGS_FOR_TARGET="" \
OLDCC="cc" CCLIBFLAGS="-O" \
CFLAGS="-g -O2 -W -Wall -Wwrite-strings -Wstrict-prototypes
-Wmissing-prototypes -Wtraditional -pedantic -Wno-long-long" \
RANLIB_FOR_TARGET="sparc64-linux-ranlib" \
RANLIB_TEST_FOR_TARGET="[ -f sparc64-linux-ranlib ] || ( [
"sparc-unknown-linux-gnu" = "sparc64-unknown-linux-gnu" ] && [ -f
/usr/bin/ranlib -o -f /bin/ranlib
] )" \
NM_FOR_TARGET="sparc64-linux-nm" AWK="gawk" \
LIBGCC2_CFLAGS="-O2 -DCROSS_COMPILE -DIN_GCC -W -Wall
-Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -isystem ./include
-fPIC -g1 -DIN_LIBGCC2
-D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc" \
INCLUDES="-I. -I. -I../../gcc/gcc -I../../gcc/gcc/.
-I../../gcc/gcc/config -I../../gcc/gcc/../include" MAYBE_USE_COLLECT2="" \
CONFIG_H="config.h auto-host.h
gansidecl.h ../../gcc/gcc/config/sparc/xm-sparc.h ../../gcc/gcc/config/sparc/linux64.h
defaults.h insn-codes.h" MACHMODE_H="mac
hmode.h machmode.def" \
LIB1ASMSRC='' \
MAKEOVERRIDES= \
-f libgcc.mk all
make[2]: Entering directory `/usr/local/src/build-gcc/gcc'
for d in libgcc; do \
if [ -d $d ]; then true; else mkdir $d; fi \
done
if [ -f stmp-dirs ]; then true; else touch stmp-dirs; fi
make GCC_FOR_TARGET="/usr/local/src/build-gcc/gcc/xgcc
-B/usr/local/src/build-gcc/gcc/ -B/usr/local/sparc64-linux/bin/
-B/usr/local/sparc64-linux/lib/ -isystem/usr/local/sparc64-linux/include" \
AR_FOR_TARGET="sparc64-linux-ar" \
AR_CREATE_FOR_TARGET="sparc64-linux-ar rc" \
AR_EXTRACT_FOR_TARGET="" \
AR_FLAGS_FOR_TARGET="" \
CC="gcc" CFLAGS="-g -O2 -W -Wall -Wwrite-strings -Wstrict-prototypes
-Wmissing-prototypes -Wtraditional -pedantic -Wno-long-long" \
HOST_PREFIX="" \
HOST_PREFIX_1="loser-" \
LANGUAGES="" \
LIBGCC2_CFLAGS="-O2 -DCROSS_COMPILE -DIN_GCC -W -Wall
-Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -isystem ./include
-fPIC -g1 -DIN_LIBGCC2
-D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc " \
MULTILIB_CFLAGS="" T= crtbegin.o
make[3]: Entering directory `/usr/local/src/build-gcc/gcc'
make[3]: Leaving directory `/usr/local/src/build-gcc/gcc'
/usr/local/src/build-gcc/gcc/xgcc -B/usr/local/src/build-gcc/gcc/
-B/usr/local/sparc64-linux/bin/ -B/usr/local/sparc64-linux/lib/ -isystem
/usr/local/sparc64-li
nux/include -O2 -DCROSS_COMPILE -DIN_GCC -W -Wall -Wwrite-strings
-Wstrict-prototypes -Wmissing-prototypes -isystem ./include -fPIC -g1
-DIN_LIBGCC2 -D__G
CC_FLOAT_NOT_NEEDED -Dinhibit_libc -shared -nodefaultlibs
-Wl,--soname=libgcc_s.so.0 -Wl,--version-script=libgcc.map -o libgcc_s.so
libgcc/./_muldi3.o libgcc/
./_divdi3.o libgcc/./_moddi3.o libgcc/./_udivdi3.o libgcc/./_umoddi3.o
libgcc/./_negdi2.o libgcc/./_lshrdi3.o libgcc/./_ashldi3.o
libgcc/./_ashrdi3.o libgcc/./_
/usr/local/sparc64-linux/bin/ld: skipping incompatible /lib/libc.so.6 when
searching for /lib/libc.so.6
/usr/local/sparc64-linux/bin/ld: skipping incompatible /lib/libc.so.6 when
searching for /lib/libc.so.6
/usr/local/sparc64-linux/bin/ld: skipping incompatible /lib/libc.so.6 when
searching for /lib/libc.so.6
/usr/local/sparc64-linux/bin/ld: skipping incompatible /lib/libc.so.6 when
searching for /lib/libc.so.6
/usr/local/sparc64-linux/bin/ld: skipping incompatible /lib/libc.so.6 when
searching for /lib/libc.so.6
/usr/local/sparc64-linux/bin/ld: skipping incompatible /lib/libc.so.6 when
searching for /lib/libc.so.6
/usr/local/sparc64-linux/bin/ld: skipping incompatible /lib/libc.so.6 when
searching for /lib/libc.so.6
root@rei:/usr/local/src/build-gcc >
More information about the Gcc-help
mailing list