aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/libgcc/config/t-slibgcc-sld
diff options
context:
space:
mode:
Diffstat (limited to 'gcc-4.9/libgcc/config/t-slibgcc-sld')
-rw-r--r--gcc-4.9/libgcc/config/t-slibgcc-sld28
1 files changed, 28 insertions, 0 deletions
diff --git a/gcc-4.9/libgcc/config/t-slibgcc-sld b/gcc-4.9/libgcc/config/t-slibgcc-sld
new file mode 100644
index 000000000..ec6e5db0a
--- /dev/null
+++ b/gcc-4.9/libgcc/config/t-slibgcc-sld
@@ -0,0 +1,28 @@
+# Build a shared libgcc library for ELF with symbol versioning
+# with the Solaris linker.
+
+SHLIB_LDFLAGS = -Wl,-h,$(SHLIB_SONAME) -Wl,-z,text -Wl,-z,defs \
+ -Wl,-M,$(SHLIB_MAP)
+
+# Linker mapfile to enforce direct binding to libgcc_s unwinder
+# (PR target/59788).
+libgcc-unwind.map: libgcc-std.ver
+ @(echo "{"; \
+ for f in `grep _Unwind_ $< | sort`; do \
+ echo " $$f = EXTERN DIRECT;"; \
+ done; \
+ echo "};" ) > $@
+
+# Copy libgcc-unwind.map to the place where gcc will look for it at build-time.
+install-libgcc-unwind-map-forbuild: libgcc-unwind.map
+ dest=$(gcc_objdir)/tmp$$$$-$<; \
+ cp $< $$dest; \
+ chmod a+r $$dest; \
+ sh $(srcdir)/../move-if-change $$dest $(gcc_objdir)/$<
+
+all: install-libgcc-unwind-map-forbuild
+
+install-libgcc-unwind-map: libgcc-unwind.map
+ $(INSTALL_DATA) $< $(DESTDIR)$(slibdir)
+
+install: install-libgcc-unwind-map