public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* FW: Error while building arm-elf cross-compiler with -arch=iwmmxt2
@ 2009-08-05 22:41 Sangeeta Ghangam
  2009-08-06  9:47 ` Richard Earnshaw
  0 siblings, 1 reply; 2+ messages in thread
From: Sangeeta Ghangam @ 2009-08-05 22:41 UTC (permalink / raw)
  To: gcc-help



Ok , figured out the issue used --with-cpu=iwmmxt2 and --with-abi=aapcs in the configure. These options got me much farther in the compile process but now I have a new set of errors

/opt/src/gcc-4.4.1/gcc/crtstuff.c: In function '__do_global_dtors_aux':
/opt/src/gcc-4.4.1/gcc/crtstuff.c:301: error: '__DTOR_LIST__' undeclared (first
use in this function)
/opt/src/gcc-4.4.1/gcc/crtstuff.c:301: error: (Each undeclared identifier is reported only once
/opt/src/gcc-4.4.1/gcc/crtstuff.c:301: error: for each function it appears in.)
make[5]: *** [/tmp/build/gcc/arm-elf/thumb/libgcc/crtbegin.o] Error 1
make[5]: Leaving directory `/tmp/build/gcc/gcc'
make[4]: *** [gcc-extra-parts] Error 2
make[4]: Leaving directory `/tmp/build/gcc/arm-elf/thumb/libgcc'
make[3]: *** [multi-do] Error 1
make[3]: Leaving directory `/tmp/build/gcc/arm-elf/libgcc'
make[2]: *** [all-multi] Error 2
make[2]: Leaving directory `/tmp/build/gcc/arm-elf/libgcc'
make[1]: *** [all-target-libgcc] Error 2
make[1]: Leaving directory `/tmp/build/gcc'
make: *** [all] Error 2
make: Leaving directory `/tmp/build/gcc'

Am I missing any recent patches/configure options?
Thanks for any help
Sangeeta

-----Original Message-----
From: Sangeeta Ghangam 
Sent: Tuesday, August 04, 2009 7:05 AM
To: 'gcc-help@gcc.gnu.org'
Subject: Error while building arm-elf cross-compiler with -arch=iwmmxt2


Hello,
I am trying to build an arm-elf cross-compiler with a gcc configure option -arch=iwmmxt2 ( or -cpu=iwmmxt2).
Following is the list of sources I have used:
Binutils-2.19.1
Gmp-4.3.1
Mpfr-2.4.1
Newlib-1.17.0
Gcc-core-4.4.1
Gcc-g++-4.4.1

I am building the toolchain on cygwin
Following are the configure options for binutils
/opt/src/binutils-2.19.1/configure --target=arm-elf --prefix=/gnutools -v 2>&1 | tee configure.out

I am building newlib with gcc by copying the newlib and libgloss folders into the gcc folder. Following are the configure options for gcc

/opt/src/gcc-4.4.1/configure --target=arm-elf --prefix=/gnutools --enable-languages=c,c++ --with-gnu-as --with-gnu-ld --with-newlib --with-gxx-include-dir=/gnutools/arm-elf/include --with-arch=iwmmxt2 --with-float=soft --with-mpfr-lib=/usr/local/lib --with-gmp-lib=/usr/local/lib -v 2>&1 | tee configure.out

I had initially configured and built gcc without using the '--with-cpu' option since I want a cross-compiler that would work with armv7 as well as iwmmxt2 architectures. I had no build issues but on compiling my test code I got an error that 'libgcc.a(_udiviso.o) uses FPA whereas target elf uses soft FP' , this inspite building gcc with the '--with-float=soft' option.
I looked on the web and found that unless '--with-arch or --with-cpu' option is specified while building gcc , libgcc gets built to use FPA by default.
That is why I am back to trying to build gcc with the '--with-arch' option.
Now I am getting gcc build errors when libgcc is built:
'checking for suffix of object files... configure: error: cannot
compute suffix of object files: cannot compile'

I get the same error even when I use '--with-arch=armv7' 
Is there any fix for this? How do I build a cross-compiler to work for both armv7 and iwmmxt2 architectures using soft float.
Thanks
Sangeeta

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: FW: Error while building arm-elf cross-compiler with  -arch=iwmmxt2
  2009-08-05 22:41 FW: Error while building arm-elf cross-compiler with -arch=iwmmxt2 Sangeeta Ghangam
@ 2009-08-06  9:47 ` Richard Earnshaw
  0 siblings, 0 replies; 2+ messages in thread
From: Richard Earnshaw @ 2009-08-06  9:47 UTC (permalink / raw)
  To: Sangeeta Ghangam; +Cc: gcc-help


On Wed, 2009-08-05 at 15:41 -0700, Sangeeta Ghangam wrote:
> 
> Ok , figured out the issue used --with-cpu=iwmmxt2 and --with-abi=aapcs in the configure. These options got me much farther in the compile process but now I have a new set of errors

Rather than trying to force the old arm-elf configuration to use the
AAPCS (you'll probably fail), just use the arm-eabi configuration --
that's already set up to use the AAPCS.

R.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-08-06  9:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-08-05 22:41 FW: Error while building arm-elf cross-compiler with -arch=iwmmxt2 Sangeeta Ghangam
2009-08-06  9:47 ` Richard Earnshaw

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).