diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2017-08-30 21:26:53 -0700 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2017-08-31 04:04:20 -0700 |
commit | 953d46ebe8cf0bf24c78b7ab0306cd035d413411 (patch) | |
tree | 285b5a5129f3236eacf8cce4fec98d356c5ddf6e | |
parent | 4fa9b3bfe6759c82beb4b043a54a3598ca467289 (diff) | |
download | glibc-hjl/pr22051/master.tar.gz |
Place $(elf-objpfx)sofini.os last [BZ #22051]hjl/pr22051/master
Since sofini.os terminates .eh_frame section, it should be placed last.
[BZ #22051]
* Makerules (build-module-helper-objlist): Filter out
$(elf-objpfx)sofini.os.
(build-shlib-objlist): Append $(elf-objpfx)sofini.os if it is
needed.
-rw-r--r-- | Makerules | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -686,14 +686,17 @@ $(build-module-helper) -o $@ $(shlib-lds-flags) \ $(call after-link,$@) endef +# sofini.os must be placed last since it terminates .eh_frame section. build-module-helper-objlist = \ $(patsubst %_pic.a,$(whole-archive) %_pic.a $(no-whole-archive),\ $(filter-out %.lds $(map-file) $(+preinit) $(+postinit) \ + $(elf-objpfx)sofini.os \ $(link-libc-deps),$^)) build-module-objlist = $(build-module-helper-objlist) $(LDLIBS-$(@F:%.so=%).so) build-shlib-objlist = $(build-module-helper-objlist) \ - $(LDLIBS-$(@F:lib%.so=%).so) + $(LDLIBS-$(@F:lib%.so=%).so) \ + $(filter $(elf-objpfx)sofini.os,$^) # Don't try to use -lc when making libc.so itself. # Also omits crti.o and crtn.o, which we do not want |