Hey lfs-dev members,
I'm in the process of building a new system. I've already got my
toolchain up and running and making my way through the system gcc.
I was going over the installed libraries. I'm not sure what inspired
me to check out the libtool control files, but I noticed something
peculiar in /usr/lib/libgmpxx.la, around line 19~20:
# Libraries that this one depends upon.
dependency_libs=' /usr/lib/libgmp.la /tools/lib/libstdc++.la'
It seems that while building the system gmp, libtool causes
libgmpxx.la to pull libstdc++.la from the toolchain. I believe, if I
am not mistaken, that libgmpxx is the c++ bindings for gmp, enabled by
the '--enable-cxx' configure option in 'Chapter 6.13.1. GMP'. Since
gmp is built before the system gcc, ld and libtool choose the
toolchain libstdc++ instead.
I scanned the remaining .la files with this quick little script below
and found no other issues.
for file in {,/usr}/lib/*.la; do
echo "${file}:"
grep -e "/lib" "${file}"
echo
done
To verify my worst fears, I ran 'ldd /usr/lib/libgmpxx.so' and got the
following references (I'm in a situation that I cannot copy/paste, so
I'm just typing out the details that matter):
libgmp.so.10 => /usr/lib/libgmp.so.10
libstdc++.so.6 => /tools/lib/libstdc++.so.6
libm.so.6 => /tools/lib/libm.so.6
libc.so.6 => /tools/lib/libc.so.6
libgcc_s.so.1 => /tools/lib/libgcc_s.so.1
Given that the only available c++ library in the environment is in the
toolchain, I suspect this happens to anyone using the '--enable-cxx'
configure flag at this stage.
Can anyone verify if this is true on their system? If it is, then I
see two possible fixes:
1) postpone building libgmpxx. (simple enough, but annoying)
2) remove it entirely. (what uses this? someone must want it)
Jonathan
--
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page