On Mon, 2 Dec 2013 12:01:38 +0000 (UTC) Thomas Kupper <thomas.kup...@gmail.com> wrote:
> G'day, > > I was coming across that error while trying to cross compile mpc for > later use with gcc using Optware building system (nothing to do with > LFS I agree). In my case it was mpc which did complain but mpfr was > the one causing it. In the libmpfr.la there was the path > to /opt/lib/libgmp.la (/opt/lib in my case cause of Optware). MPC > seems to look at the libmpfr.la (and libgmp.la) I assume. > > --- <path to the libmpfr.la> --- > ... > # Libraries that this one depends upon. > dependency_libs=' -L<some-path-to-my-project> opt/lib/libgmp.la' > ... > --------------------------- > > I still don't know the source of the problem but I simply did sed the > /opt/lib/*.la out of the libmpfr.la file and mpc and gcc compiled > fine. And I may add that "/opt/lib/libgmp.la" is is not in > 'dependency_libs the libmpfr.la file right after compilation > in ./src/.libs/libmpfr.la and ./src/libmpfr.la. Instead the complete > path to were it really gets copied. It seems to happen during the > "$make install" phase. > > Maybe that a) helps someone else too - as did your post me - and b) > maybe someone with deeper knowledge of libs/libtool and compiling > knows what's the source of the problem is. The method with linking to > - in my case - /opt/lib would be a bit more work since I do cross > compile for i686 and x86_64 bit. > > Additionally, in libmpc.la the two paths to /opt/lib/libgmp.la and > /opt/lib/libmpfr.la appear again but gcc seems not to mind and > compiles fine anyway. > > Below the sed I used, although probaly obvious: > $ sed -i 's%^\(dependency_libs=.*\) \(/opt/lib/.*la\)%/\1%g' \ > > /home/jane/Projects/slug/optware/asustor-i686/staging/opt/lib/libmpfr.la > > System involved: > - Ubuntu 12.04 32-bit, 4 logical CPU's, 4GB RAM (Parallels VM) > - cross compiler : gcc 4.6.3 > - latest Optware and latest GMP,MPFR and MPC > > I was also able to trace the problem back to a bad dependency line in a libtool archive file. But in my case it can't be an install problem because in LFS, you don't actually install these libraries in your /tools tree. You just unpack their sources inside the gcc source directory and let Make build and use them. In the end, after hitting the same wall several times, I just used a redirecting link as no one was prepared to suggest anything better. In the second-pass build of gcc everything went smoothly, so the problem must lie with my host compiler. I have a "home-rolled" minimalist system based on Slackware packages and something is probably missing in my setup. -- http://linuxfromscratch.org/mailman/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/lfs/faq.html Unsubscribe: See the above information page