Linux From ScratchThis Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
configure: WARNING:
*** These auxiliary programs are missing or incompatible versions: autoconf
*** some features will be disabled.
*** Check the INSTALL file for required versions.
checking LD_LIBRARY_PATH variable... ok
checking whether GCC supports -static-libgcc... -static-libgcc
checking for bash... /bin/bash
checking for perl... /usr/bin/perl
checking for install-info... /tools/bin/install-info
checking for bison... no
checking for libc-friendly stddef.h... yes
checking whether we need to use -P to assemble .S files... no
checking for .set assembler directive... yes
checking for assembler gnu_unique_object symbol type... yes
checking for .symver assembler directive... yes
checking for ld --version-script... yes
checking for .previous assembler directive... yes
checking for .protected and .hidden assembler directive... yes
checking whether __attribute__((visibility())) is supported... yes
checking for broken __attribute__((visibility()))... no
checking for broken __attribute__((alias()))... no
checking whether to put _rtld_local into .sdata section... no
checking for .preinit_array/.init_array/.fini_array support... ../glibc-2.17/configure: line 6142: /usr/bin/readelf: No such file or directory
no
configure: error: Need linker with .init_array/.fini_array support.
Quote:
root:/sources/7.3/glibc-build# cat config.log
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by GNU C Library configure (see version.h), which was
generated by GNU Autoconf 2.68. Invocation command line was
configure:2366: checking build system type
configure:2380: result: i686-pc-linux-gnu
configure:2400: checking host system type
configure:2413: result: i686-pc-linux-gnu
configure:2482: checking for gcc
configure:2498: found /tools/bin/gcc
configure:2509: result: gcc
configure:2738: checking for C compiler version
configure:2747: gcc --version >&5
gcc (GCC) 4.7.2
Copyright (C) 2012 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
configure:2758: $? = 0
configure:2747: gcc -v >&5
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/tools/libexec/gcc/i686-pc-linux-gnu/4.7.2/lto-wrapper
Target: i686-pc-linux-gnu
Configured with: ../gcc-4.7.2/configure --prefix=/tools --with-local-prefix=/tools --with-native-system-header-dir=/tools/include --enable-clocale=gnu --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-languages=c,c++ --disable-libstdcxx-pch --disable-multilib --disable-bootstrap --disable-libgomp --with-mpfr-include=/mnt/lfs/sources/7.3/gcc-build2/../gcc-4.7.2/mpfr/src --with-mpfr-lib=/mnt/lfs/sources/7.3/gcc-build2/mpfr/src/.libs : (reconfigured) ../gcc-4.7.2/configure --prefix=/tools --with-local-prefix=/tools --with-native-system-header-dir=/tools/include --enable-clocale=gnu --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-languages=c,c++ --disable-libstdcxx-pch --disable-multilib --disable-bootstrap --disable-libgomp --with-mpfr-include=/mnt/lfs/sources/7.3/gcc-build2/../gcc-4.7.2/mpfr/src --with-mpfr-lib=/mnt/lfs/sources/7.3/gcc-build2/mpfr/src/.libs
Thread model: posix
gcc version 4.7.2 (GCC)
configure:2758: $? = 0
configure:2747: gcc -V >&5
gcc: error: unrecognized command line option '-V'
gcc: fatal error: no input files
compilation terminated.
configure:2758: $? = 1
configure:2747: gcc -qversion >&5
gcc: error: unrecognized command line option '-qversion'
gcc: fatal error: no input files
compilation terminated.
configure:2758: $? = 1
configure:2763: checking for suffix of object files
configure:2785: gcc -c conftest.c >&5
configure:2789: $? = 0
configure:2810: result: o
configure:2814: checking whether we are using the GNU C compiler
configure:2833: gcc -c conftest.c >&5
configure:2833: $? = 0
configure:2842: result: yes
configure:2851: checking whether gcc accepts -g
configure:2871: gcc -c -g conftest.c >&5
configure:2871: $? = 0
configure:2912: result: yes
configure:2929: checking for gcc option to accept ISO C89
configure:2993: gcc -c -g -O2 conftest.c >&5
configure:2993: $? = 0
configure:3006: result: none needed
configure:3076: checking how to run the C preprocessor
configure:3107: gcc -E conftest.c
configure:3107: $? = 0
configure:3121: gcc -E conftest.c
conftest.c:11:28: fatal error: ac_nonexistent.h: No such file or directory
compilation terminated.
configure:3121: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "GNU C Library"
| #define PACKAGE_TARNAME "glibc"
| #define PACKAGE_VERSION "(see version.h)"
| #define PACKAGE_STRING "GNU C Library (see version.h)"
| #define PACKAGE_BUGREPORT "http://sourceware.org/bugzilla/"
| #define PACKAGE_URL "http://www.gnu.org/software/glibc/"
| #define PKGVERSION "(GNU libc) "
| #define REPORT_BUGS_TO "<http://www.gnu.org/software/libc/bugs.html>"
| /* end confdefs.h. */
| #include <ac_nonexistent.h>
configure:3146: result: gcc -E
configure:3166: gcc -E conftest.c
configure:3166: $? = 0
configure:3180: gcc -E conftest.c
conftest.c:11:28: fatal error: ac_nonexistent.h: No such file or directory
compilation terminated.
configure:3180: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "GNU C Library"
| #define PACKAGE_TARNAME "glibc"
| #define PACKAGE_VERSION "(see version.h)"
| #define PACKAGE_STRING "GNU C Library (see version.h)"
| #define PACKAGE_BUGREPORT "http://sourceware.org/bugzilla/"
| #define PACKAGE_URL "http://www.gnu.org/software/glibc/"
| #define PKGVERSION "(GNU libc) "
| #define REPORT_BUGS_TO "<http://www.gnu.org/software/libc/bugs.html>"
| /* end confdefs.h. */
| #include <ac_nonexistent.h>
configure:3267: checking for g++
configure:3283: found /tools/bin/g++
configure:3294: result: g++
configure:3321: checking for C++ compiler version
configure:3330: g++ --version >&5
g++ (GCC) 4.7.2
Copyright (C) 2012 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
configure:3341: $? = 0
configure:3330: g++ -v >&5
Using built-in specs.
COLLECT_GCC=g++
COLLECT_LTO_WRAPPER=/tools/libexec/gcc/i686-pc-linux-gnu/4.7.2/lto-wrapper
Target: i686-pc-linux-gnu
Configured with: ../gcc-4.7.2/configure --prefix=/tools --with-local-prefix=/tools --with-native-system-header-dir=/tools/include --enable-clocale=gnu --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-languages=c,c++ --disable-libstdcxx-pch --disable-multilib --disable-bootstrap --disable-libgomp --with-mpfr-include=/mnt/lfs/sources/7.3/gcc-build2/../gcc-4.7.2/mpfr/src --with-mpfr-lib=/mnt/lfs/sources/7.3/gcc-build2/mpfr/src/.libs : (reconfigured) ../gcc-4.7.2/configure --prefix=/tools --with-local-prefix=/tools --with-native-system-header-dir=/tools/include --enable-clocale=gnu --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-languages=c,c++ --disable-libstdcxx-pch --disable-multilib --disable-bootstrap --disable-libgomp --with-mpfr-include=/mnt/lfs/sources/7.3/gcc-build2/../gcc-4.7.2/mpfr/src --with-mpfr-lib=/mnt/lfs/sources/7.3/gcc-build2/mpfr/src/.libs
Thread model: posix
gcc version 4.7.2 (GCC)
configure:3341: $? = 0
configure:3330: g++ -V >&5
g++: error: unrecognized command line option '-V'
g++: fatal error: no input files
compilation terminated.
configure:3341: $? = 1
configure:3330: g++ -qversion >&5
g++: error: unrecognized command line option '-qversion'
g++: fatal error: no input files
compilation terminated.
configure:3341: $? = 1
configure:3345: checking whether we are using the GNU C++ compiler
configure:3364: g++ -c conftest.cpp >&5
configure:3364: $? = 0
configure:3373: result: yes
configure:3382: checking whether g++ accepts -g
configure:3402: g++ -c -g conftest.cpp >&5
configure:3402: $? = 0
configure:3443: result: yes
configure:3509: checking for readelf
configure:3525: found /usr/bin/readelf
configure:3536: result: readelf
configure:3998: checking for sysdeps preconfigure fragments
configure:4005: result:
configure:4079: running configure fragment for add-on libidn
configure:4079: running configure fragment for add-on nptl
configure:4127: checking add-on ports for preconfigure fragments
configure:4134: result:
configure:4215: checking for assembler and linker STT_GNU_IFUNC support
configure:4246: result: yes
configure:4249: checking whether .text pseudo-op must be used
configure:4259: gcc -c conftest.s 1>&5
configure:4262: $? = 0
configure:4273: result: yes
configure:4291: checking sysdep dirs
configure:4505: result: sysdeps/generic
configure:4559: WARNING: add-on ports contributed no useful sysdeps directories
configure:4582: checking for a BSD-compatible install
configure:4650: result: /tools/bin/install -c
configure:4665: checking whether ln -s works
configure:4669: result: yes
configure:4693: checking whether /tools/lib/gcc/i686-pc-linux-gnu/4.7.2/../../../../i686-pc-linux-gnu/bin/as is GNU as
configure:4707: result: yes
configure:4712: checking whether /tools/lib/gcc/i686-pc-linux-gnu/4.7.2/../../../../i686-pc-linux-gnu/bin/ld is GNU ld
configure:4726: result: yes
configure:4736: checking for /tools/lib/gcc/i686-pc-linux-gnu/4.7.2/../../../../i686-pc-linux-gnu/bin/as
configure:4763: result: /tools/lib/gcc/i686-pc-linux-gnu/4.7.2/../../../../i686-pc-linux-gnu/bin/as
configure:4778: checking version of /tools/lib/gcc/i686-pc-linux-gnu/4.7.2/../../../../i686-pc-linux-gnu/bin/as
configure:4788: result: 2.23.1, ok
configure:4799: checking for /tools/lib/gcc/i686-pc-linux-gnu/4.7.2/../../../../i686-pc-linux-gnu/bin/ld
configure:4826: result: /tools/lib/gcc/i686-pc-linux-gnu/4.7.2/../../../../i686-pc-linux-gnu/bin/ld
configure:4841: checking version of /tools/lib/gcc/i686-pc-linux-gnu/4.7.2/../../../../i686-pc-linux-gnu/bin/ld
configure:4851: result: 2.23.1, ok
configure:4865: checking for gcc
configure:4892: result: gcc
configure:4907: checking version of gcc
configure:4917: result: 4.7.2, ok
configure:4928: checking for gnumake
configure:4958: result: no
configure:4928: checking for gmake
configure:4958: result: no
configure:4928: checking for make
configure:4944: found /tools/bin/make
configure:4955: result: make
configure:4970: checking version of make
configure:4980: result: 3.82, ok
configure:4992: checking for gnumsgfmt
configure:5022: result: no
configure:4992: checking for gmsgfmt
configure:5022: result: no
configure:4992: checking for msgfmt
configure:5008: found /tools/bin/msgfmt
configure:5019: result: msgfmt
configure:5034: checking version of msgfmt
configure:5044: result: 0.18.2, ok
configure:5055: checking for makeinfo
configure:5071: found /tools/bin/makeinfo
configure:5082: result: makeinfo
configure:5097: checking version of makeinfo
configure:5107: result: 5.0, ok
configure:5118: checking for sed
configure:5134: found /tools/bin/sed
configure:5145: result: sed
configure:5160: checking version of sed
configure:5170: result: 4.2.2, ok
configure:5181: checking for gawk
configure:5197: found /tools/bin/gawk
configure:5208: result: gawk
configure:5223: checking version of gawk
configure:5233: result: 4.0.2, ok
configure:5284: checking for nm
configure:5300: found /usr/bin/nm
configure:5311: result: nm
configure:5338: checking for autoconf
configure:5368: result: no
configure:5407: WARNING:
*** These auxiliary programs are missing or incompatible versions: autoconf
*** some features will be disabled.
*** Check the INSTALL file for required versions.
configure:5443: checking LD_LIBRARY_PATH variable
configure:5453: result: ok
configure:5462: checking whether GCC supports -static-libgcc
configure:5473: result: -static-libgcc
configure:5479: checking for bash
configure:5497: found /bin/bash
configure:5510: result: /bin/bash
configure:5583: checking for perl
configure:5601: found /usr/bin/perl
configure:5614: result: /usr/bin/perl
configure:5628: checking for install-info
configure:5647: found /tools/bin/install-info
configure:5660: result: /tools/bin/install-info
configure:5670: checking for bison
configure:5702: result: no
configure:5711: checking for libc-friendly stddef.h
configure:5735: gcc -c -g -O2 conftest.c >&5
conftest.c: In function 'main':
conftest.c:26:38: warning: incompatible implicit declaration of built-in function 'abort' [enabled by default]
configure:5735: $? = 0
configure:5742: result: yes
configure:5749: checking whether we need to use -P to assemble .S files
configure:5759: gcc -c conftest.S 1>&5
configure:5762: $? = 0
configure:5770: result: no
configure:5777: checking for .set assembler directive
configure:5803: result: yes
configure:5810: checking for assembler gnu_unique_object symbol type
configure:5827: result: yes
configure:5834: checking for .symver assembler directive
configure:5851: result: yes
configure:5853: checking for ld --version-script
configure:5879: gcc -g -O2 -shared
-o conftest.so conftest.o
-nostartfiles -nostdlib
-Wl,--version-script,conftest.map
1>&5
configure:5882: $? = 0
configure:5897: result: yes
configure:5918: checking for .previous assembler directive
configure:5928: gcc -c conftest.s 1>&5
configure:5931: $? = 0
configure:5939: result: yes
configure:5973: checking for .protected and .hidden assembler directive
configure:5985: gcc -c conftest.s 1>&5
configure:5988: $? = 0
configure:5996: result: yes
configure:6000: checking whether __attribute__((visibility())) is supported
configure:6011: gcc -Werror -S conftest.c -o conftest.s 1>&5
configure:6014: $? = 0
configure:6025: result: yes
configure:6033: checking for broken __attribute__((visibility()))
configure:6045: gcc -Werror -S conftest.c -o conftest.s 1>&5
configure:6048: $? = 0
configure:6057: result: no
configure:6064: checking for broken __attribute__((alias()))
configure:6079: gcc -Werror -S conftest.c -o conftest.s 1>&5
configure:6082: $? = 0
configure:6092: result: no
configure:6099: checking whether to put _rtld_local into .sdata section
configure:6113: result: no
configure:6121: checking for .preinit_array/.init_array/.fini_array support
configure:6137: gcc -g -O2 -o conftest
conftest.c -static -nostartfiles -nostdlib
1>&5
configure:6140: $? = 0
configure:6153: result: no
configure:6156: error: Need linker with .init_array/.fini_array support.
I found out that /usr/bin/readelf exists but when I run it, it says
no such file or directory even though file exists.
also there is readelf exists under /tools/bin.
so I deleted /usr/bin/readelf and create link to /tools/bin dir one.
I don't know why there are two different file that has the same name across in the /usr/bin and /tool/bin.
I found out that /usr/bin/readelf exists but when I run it, it says
no such file or directory even though file exists.
also there is readelf exists under /tools/bin.
so I deleted /usr/bin/readelf and create link to /tools/bin dir one.
I don't know why there are two different file that has the same name across in the /usr/bin and /tool/bin.
At this point there shouldn't be a readelf present in /usr/bin.
You installed /tools/bin/readelf in chapter 5.8. Binutils-2.23.1 - Pass 2, this one is used until the new one (6.13. Binutils-2.23.1)is installed. After you chroot (6.4. Entering the Chroot Environment) there should be only 1 readelf available, the one in /tools/bin
It looks like you have back-traced and are redoing previous chapters.
drunna, Thanks for the advice,
I checked time stamp of the file under /usr/bin and seems I did something not followed the direction on LFS Book.
Maybe I should do it again from scratch.
If you have made a backup as suggested in chapter 5.34, you can take that as a starting point (remove all in $LFS, restore backup and start with chapter 6)
EDIT: That is assuming nothing went wrong in chapter 5.....
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.