Hi Pierre, On Sat, Feb 15, 2020 at 9:58 PM Pierre Labastie via lfs-dev <[email protected]> wrote: > > /home/eus/LFS-system/LFS-tools/bin/../lib/gcc/x86_64-pc-linux-gnu/9.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: > > /lib/x86_64-linux-gnu/libpthread.so.0: undefined reference to > > There is something wrong in your setup: no library in /lib should be used at > this stage...
Thank you very much for pointing that out. Indeed, it is the problem, specifically due to not using the option `--with-sysroot' when building the second binutils described at http://www.linuxfromscratch.org/lfs/view/development/chapter05/binutils-pass2.html. Without the option, ld will first try to read ld.so.conf in several different places and end up reading the ld.so.conf of the build system. Supplying the option `--with-sysroot' forces ld to read ld.so.conf in places within the non-existent directory /LFS-tools/x86_64-pc-linux-gnu/sys-root/. Since the directory is non-existent, no ld.so.conf is read, and ld ends up searching in those paths specified by the `-L' options. Once again, thank you for your help. > Pierre -- Best regards, Tadeus -- http://lists.linuxfromscratch.org/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page
