From f46876f99ca558a311cf215f9eec26a4db4097e0 Mon Sep 17 00:00:00 2001 From: Geoffrey Keating Date: Fri, 30 Sep 2005 18:08:26 +0000 Subject: [PATCH] t-slibgcc-darwin (libgcc_s_%.dylib): Remove old symlinks before creating new ones. * config/t-slibgcc-darwin (libgcc_s_%.dylib): Remove old symlinks before creating new ones. Do symlinks before creating the actual targets. From-SVN: r104826 --- gcc/ChangeLog | 4 ++++ gcc/config/t-slibgcc-darwin | 15 ++++++++------- 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 58ed17d..00107da 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,9 @@ 2005-09-30 Geoffrey Keating + * config/t-slibgcc-darwin (libgcc_s_%.dylib): Remove old symlinks + before creating new ones. Do symlinks before creating the actual + targets. + * config/t-slibgcc-darwin (libgcc_s_%.dylib): Use --print-multi-lib to work out which multilibs are actually being built. diff --git a/gcc/config/t-slibgcc-darwin b/gcc/config/t-slibgcc-darwin index 3a2fc18..ace3ae9 100644 --- a/gcc/config/t-slibgcc-darwin +++ b/gcc/config/t-slibgcc-darwin @@ -45,6 +45,14 @@ ASM_HIDDEN_OP = .private_extern # # This assumes each multilib corresponds to a different architecture. libgcc_s.%.dylib : $(SHLIB_VERPFX).%.ver libgcc.a + # When builting multilibbed target libraries, all the required + # libraries are expected to exist in the multilib directory. + MLIBS=`$(GCC_FOR_TARGET) --print-multi-lib \ + | sed -e 's/;.*$$//' -e '/^\.$$/d'` ; \ + for mlib in $$MLIBS ; do \ + rm -f $${mlib}/$@ || exit 1 ; \ + $(LN_S) ../$@ $${mlib}/$@ || exit 1 ; \ + done MLIBS=`$(GCC_FOR_TARGET) --print-multi-lib \ | sed -e 's/;.*$$//' -e '/^\.$$/d' -e 's/^/_/'` ; \ for mlib in '' $$MLIBS ; do \ @@ -53,13 +61,6 @@ libgcc_s.%.dylib : $(SHLIB_VERPFX).%.ver libgcc.a libgcc_s$${mlib}.$(SHLIB_SOVERSION)$(SHLIB_EXT) || exit 1 ; \ done $(LIPO_FOR_TARGET) -output $@ -create $(@)_T* - # When builting multilibbed target libraries, all the required - # libraries are expected to exist in the multilib directory. - MLIBS=`$(GCC_FOR_TARGET) --print-multi-lib \ - | sed -e 's/;.*$$//' -e '/^\.$$/d'` ; \ - for mlib in $$MLIBS ; do \ - ln -s ../$@ $${mlib}/$@ || exit 1 ; \ - done rm $(@)_T* # From the point-of-view of the Makefiles, libgcc is built by the 'strip' -- 2.7.4