On Mon, Dec 30, 2013 at 11:29:34PM +0100, Frans de Boer wrote: > Dear reader, > > While building things again, I now start to wonder why LFS let almost > every package installs a static library? Where are the static libraries > used? > They can sometimes be used if you mis-install one of the packages :-) More so on 32-bit x86 - x86_64 is more likely to fail to link static libs into shared executables because it requires -fPIC. Obviously, using something to suppress the static libs in your own package management will highlight any places where this happens! I append ".hidden" to all non-toolchain /usr/lib/lib*.a files at the end of my package installs.
More likely, _some_ of the toolchain libs _might_ be required to run configure scripts. I've never found enough time to test this. I did hide a few "unlikely to be needed" static toolchain libs, but others such as libc.a seem likely to be generally used, at least in configure scripts. Or, as Bruce's reply probably pointed to (I didn't read his link) - for development. > After all, the down side of static libraries is that once linked into a > module/program, any upgrade is not incorporated. Potentially leaving > modules/programs vulnerable to manipulation. > In general, please be aware that "--disable-static" does not always work. More importantly, some libs are not in fixed versions, so the static version is theoretically required (e.g. PAM needs a static lib from flex - I got a dirty workaround from our late colleague Andy to convert any .a to .so, but that might not be a good idea when things can change because they have not been versioned). Also, in BLFS tcl and tk require their static stub libs, and firefox / xulrunner require libcrmf.a which in my systems comes from standalone nss. I now remember there is at least one static lib in kde. And probably others in packages I don't care about. > It is listed that only a very few use some static libraries and others > are not mentioned. I know, disk space is not an issue nowadays, but > still it needs to be maintained and dependencies are not listed anyhow. > > Can someone shed some light on this issue? > > Regards, Frans. > -- > http://linuxfromscratch.org/mailman/listinfo/lfs-support > FAQ: http://www.linuxfromscratch.org/lfs/faq.html > Unsubscribe: See the above information page I think many LFS/BLFS builders don't care about these sort of problems. It was a tedious buisness to disable static libs in BLFS. Fortunately, those of us who care can fix the parts we care about on our own systems (so yes, I could test if my remaining static toolchain libs are really needed, but it hasn't yet proved important enough to me : if I need to rebuild the toolchain, I upgrade LFS). ĸen -- das eine Mal als Tragödie, dieses Mal als Farce -- http://linuxfromscratch.org/mailman/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/lfs/faq.html Unsubscribe: See the above information page