Readjusted linker issues etc.
robertmbaker at gmail.com
Sun May 17 18:09:10 PDT 2009
As I mentioned the other day I did go ahead and build the temp system
again. This time I used linux-220.127.116.11 along with the corresponding
grsec patch. I have had no issues I can trace back to the kernel
includes. So at least early on that looks good.
I was experiencing problems with the re-adjusted linker before I
rebuilt the temporary system, but didn't look at it much because I was
trying to document the reboot procedure. These same issues did crop
back up on my latest rebuild. Taking a look at the ld-new that we
copy into /tools/bin during binutils-pass2 I found it was considerably
smaller than expected. Reading the file with a text editor shed some
light on my problems.
# ld-new - temporary wrapper script for .libs/ld-new
# Generated by ltmain.sh (GNU libtool 1.2435 2007/03/18 18:44:42) 2.1a
# The ld-new program cannot be directly executed until all the libtool
# libraries that it depends on are installed.
# This wrapper script should never be moved out of the build directory.
# If it is, it will not operate correctly.
Going back to my binutils obj/ directory and executing the below
commad installed a working re-adjusted linker.
make -C ld install
I haven't explored a solution that doesn't require keeping the build
directory from the previous chapter just yet. Instead I have been
reviewing the test suite failures that I am experiencing later in the
build. Running the following for the binutils test suite results in a
small handfull of errors.
make CFLAGS="-fPIC -fno-stack-protector -U_FORTIFY_SOURCE -nonow
-nopie" -k check
FAIL: run objcopy of executable
FAIL: run stripped executable
FAIL: run stripped executable with saving a symbol
FAIL: objdump -W
FAIL: readelf -wa (compressed)
FAIL: Check --gc-section/-r/-u
FAIL: NOCROSSREFS 3
FAIL: S-records with constructors
The good news is with similar CFLAGS, and
LDFLAGS="-Wl,-no-fatal-warning" all the glibc tests pass.
More information about the hlfs-dev