This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


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 building Solaris hosted PowerPC EABI cross compiler


Hi,

I am having trouble building a powerpc-eabi targeted cross compiler on
my Sun Ultra 60 running Solaris 8.  I have read through a couple of
cross-GCC FAQs and through the GCC installation instructions but am
having no luck.  I am using native GCC (version 2.95.3) to build the
cross compiler.  I have done a fair amount of web searching on the error
messages that I am getting but I haven't been able to find a solution.
I have also tried a lot of different combinations of different versions
of binutils and gcc trying to determine if the problem was with the
latest versions (I even tried the exact versions mentioned in the FAQ
below).

Following the cross-GCC FAQ at the below URL (and substituting newer
version numbers for all components, changing the target to powerpc-eabi
and changing prefix to /opt/gcc-ppc-3.1.1), I have built and installed
binutils 2.12.1, built and installed a bootstrap GCC 3.1.1 and built and
installed newlib 1.10.0.  I am running into problems building the full
GCC.

http://crossgcc.billgatliff.com/crossgccfaq/t1.html

I wiped out the GCC build directory prior to re-configuring.  This seems
to be needed but isn't explicitly stated in the FAQ.  Configuration
succeeds but the following make does not.  It dies while "Configuring in
powerpc-eabi/libiberty" saying that:

checking whether the C compiler
(/export/home0/software/build/build-gcc/gcc/xgcc -B/export/home0/software/build/build-gcc/gcc/ -B/opt/gcc-ppc-3.1.1/powerpc-eabi/bin/ -B/opt/gcc-ppc-3.1.1/powerpc-eabi/lib/ -isystem /opt/gcc-ppc-3.1.1/powerpc-eabi/include -g -O2 ) works... no
configure: error: installation or configuration problem: C compiler cannot create executables.
make: *** [configure-target-libiberty] Error 1

Inspecting config.log in powerpc-eabi/libiberty reveals the following
error:

configure:2212: /export/home0/software/build/build-gcc/gcc/xgcc -B/export/home0/software/build/build-gcc/gcc/ -B/opt/gcc-ppc-3.1.1/powerpc-eabi/bin/ -B/opt/gcc-ppc-3.1.1/powerpc-eabi/lib/ -isystem /opt/gcc-ppc-3.1.1/powerpc-eabi/include -o
conftest -g -O2   conftest.c  1>&5
/opt/gcc-ppc-3.1.1/powerpc-eabi/bin/ld: warning: cannot find entry symbol _start; defaulting to 01800074
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o): In function `__eabi':
/export/home0/software/build/build-gcc/gcc/eabi.S:232: undefined reference to `__init'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:146: undefined reference to `__SDATA_START__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:148: undefined reference to `__SBSS_END__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:150: undefined reference to `__SDATA2_START__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:151: undefined reference to `__SBSS2_END__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:152: undefined reference to `__GOT_START__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:155: undefined reference to `__GOT_END__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:156: undefined reference to `__GOT2_START__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:157: undefined reference to `__GOT2_END__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:158: undefined reference to `__FIXUP_START__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:159: undefined reference to `__FIXUP_END__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:163: undefined reference to `__CTOR_LIST__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:164: undefined reference to `__CTOR_END__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:165: undefined reference to `__DTOR_LIST__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:166: undefined reference to `__DTOR_END__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:167: undefined reference to `__EXCEPT_START__'
/export/home0/software/build/build-gcc/gcc/libgcc.a(eabi.o):/export/home0/software/build/build-gcc/gcc/eabi.S:171: undefined reference to `__EXCEPT_END__'
collect2: ld returned 1 exit status
configure: failed program was:

#line 2207 "configure"
#include "confdefs.h"

main(){return(0);}

These undefined symbols sound like ld script symbols to me (not knowing
a whole lot) and also sort of C++ related (constructors, destructors,
exceptions).  Does anyone happen to know what I am doing wrong?  I
re-executed that failed xgcc command with a -v so I could see all the
various tool invocations and don't see anything more there that would
seem to help.  If you need to see that too, let me know and I'll post
it.

Thanks for the help!

-- 
Ron McCall
Sikorsky Aircraft
203-386-4695
rmccall@sikorsky.com


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