diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2017-08-31 06:28:31 -0700 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2017-09-07 09:19:33 -0700 |
commit | c71ddec7b314d4da5397508516983e0a9e831711 (patch) | |
tree | 06ed16eea4bd2b9da1a7a7231f7cfd9e27d5e171 | |
parent | bc5ace67fe9823757532e0273f6c1cdfda065433 (diff) | |
download | glibc-c71ddec7b314d4da5397508516983e0a9e831711.tar.gz |
Place $(elf-objpfx)sofini.os last [BZ #22051]
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.
(cherry picked from commit ecd0747df388f3925d4839740b0abcf43d0a9fb2)
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | Makerules | 5 |
2 files changed, 12 insertions, 1 deletions
@@ -1,3 +1,11 @@ +2017-08-31 H.J. Lu <hongjiu.lu@intel.com> + + [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. + 2017-07-29 Torvald Riegel <triegel@redhat.com> Carlos O'Donell <carlos@redhat.com> @@ -669,14 +669,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 |