This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [CROSS GCC]: xgcc not using multi-os-directory for ligcc_s.so.1
- From: Daniel Jacobowitz <drow at false dot org>
- To: Richard Chan <rspchan at starhub dot net dot sg>
- Cc: gcc at gcc dot gnu dot org
- Date: Sun, 4 Jul 2004 14:40:30 -0400
- Subject: Re: [CROSS GCC]: xgcc not using multi-os-directory for ligcc_s.so.1
- References: <40E802D1.8040802@starhub.net.sg>
On Sun, Jul 04, 2004 at 09:14:57PM +0800, Richard Chan wrote:
> In building a x86->Sparc32,64 cross I encountered the situation where
> xgcc is not using
> the multi-os-directory when building libgcc_s.so.1. This results in
> finding the wrong target
> crt*.o files (32-bit) when trying to build 64-bit libgcc_s.so.1.
>
> Problem description
>
> Building an x86->Sparc32,64 cross using
> configure
> --prefix=/opt/sparctools --target=sparc64-unknown-linux-gnu
> --enable-threads=posix --enable-__cxa_atexit --disable-libunwind-exceptions
> --disable-optimization --with-system-zlib
>
> The target files (necessary for pthread.h, libc.so etc) have been copied
> over
> from a live system:
>
> 32-bit files in <prefix>/<target>/lib
> 64-bit files in<prefix>/<target>lib64
> System headers in <prefix>/<target>/sys-include
You're using a multi-OS directory, so you need to put them where GCC
will expect OS directories. It won't use the OS libdir suffix for
<target>/lib.
Try this instead:
Add --with-sysroot=/opt/sparctools/sys-root
32-bit files in <prefix>/sys-root/usr/lib
64-bit files in <prefix>/sys-root/usr/lib64
System headers in <prefix>/sys-root/usr/include
I assume you're using 3.4, by the way.
--
Daniel Jacobowitz