On Sat, 27 Sep 2014 15:24:44 -0500 Bruce Dubbs <[email protected]> wrote:
> Hazel Russman wrote: > > In the Chapter 5 build of glibc, three configuration tests are > > bypassed because "The linker installed during Section 5.4... was > > cross-compiled and as such cannot be used until Glibc has been > > installed. This means that the configure test... will fail, as it > > relies on a working linker." > > > > Out of curiosity, I ran ldd on both the static and the dynamic > > linkers from the first pass binutils build. They are linked to the > > host glibc (and a few other host libraries as well). Why would they > > not work? > > > > I usually find the explanations in the book very enlightening but > > this one puzzles me. > > IIRC it really depends on the host. Some libraries and programs are not > yet built, but the host's glibc would be used in this case. > > -- Bruce I was still puzzled so I did a bit of browsing on cross-compiling glibc. The sites I looked at gave a different and much simpler explanation for bypassing those tests. They involve compiling and running a test program; if it was cross-compiled, it wouldn't run on the build system and the configuration would error out. It occurred to me that this wouldn't apply to LFS, where the target and build systems are deliberately made compatible. So, just as an experiment, I made a fresh partition, mounted it on $LFS and repeated the first stages of chapter 5. This time I configured glibc *without* those three options, just to see what would happen. It configured OK and when I checked config.log, all three of those variables had been set to "yes" just as if I'd set them by hand. I made and installed it and ran the sanity test and it worked. As a further check, I did the second pass builds of binutils and gcc and repeated the sanity test and that was OK too. So it looks as if the libc_cv options aren't necessary after all. Of course the only way to prove it conclusively would be to continue through the whole of chapter 5 and chapter 6, build a kernel and see if it would boot. That's a heck of a lot of work just to prove a point! -- Hazel Russman <[email protected]> -- http://lists.linuxfromscratch.org/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page Do not top post on this list. A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail? http://en.wikipedia.org/wiki/Posting_style
