need help with gcc 4.1.0 crosscompiler for arm

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I'm obviously doing something stupid, and would appreciate some help.

I've got an embedded application running on arm hardware. Currently it
is built with gcc 3.4.3 and binutils 2.15.  I configure binutils and
gcc in the obvious ways:

../binutils-2.15/configure --prefix=/usr/local/armdev-3.4.3 --target=arm-elf

../gcc-3.4.3/configure --prefix=/usr/local/armdev-3.4.3
--target=arm-elf --enable-languages=c,c++

after having patched gcc/config/arm/t-elf using this patch file:

-----     patch file     -----
--- gcc-3.4.2/gcc/config/arm/t-arm-elf  2003-09-30 03:21:41.000000000 -0700
+++ gcc-3.4.2-p/gcc/config/arm/t-arm-elf        2004-09-17
09:29:58.312527908 -0700
@@ -26,9 +26,9 @@
 # MULTILIB_DIRNAMES   += 32bit 26bit
 # MULTILIB_EXCEPTIONS += *mthumb/*mapcs-26*
 #
-# MULTILIB_OPTIONS    += mno-thumb-interwork/mthumb-interwork
-# MULTILIB_DIRNAMES   += normal interwork
-# MULTILIB_EXCEPTIONS += *mapcs-26/*mthumb-interwork*
+MULTILIB_OPTIONS    += mno-thumb-interwork/mthumb-interwork
+MULTILIB_DIRNAMES   += normal interwork
+MULTILIB_EXCEPTIONS += *mapcs-26/*mthumb-interwork*
 #
 # MULTILIB_OPTIONS    += fno-leading-underscore/fleading-underscore
 # MULTILIB_DIRNAMES   += elf under
@@ -71,7 +71,7 @@
 # Currently there is a bug somewhere in GCC's alias analysis
 # or scheduling code that is breaking _fpmul_parts in fp-bit.c.
 # Disabling function inlining is a workaround for this problem.
-TARGET_LIBGCC2_CFLAGS = -Dinhibit_libc -fno-inline
+TARGET_LIBGCC2_CFLAGS = -Dinhibit_libc -fno-inline -msoft-float

 # Assemble startup files.
 $(T)crti.o: $(srcdir)/config/arm/crti.asm $(GCC_PASSES)

-----     end of patch file     -----

GCC builds fine and builds the application fine.

I try doing the same thing for gcc 4.1.0 and gcc builds fine, but when
it finally gets around to trying to link the executable, I get error
messages that I *think* mean that libgcc is being built with arm
floating point instructions, for instance:

/usr/local/gnuarm-4.1.0/bin/arm-elf-ld: ERROR:
/usr/local/gnuarm-4.1.0/lib/gcc/arm-elf/4.1.0/interwork/libgcc.a(_clz.o)
uses FPA instructions, whereas application.elf does not

I've tried every configuration option I can think of to build libgcc
without floating point, but have not managed to do so.

As I said, I'm obviously doing something dumb, and any help in
figuring out what I should do instead would be greatly appreciated.

Thanks,

Marty


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux