Opened 20 years ago
Closed 20 years ago
#1061 closed defect (fixed)
Binutils build failure from libc stripped with buggy strip
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | highest | Milestone: | |
Component: | Book | Version: | SVN |
Severity: | blocker | Keywords: | |
Cc: |
Description
LFS-SVN failes to build if the host system has stripped it's libc/a with the buggy strip command from binutils-2.15.94.0.1 or earlier.
Suggested fix:
place a note in the Chapter 5 binutils static build regarding the issue (see below) and recommend dropping the -enable-static and -all-static options from static binutils and gcc respectively
====
Recently a version of the binutils "strip" command had a bug that caused TLS (Thread Local Storage) symbols to be incorrectly dropped from static libraries. In addition, the binutils "ld" command did not warn of this condition when comparing TLS symbols. Newer versions of "ld" now warn of this condition and abort the compilation.
In order to test if your host system has this issue, execute the following commands:
<insert testcase here - there was one in the archives somewhere, but it eldues me ATM>
If your host system is affected, you can workaround the problem by ommiting the LDFLAGS="-all-static" from the make command below, and also the BOOT_LDFLAGS="-static" from the GCC make command in the next section.
=====
We'll need to revist this prior to release, as I understand that Ryan's cross-building toolchain no longer requires static building of binutils and gcc, and may be implemented soon - a more knowledgable toolchain than I will need to make that call however.
Change History (3)
comment:1 by , 20 years ago
Priority: | lowest → highest |
---|---|
Severity: | normal → blocker |
comment:2 by , 20 years ago
Some recent discussions mooted a 7.0 for the cross-lfs stuff, and perhaps a 6.1\6.2 release before then.
If so, putting in the testcase and checking the fix is appropriate sooner rather than later will fix the issue for people building SVN - it can always be taken out later ;)
Thanks again Steve (and to Randy for pestering us to do something about this). Setting as P1 blocker as LFS isn't able to rebuild itself if folks have stripped libc.a. Whilst the text above looks pretty good and is a easy enough workaround, I'm not sure we shouldn't be taking this opportunity to get the book using the cross-lfs work that Ryan has already done.
Incidentally, I found a test case for the problem at http://linuxfromscratch.org/pipermail/lfs-hackers/2004-December/002944.html if we don't go the cross-lfs root just yet.