This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Build of 4.1.0 in cross env
- From: Andrew Haley <aph at redhat dot com>
- To: FERANDELLE Pascal <pascal dot ferandelle at fr dot thalesgroup dot com>
- Cc: java at gcc dot gnu dot org
- Date: Wed, 3 May 2006 14:24:50 +0100
- Subject: Re: Build of 4.1.0 in cross env
- References: <443D0B22.8205A9E4@fr.thalesgroup.com> <17469.3098.421806.759791@zapata.pink> <443D0EF7.EF6BCD75@fr.thalesgroup.com> <17469.4874.181720.730851@zapata.pink> <4458ADE5.FB11CF80@fr.thalesgroup.com>
FERANDELLE Pascal writes:
> > > - extraction of gcc-core-4.1.0.tar, gcc-g++-4.1.0.tar and gcc-java-4.1.0.tar
> > >
> > > - ./configure --with-sysroot=/VMPC/BlueCat --enable-langages=c,java --target=powerpc-linux
> > > (my Linux PowerPC environment is under /VMPC/BlueCat)
> >
> > Configuring gcc in the srcdir is truly scary, and I'm surprised it
> > works at all, but I don't know that's the cause of your problem.
> >
> > "First, we highly recommend that GCC be built into a separate
> > directory than the sources which does not reside within the source
> > tree. This is how we generally build GCC; building where srcdir ==
> > objdir should still work, but doesn't get extensive testing; building
> > where objdir is a subdirectory of srcdir is unsupported.
> >
> > "To configure GCC:
> >
> > % mkdir objdir
> > % cd objdir
> > % srcdir/configure [options] [target]"
> >
> >
>
> I followed this way, and it works better now !!!
> I still have to copy three libraries from my Linux/PowerPC environment to /usr/local/powerpc-linux/lib directory (libc.so.6, libc_nonshared.a, ld.so.1), because the specified path with the --with-sysroot option, is not taken into account everywhere during the build, but it is the only modifications I have to do (nothing in Makefile for example).
>
> So now, I have a complete cross powerpc-linux gcc chain in 4.1.0, and I test on a simple HelloWorld Java program.
> It does not link because there is an undefined reference to __tls_get_addr, needed by libgcj.so.
> I did not have this problem in 3.4.4.
>
> Any idea ?
It should be in the target lib libpthread.so. Make sure your
LD_LIBRARY_PATH points to the dir where that lib resides.
Andrew.