On Sat, May 1, 2010 at 2:06 AM, Ian Lance Taylor <iant@xxxxxxxxxx> wrote: > Tom Hawkins <tomahawkins@xxxxxxxxx> writes: > >> Binutils builds find (2.20), but I'm having problems building GCC >> (4.5.0). I configure with: >> >> $ cd build >> $ ../gcc-4.5.0/configure --target=powerpc-eabi >> --prefix=$HOME/powerpc-eabi --enable-languages=c,ada --with-newlib >> --without-headers >> >> The snippet of the failure is below. It appears it is using the wrong >> assembler. > > Yes. > > Did you configure the binutils with the exact same --target and > --prefix options? Yes, exactly the same. > > Run the failing gcc command with the -v option to > see which assembler it is invoking. It appears that your host gcc is > running your target assembler, which is a peculiar failure mode. With -v, yes, it looks like it is using the target assembler. Any suggestions? Using built-in specs. Target: i486-linux-gnu Configured with: ../src/configure -v --with-pkgversion='Ubuntu 4.4.3-4ubuntu5' --with-bugurl=file:///usr/share/doc/gcc-4.4/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --enable-shared --enable-multiarch --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.4 --program-suffix=-4.4 --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-plugin --enable-objc-gc --enable-targets=all --disable-werror --with-arch-32=i486 --with-tune=generic --enable-checking=release --build=i486-linux-gnu --host=i486-linux-gnu --target=i486-linux-gnu Thread model: posix gcc version 4.4.3 (Ubuntu 4.4.3-4ubuntu5) COLLECT_GCC_OPTIONS='-c' '-v' '-g' '-O2' '-DIN_GCC' '-DCROSS_DIRECTORY_STRUCTURE' '-W' '-Wall' '-Wwrite-strings' '-Wcast-qual' '-Wstrict-prototypes' '-Wmissing-prototypes' '-Wmissing-format-attribute' '-pedantic' '-Wno-long-long' '-Wno-variadic-macros' '-Wno-overlength-strings' '-Wold-style-definition' '-Wc++-compat' '-DHAVE_CONFIG_H' '-DGENERATOR_FILE' '-I.' '-Ibuild' '-I../../gcc-4.5.0/gcc' '-I../../gcc-4.5.0/gcc/build' '-I../../gcc-4.5.0/gcc/../include' '-I../../gcc-4.5.0/gcc/../libcpp/include' '-I/home/e0082888/Downloads/build/./gmp' '-I/home/e0082888/Downloads/gcc-4.5.0/gmp' '-I/home/e0082888/Downloads/build/./mpfr' '-I/home/e0082888/Downloads/gcc-4.5.0/mpfr' '-I/home/e0082888/Downloads/gcc-4.5.0/mpc/src' '-I../../gcc-4.5.0/gcc/../libdecnumber' '-I../../gcc-4.5.0/gcc/../libdecnumber/dpd' '-I../libdecnumber' '-o' 'build/genmodes.o' '-mtune=generic' '-march=i486' /usr/lib/gcc/i486-linux-gnu/4.4.3/cc1 -quiet -v -I. -Ibuild -I../../gcc-4.5.0/gcc -I../../gcc-4.5.0/gcc/build -I../../gcc-4.5.0/gcc/../include -I../../gcc-4.5.0/gcc/../libcpp/include -I/home/e0082888/Downloads/build/./gmp -I/home/e0082888/Downloads/gcc-4.5.0/gmp -I/home/e0082888/Downloads/build/./mpfr -I/home/e0082888/Downloads/gcc-4.5.0/mpfr -I/home/e0082888/Downloads/gcc-4.5.0/mpc/src -I../../gcc-4.5.0/gcc/../libdecnumber -I../../gcc-4.5.0/gcc/../libdecnumber/dpd -I../libdecnumber -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -DHAVE_CONFIG_H -DGENERATOR_FILE ../../gcc-4.5.0/gcc/genmodes.c -D_FORTIFY_SOURCE=2 -quiet -dumpbase genmodes.c -mtune=generic -march=i486 -auxbase-strip build/genmodes.o -g -O2 -W -Wall -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wmissing-format-attribute -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -Wold-style-definition -Wc++-compat -version -fstack-protector -o /tmp/ccD1sArz.s GNU C (Ubuntu 4.4.3-4ubuntu5) version 4.4.3 (i486-linux-gnu) compiled by GNU C version 4.4.3, GMP version 4.3.2, MPFR version 2.4.2-p1. GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 ignoring nonexistent directory "/usr/local/include/i486-linux-gnu" ignoring nonexistent directory "/usr/lib/gcc/i486-linux-gnu/4.4.3/../../../../i486-linux-gnu/include" ignoring nonexistent directory "/usr/include/i486-linux-gnu" ignoring nonexistent directory "../../gcc-4.5.0/gcc/build" #include "..." search starts here: #include <...> search starts here: . build ../../gcc-4.5.0/gcc ../../gcc-4.5.0/gcc/../include ../../gcc-4.5.0/gcc/../libcpp/include /home/e0082888/Downloads/build/./gmp /home/e0082888/Downloads/gcc-4.5.0/gmp /home/e0082888/Downloads/build/./mpfr /home/e0082888/Downloads/gcc-4.5.0/mpfr /home/e0082888/Downloads/gcc-4.5.0/mpc/src ../../gcc-4.5.0/gcc/../libdecnumber ../../gcc-4.5.0/gcc/../libdecnumber/dpd ../libdecnumber /usr/local/include /usr/lib/gcc/i486-linux-gnu/4.4.3/include /usr/lib/gcc/i486-linux-gnu/4.4.3/include-fixed /usr/include End of search list. GNU C (Ubuntu 4.4.3-4ubuntu5) version 4.4.3 (i486-linux-gnu) compiled by GNU C version 4.4.3, GMP version 4.3.2, MPFR version 2.4.2-p1. GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 Compiler executable checksum: 5998ce5f1765e99eea5269f4c1e38d44 COLLECT_GCC_OPTIONS='-c' '-v' '-g' '-O2' '-DIN_GCC' '-DCROSS_DIRECTORY_STRUCTURE' '-W' '-Wall' '-Wwrite-strings' '-Wcast-qual' '-Wstrict-prototypes' '-Wmissing-prototypes' '-Wmissing-format-attribute' '-pedantic' '-Wno-long-long' '-Wno-variadic-macros' '-Wno-overlength-strings' '-Wold-style-definition' '-Wc++-compat' '-DHAVE_CONFIG_H' '-DGENERATOR_FILE' '-I.' '-Ibuild' '-I../../gcc-4.5.0/gcc' '-I../../gcc-4.5.0/gcc/build' '-I../../gcc-4.5.0/gcc/../include' '-I../../gcc-4.5.0/gcc/../libcpp/include' '-I/home/e0082888/Downloads/build/./gmp' '-I/home/e0082888/Downloads/gcc-4.5.0/gmp' '-I/home/e0082888/Downloads/build/./mpfr' '-I/home/e0082888/Downloads/gcc-4.5.0/mpfr' '-I/home/e0082888/Downloads/gcc-4.5.0/mpc/src' '-I../../gcc-4.5.0/gcc/../libdecnumber' '-I../../gcc-4.5.0/gcc/../libdecnumber/dpd' '-I../libdecnumber' '-o' 'build/genmodes.o' '-mtune=generic' '-march=i486' as -V -Qy -o build/genmodes.o /tmp/ccD1sArz.s GNU assembler version 2.20 (powerpc-eabi) using BFD version (GNU Binutils) 2.20 /tmp/ccD1sArz.s: Assembler messages: /tmp/ccD1sArz.s:19: Error: Unrecognized opcode: `pushl' /tmp/ccD1sArz.s:22: Error: Unrecognized opcode: `movl' /tmp/ccD1sArz.s:26: Error: Unrecognized opcode: `subl' ... > > Ian >