This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: libgomp failures on powerpc-apple-darwin8
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Jack Howarth <howarth at bromo dot msbb dot uc dot edu>
- Cc: gcc at gcc dot gnu dot org
- Date: Wed, 14 Mar 2007 10:11:35 +0100
- Subject: Re: libgomp failures on powerpc-apple-darwin8
- References: <20070314022841.GA30036@bromo.msbb.uc.edu>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Tue, Mar 13, 2007 at 10:28:41PM -0400, Jack Howarth wrote:
> Interestingly, while...
>
> gcc-4 pr30703.C -fmessage-length=0 -fopenmp -O0 -L/sw/lib/gcc4.2/lib -lgomp -lstdc++ -lm -m32 -o ./pr30703.exe
> /usr/bin/ld: Undefined symbols:
> __Unwind_Resume
> collect2: ld returned 1 exit status
>
> fails on powerpc-apple-darwin8....
>
> gcc-4 pr30703.C -fmessage-length=0 -fopenmp -O0 -L/sw/lib/gcc4.2/lib -lgomp -lstdc++ -lm -m32 -shared-libgcc -o ./pr30703.exe
>
> ...links fine. On powerpc-apple-darwin8, libgcc.a is missing __Unwind_Resume. I wonder why this doesn't show up
> on any other architectures?
Because libstdc++.so links against libgcc_s.so.1 which exports that symbol
(was linked with -shared-libgcc). Or, on ELFish targets that use recent
binutils when neither -shared-libgcc nor -static-libgcc is used,
libgcc_s.so.1 is linked in --as-needed.
libgcc.a doesn't contain the unwinder on purpose, it is only in libgcc_s.so
and libgcc_eh.a, so that every binary or library doesn't have its own copy
of the unwinder (which causes severe problems).
Jakub