Hi, while trying to build arm-elf-gcc-4.6.0 I get assembler errors in thumb/libgcc. I'm having a hard time finding out how to build gcc correctly and don't know what I did wrong, any hints appreciated. here the end of make output: make[4]: Entering directory `/usr/local/build/gcc/gcc-4.6.0-arm/arm-elf/thumb/libgcc' # If this is the top-level multilib, build all the other # multilibs. /usr/local/build/gcc/gcc-4.6.0-arm/./gcc/xgcc -B/usr/local/build/gcc/gcc-4.6.0-arm/./gcc/ -B/usr/local/exp/gcc-4.6.0/arm-elf/bin/ -B/usr/local/exp/gcc-4.6.0/arm-elf/lib/ -isystem /usr/local/exp/gcc-4.6.0/arm-elf/include -isystem /usr/local/exp/gcc-4.6.0/arm-elf/sys-include -g -Os -mthumb -O2 -g -Os -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -W -Wall -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include -fno-inline -Wno-missing-prototypes -g -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -fno-stack-protector -I. -I. -I../../.././gcc -I../../../../gcc-4.6.0/libgcc -I../../../../gcc-4.6.0/libgcc/. -I../../../../gcc-4.6.0/libgcc/../gcc -I../../../../gcc-4.6.0/libgcc/../include -DHAVE_CC_TLS -DUSE_EMUTLS -o _thumb1_case_sqi.o -MT _thumb1_case_sqi.o -MD -MP -MF _thumb1_case_sqi.dep -DL_thumb1_case_sqi -xassembler-with-cpp \ -c ../../../../gcc-4.6.0/libgcc/../gcc/config/arm/lib1funcs.asm ../../../../gcc-4.6.0/libgcc/../gcc/config/arm/lib1funcs.asm: Assembler messages: ../../../../gcc-4.6.0/libgcc/../gcc/config/arm/lib1funcs.asm:1725: Error: unknown pseudo-op: `.syntax' ../../../../gcc-4.6.0/libgcc/../gcc/config/arm/lib1funcs.asm:1729: Error: bad instruction `lsrs r1,r1,#1' ../../../../gcc-4.6.0/libgcc/../gcc/config/arm/lib1funcs.asm:1730: Error: bad instruction `lsls r1,r1,#1' ../../../../gcc-4.6.0/libgcc/../gcc/config/arm/lib1funcs.asm:1732: Error: bad instruction `lsls r1,r1,#1' make[4]: *** [_thumb1_case_sqi.o] Error 1 make[4]: Leaving directory `/usr/local/build/gcc/gcc-4.6.0-arm/arm-elf/thumb/libgcc' make[3]: *** [multi-do] Error 1 make[3]: Leaving directory `/usr/local/build/gcc/gcc-4.6.0-arm/arm-elf/libgcc' make[2]: *** [all-multi] Error 2 make[2]: Leaving directory `/usr/local/build/gcc/gcc-4.6.0-arm/arm-elf/libgcc' make[1]: *** [all-target-libgcc] Error 2 make[1]: Leaving directory `/usr/local/build/gcc/gcc-4.6.0-arm' make: *** [all] Error 2 Google found that it could be using a wrong as, but I get the same error with my old installed version: arm-elf-gcc-3.4.3 -isystem /usr/local/exp/gcc-4.6.0/arm-elf/include -isystem /usr/local/exp/gcc-4.6.0/arm-elf/sys-include -g -Os -mthumb -O2 -g -Os -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -W -Wall -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include -fno-inline -Wno-missing-prototypes -g -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -I. -I. -I../../.././gcc -I../../../../gcc-4.6.0/libgcc -I../../../../gcc-4.6.0/libgcc/. -I../../../../gcc-4.6.0/libgcc/../gcc -I../../../../gcc-4.6.0/libgcc/../include -DHAVE_CC_TLS -DUSE_EMUTLS -o _thumb1_case_sqi.o -MT _thumb1_case_sqi.o -MD -MP -MF _thumb1_case_sqi.dep -DL_thumb1_case_sqi -xassembler-with-cpp -c ../../../../gcc-4.6.0/libgcc/../gcc/config/arm/lib1funcs.asm leads to literally the same error messages from the assembler. I did: # At first we build only the cross compiler without any libraries. # To enable Thumb interworking, you need to edit # gcc-4.4.1/gcc/config/arm/t-arm-elf. Uncomment the following # lines: # # MULTILIB_OPTIONS += mlittle-endian/mbig-endian # MULTILIB_DIRNAMES += le be # MULTILIB_MATCHES += mbig-endian=mbe mlittle-endian=mle # # MULTILIB_OPTIONS += mhard-float/msoft-float # MULTILIB_DIRNAMES += fpu soft # MULTILIB_EXCEPTIONS += *mthumb/*mhard-float* # # MULTILIB_OPTIONS += mno-thumb-interwork/mthumb-interwork # MULTILIB_DIRNAMES += normal interwork # and configured: ../gcc-4.6.0/configure \ --prefix=/usr/local/exp/gcc-4.6.0/ \ --enable-languages=c,c++ \ --target=arm-elf \ --program-prefix=arm-elf \ --with-sysroot=/usr/local/build/gcc/sysroot/ \ --enable-interwork --enable-multilib \ --enable-target-optspace --with-float=soft \ --with-zlib=no what did I wrong and how do I continue? I found several HOWTOs for building for ARM target, but I'm afraid no comprehensive one. Which documentation I should follow? Any hints and pointers appreciated! oki, Steffen