Been working through the book meticulously and had no real problems until
building Perl in chapter 5.
Here is the tail of the output:
cc -o perl -fstack-protector-strong -L/usr/local/lib perlmain.o lib/auto/B/B.a
lib/auto/Compress/Raw/Bzip2/Bzip2.a lib/auto/Compress/Raw/Zlib/Zlib.a
lib/auto/Cwd/Cwd.a lib/auto/Data/Dumper/Dumper.a lib/auto/Devel/PPPort/PPPort.a
lib/auto/Devel/Peek/Peek.a lib/auto/Digest/MD5/MD5.a lib/auto/Digest/SHA/SHA.a
lib/auto/Encode/Encode.a lib/auto/Fcntl/Fcntl.a lib/auto/File/DosGlob/DosGlob.a
lib/auto/File/Glob/Glob.a lib/auto/Filter/Util/Call/Call.a
lib/auto/Hash/Util/Util.a lib/auto/Hash/Util/FieldHash/FieldHash.a
lib/auto/I18N/Langinfo/Langinfo.a lib/auto/IO/IO.a lib/auto/IPC/SysV/SysV.a
lib/auto/List/Util/Util.a lib/auto/MIME/Base64/Base64.a
lib/auto/Math/BigInt/FastCalc/FastCalc.a lib/auto/Opcode/Opcode.a
lib/auto/POSIX/POSIX.a lib/auto/PerlIO/encoding/encoding.a
lib/auto/PerlIO/mmap/mmap.a lib/auto/PerlIO/scalar/scalar.a
lib/auto/PerlIO/via/via.a lib/auto/SDBM_File/SDBM_File.a
lib/auto/Socket/Socket.a lib/auto/Storable/Storable.a
lib/auto/Sys/Hostname/Hostname.a lib/auto/Sys/Syslog/Syslog.a
lib/auto/Tie/Hash/NamedCapture/NamedCapture.a lib/auto/Time/HiRes/HiRes.a
lib/auto/Time/Piece/Piece.a lib/auto/Unicode/Collate/Collate.a
lib/auto/arybase/arybase.a lib/auto/attributes/attributes.a lib/auto/mro/mro.a
lib/auto/re/re.a lib/auto/threads/threads.a lib/auto/threads/shared/shared.a
lib/auto/Encode/Byte/Byte.a lib/auto/Encode/CN/CN.a
lib/auto/Encode/EBCDIC/EBCDIC.a lib/auto/Encode/JP/JP.a lib/auto/Encode/KR/KR.a
lib/auto/Encode/Symbol/Symbol.a lib/auto/Encode/TW/TW.a
lib/auto/Encode/Unicode/Unicode.a libperl.a `cat ext.libs` -lm
/tools/lib/libcrypt.a
lib/auto/POSIX/POSIX.a(POSIX.o): In function `XS_POSIX_tmpnam':
POSIX.c:(.text+0x3654): warning: the use of `tmpnam' is dangerous, better use
`mkstemp'
/mnt/lfs/tools/bin/../lib/gcc/x86_64-unknown-linux-gnu/5.2.0/../../../../lib64/librt.so:
undefined reference to `__pthread_barrier_wait@GLIBC_PRIVATE'
/mnt/lfs/tools/bin/../lib/gcc/x86_64-unknown-linux-gnu/5.2.0/../../../../lib64/librt.so:
undefined reference to `__pthread_barrier_init@GLIBC_PRIVATE'
/lib/x86_64-linux-gnu/libpthread.so.0: undefined reference to
`h_errno@GLIBC_PRIVATE'
collect2: error: ld returned 1 exit status
makefile:376: recipe for target 'perl' failed
make: *** [perl] Error 1
I can reproduce this error message in two words.
1) by copying verbatim the last compilation command:
cc -o perl -fstack-protector-strong -L/usr/local/lib perlmain.o lib/auto/B/B.a
lib/auto/Compress/Raw/Bzip2/Bzip2.a lib/auto/Compress/Raw/Zlib/Zlib.a
lib/auto/Cwd/Cwd.a lib/auto/Data/Dumper/Dumper.a lib/auto/Devel/PPPort/PPPort.a
lib/auto/Devel/Peek/Peek.a lib/auto/Digest/MD5/MD5.a lib/auto/Digest/SHA/SHA.a
lib/auto/Encode/Encode.a lib/auto/Fcntl/Fcntl.a lib/auto/File/DosGlob/DosGlob.a
lib/auto/File/Glob/Glob.a lib/auto/Filter/Util/Call/Call.a
lib/auto/Hash/Util/Util.a lib/auto/Hash/Util/FieldHash/FieldHash.a
lib/auto/I18N/Langinfo/Langinfo.a lib/auto/IO/IO.a lib/auto/IPC/SysV/SysV.a
lib/auto/List/Util/Util.a lib/auto/MIME/Base64/Base64.a
lib/auto/Math/BigInt/FastCalc/FastCalc.a lib/auto/Opcode/Opcode.a
lib/auto/POSIX/POSIX.a lib/auto/PerlIO/encoding/encoding.a
lib/auto/PerlIO/mmap/mmap.a lib/auto/PerlIO/scalar/scalar.a
lib/auto/PerlIO/via/via.a lib/auto/SDBM_File/SDBM_File.a
lib/auto/Socket/Socket.a lib/auto/Storable/Storable.a
lib/auto/Sys/Hostname/Hostname.a lib/auto/Sys/Syslog/Syslog.a
lib/auto/Tie/Hash/NamedCapture/NamedCapture.a lib/auto/Time/HiRes/HiRes.a
lib/auto/Time/Piece/Piece.a lib/auto/Unicode/Collate/Collate.a
lib/auto/arybase/arybase.a lib/auto/attributes/attributes.a lib/auto/mro/mro.a
lib/auto/re/re.a lib/auto/threads/threads.a lib/auto/threads/shared/shared.a
lib/auto/Encode/Byte/Byte.a lib/auto/Encode/CN/CN.a
lib/auto/Encode/EBCDIC/EBCDIC.a lib/auto/Encode/JP/JP.a lib/auto/Encode/KR/KR.a
lib/auto/Encode/Symbol/Symbol.a lib/auto/Encode/TW/TW.a
lib/auto/Encode/Unicode/Unicode.a libperl.a `cat ext.libs` -lm
/tools/lib/libcrypt.a
lib/auto/POSIX/POSIX.a(POSIX.o): In function `XS_POSIX_tmpnam':
POSIX.c:(.text+0x3654): warning: the use of `tmpnam' is dangerous, better use
`mkstemp'
/mnt/lfs/tools/bin/../lib/gcc/x86_64-unknown-linux-gnu/5.2.0/../../../../lib64/librt.so:
undefined reference to `__pthread_barrier_wait@GLIBC_PRIVATE'
/mnt/lfs/tools/bin/../lib/gcc/x86_64-unknown-linux-gnu/5.2.0/../../../../lib64/librt.so:
undefined reference to `__pthread_barrier_init@GLIBC_PRIVATE'
/lib/x86_64-linux-gnu/libpthread.so.0: undefined reference to
`h_errno@GLIBC_PRIVATE'
collect2: error: ld returned 1 exit status
2) By entering the following command sequence
echo 'main(){}' | gcc -xc -v -Wl,-verbose -lrt - 2>&1 | grep libpthread
libpthread.so.0 needed by
/mnt/lfs/tools/bin/../lib/gcc/x86_64-unknown-linux-gnu/5.2.0/../../../../lib64/librt.so
found libpthread.so.0 at /lib/x86_64-linux-gnu/libpthread.so.0
/lib/x86_64-linux-gnu/libpthread.so.0: undefined reference to
`h_errno@GLIBC_PRIVATE'
The configure command I gave for making binutils was copied directly from the
book
CC=$LFS_TGT-gcc AR=$LFS_TGT-ar
RANLIB=$LFS_TGT-ranlib ../binutils-2.25.1/configure
--prefix=/tools --disable-nls --disable-werror
--with-lib-path=/tools/lib --with-sysroot &>
../buildlogs/secondpass/binutils-2.25.1/configurelog
Here is the tail of the binutils configure output
hecking where to find the target windres... just compiled
checking where to find the target windmc... just compiled
checking whether to enable maintainer-specific portions of Makefiles... no
configure: creating ./config.status
config.status: creating Makefile
Here is the tail of the binutils make
libtool: link: x86_64-lfs-linux-gnu-gcc -W -Wall -Wstrict-prototypes
-Wmissing-prototypes -Wshadow -g -O2 -static-libstdc++ -static-libgcc -o ld-new
ldgram.o ldlex-wrapper.o lexsup.o ldlang.o mri.o ldctor.o ldmain.o ldwrite.o
ldexp.o ldemul.o ldver.o ldmisc.o ldfile.o ldcref.o plugin.o ldbuildid.o
eelf_x86_64.o eelf32_x86_64.o eelf_i386.o ei386linux.o eelf_l1om.o eelf_k1om.o
../bfd/.libs/libbfd.a ../libiberty/libiberty.a -ldl
make[4]: Leaving directory '/mnt/lfs/sources/build/ld'
make[3]: Leaving directory '/mnt/lfs/sources/build/ld'
make[2]: Leaving directory '/mnt/lfs/sources/build/ld'
make[1]: Nothing to be done for 'all-target'.
make[1]: Leaving directory '/mnt/lfs/sources/build'
Here is the tail of the make -C ld clean
test -z "*.o ldscripts/* e*.c ld1 ld2 ld3 ldemul-list.h crtbegin.o crtend.o
ld.log ld.sum" || rm -f *.o ldscripts/* e*.c ld1 ld2 ld3 ldemul-list.h
crtbegin.o crtend.o ld.log ld.sum
rm -f *.lo
rm -rf tmpdir
make[1]: Leaving directory '/mnt/lfs/sources/build/ld'
make: Leaving directory '/mnt/lfs/sources/build/ld'
And here is the tail of make -C ld LIB_PATH=/usr/lib:/lib
libtool: link: x86_64-lfs-linux-gnu-gcc -W -Wall -Wstrict-prototypes
-Wmissing-prototypes -Wshadow -g -O2 -static-libstdc++ -static-libgcc -o ld-new
ldgram.o ldlex-wrapper.o lexsup.o ldlang.o mri.o ldctor.o ldmain.o ldwrite.o
ldexp.o ldemul.o ldver.o ldmisc.o ldfile.o ldcref.o plugin.o ldbuildid.o
eelf_x86_64.o eelf32_x86_64.o eelf_i386.o ei386linux.o eelf_l1om.o eelf_k1om.o
../bfd/.libs/libbfd.a ../libiberty/libiberty.a -ldl
make[2]: Leaving directory '/mnt/lfs/sources/build/ld'
make[1]: Leaving directory '/mnt/lfs/sources/build/ld'
make: Leaving directory '/mnt/lfs/sources/build/ld'
So, everything seems to have gone well with all of that.
What could the problem be? Anyone seen anything like this before?
Daer Semaj
--
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