diff options
author | Rich Felker <dalias@aerifal.cx> | 2015-11-04 21:40:36 -0500 |
---|---|---|
committer | Rich Felker <dalias@aerifal.cx> | 2015-11-04 21:40:36 -0500 |
commit | 6a851e3ab8a1ae524b2aa6218615ec1c86528e9c (patch) | |
tree | cdd197834c833b4a5a050c7b2bb12826484e9397 /configure | |
parent | 2efd38e8c70f00ca6bbc1eb5199aa507d45436cf (diff) | |
download | musl-6a851e3ab8a1ae524b2aa6218615ec1c86528e9c.tar.gz musl-6a851e3ab8a1ae524b2aa6218615ec1c86528e9c.tar.bz2 musl-6a851e3ab8a1ae524b2aa6218615ec1c86528e9c.tar.xz musl-6a851e3ab8a1ae524b2aa6218615ec1c86528e9c.zip |
have configure check/add --gc-sections linker option
this allowing the linker to drop certain weak definitions that are
only used as dummies for static linking. they could be eliminated for
shared library builds using the preprocessor instead, but we are
trying to transition to using the same object files for shared and
static libc, so a link-time solution is preferable.
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -521,6 +521,10 @@ fi tryldflag LDFLAGS_AUTO -Wl,--sort-section,alignment tryldflag LDFLAGS_AUTO -Wl,--sort-common +# When linking shared library, drop dummy weak definitions that were +# replaced by strong definitions from other translation units. +tryldflag LDFLAGS_AUTO -Wl,--gc-sections + # Some patched GCC builds have these defaults messed up... tryldflag LDFLAGS_AUTO -Wl,--hash-style=both |