This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[libgcc, build] Don't build libgcc-unwind.map with --disable-shared (PR libgcc/61097)
- From: Rainer Orth <ro at CeBiTec dot Uni-Bielefeld dot DE>
- To: gcc-patches at gcc dot gnu dot org
- Date: Thu, 08 May 2014 14:14:31 +0200
- Subject: [libgcc, build] Don't build libgcc-unwind.map with --disable-shared (PR libgcc/61097)
- Authentication-results: sourceware.org; auth=none
As reported in the PR, libgcc fails to build on Solaris with
--disable-shared: the creation of libgcc-unwind.map depends on
libgcc-std.ver which isn't built in this case.
Fixed as follows, tested by verifying that a --disable-shared
i386-pc-solaris2.10 build gets into stage2 without trying to build map
files, while a default (i.e. --enable-shared) build still correctly
builds the maps.
Installed on mainline; will backport to the 4.9 branch in a few days.
Rainer
2014-05-08 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
PR libgcc/61097
* config/t-slibgcc-sld: Only build and install libgcc-unwind.map
if --enable-shared.
# HG changeset patch
# Parent 8b4f4776ed04d118977a300b92559035f3b7a49b
Don't build libgcc-unwind.map with --disable-shared (PR libgcc/61097)
diff --git a/libgcc/config/t-slibgcc-sld b/libgcc/config/t-slibgcc-sld
--- a/libgcc/config/t-slibgcc-sld
+++ b/libgcc/config/t-slibgcc-sld
@@ -4,6 +4,8 @@
SHLIB_LDFLAGS = -Wl,-h,$(SHLIB_SONAME) -Wl,-z,text -Wl,-z,defs \
-Wl,-M,$(SHLIB_MAP)
+ifeq ($(enable_shared),yes)
+
# Linker mapfile to enforce direct binding to libgcc_s unwinder
# (PR target/59788).
libgcc-unwind.map: libgcc-std.ver
@@ -26,3 +28,5 @@ install-libgcc-unwind-map: libgcc-unwind
$(INSTALL_DATA) $< $(DESTDIR)$(slibdir)
install: install-libgcc-unwind-map
+
+endif
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University