This is the mail archive of the crossgcc@sourceware.org mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Problem w/ glibc-2.3.4 on PPC partially solved


I am trying to run crosstool to compile a toolchain for i386. My
machine is a PowerPC G4 with OS X 10.4 (Tiger).

(I have taken all the neccessary measures to make sure that crosstool
doesn't choke on some OS X programs like ld, as, and sed.)

while compiling glibc-2.3.4, ./demo-i386.sh exits with:

checking for suffix of object files... configure: error: cannot
compute suffix of object files: cannot compile
See `config.log' for more details.

closer inspection of
./build/i386-unknown-linux-gnu/gcc-3.4.3-glibc-2.3.4/build-glibc-headers/config.log
reveals the following relevant segment:

configure:2651: checking for suffix of object files
configure:2672: gcc -c -std=gnu99 -DBOOTSTRAP_GCC -Wall -Winline
-Wstrict-prototypes -Wwrite-strings -mpreferred-stack-boundary=2
conftest.c >&5
cc1: error: invalid option 'preferred-stack-boundary=2'
configure:2675: $? = 1
configure: failed program was:
| /* confdefs.h.  */
|
| #define PACKAGE_NAME "GNU C Library"
| #define PACKAGE_TARNAME "c-library"
| #define PACKAGE_VERSION "(see version.h)"
| #define PACKAGE_STRING "GNU C Library (see version.h)"
| #define PACKAGE_BUGREPORT "glibc"
| #define USE_REGPARMS 1
| /* end confdefs.h.  */
|
| int
| main ()
| {
|
|   ;
|   return 0;
| }
configure:2689: error: cannot compute suffix of object files: cannot compile
See `config.log' for more details.

I looked in OS X's manpage for gcc, and sure enough
-mpreferred-stack-boundary is not a valid command line option for
Darwin's gcc on PowerPC (it's okay for i386 though).

So it seems the fix for this would be to mess with Autoconf or the
configure scripts so that -mpreferred-stack-boundary=2 is never passed
to gcc if the host is PowerPC. I'm wholly unfamiliar with the
configure scripts/Autoconf though, so if anyone else is
interested/motivated enough, then please treat this like a user bug
report. Thanks.

- Brian Waters

--
For unsubscribe information see http://sourceware.org/lists.html#faq


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]