From d6678f7b3b54edbc136b2fde7c4ca4025f522ff0 Mon Sep 17 00:00:00 2001 From: Vladimir Prus Date: Wed, 29 Mar 2006 11:43:03 +0000 Subject: [PATCH] Merge rpath and strip fixed for OSF from trunk. [SVN r33520] --- src/tools/gcc.jam | 27 ++++++++++++++++++++++++--- 1 file changed, 24 insertions(+), 3 deletions(-) diff --git a/src/tools/gcc.jam b/src/tools/gcc.jam index 6a05c9e6a..4e6551125 100644 --- a/src/tools/gcc.jam +++ b/src/tools/gcc.jam @@ -59,7 +59,15 @@ rule init ( version ? : command * : options * ) local linker = [ feature.get-values : $(options) ] ; if ! $(linker) { - linker = gnu ; + + if [ os.name ] = OSF + { + linker = osf ; + } + else + { + linker = gnu ; + } } init-link-flags gcc $(linker) $(condition) ; @@ -303,6 +311,19 @@ rule init-link-flags ( toolset linker condition ) flags $(toolset).link RPATH $(condition) : : unchecked ; flags $(toolset).link RPATH_LINK $(condition) : : unchecked ; } + + case osf : + { + # No --strip-all, just -s + flags $(toolset).link OPTIONS $(condition)/off : -Wl,-s + : unchecked ; + + flags $(toolset).link RPATH $(condition) : : unchecked ; + # This does not supports -R + flags $(toolset).link RPATH_OPTION $(condition) : -rpath : unchecked ; + # -rpath-link is not supported at all. + } + case sun : { @@ -345,7 +366,7 @@ rule link ( targets * : sources * : properties * ) actions link bind LIBRARIES { - "$(CONFIG_COMMAND)" -L"$(LINKPATH)" -Wl,-R$(SPACE)-Wl,"$(RPATH)" -Wl,-rpath-link$(SPACE)-Wl,"$(RPATH_LINK)" -o "$(<)" "$(>)" "$(LIBRARIES)" -l$(FINDLIBS-ST) -l$(FINDLIBS-SA) $(OPTIONS) $(USER_OPTIONS) + "$(CONFIG_COMMAND)" -L"$(LINKPATH)" -Wl,$(RPATH_OPTION:E=-R)$(SPACE)-Wl,"$(RPATH)" -Wl,-rpath-link$(SPACE)-Wl,"$(RPATH_LINK)" -o "$(<)" "$(>)" "$(LIBRARIES)" -l$(FINDLIBS-ST) -l$(FINDLIBS-SA) $(OPTIONS) $(USER_OPTIONS) } @@ -403,7 +424,7 @@ rule link.dll ( targets * : sources * : properties * ) # Differ from 'link' above only by -shared. actions link.dll bind LIBRARIES { - "$(CONFIG_COMMAND)" -L"$(LINKPATH)" -Wl,-R$(SPACE)-Wl,"$(RPATH)" -o "$(<)" $(HAVE_SONAME)-Wl,$(SONAME_OPTION)$(SPACE)-Wl,$(<[1]:D=) -shared "$(>)" "$(LIBRARIES)" -l$(FINDLIBS-ST) -l$(FINDLIBS-SA) $(OPTIONS) $(USER_OPTIONS) + "$(CONFIG_COMMAND)" -L"$(LINKPATH)" -Wl,$(RPATH_OPTION:E=-R)$(SPACE)-Wl,"$(RPATH)" -o "$(<)" $(HAVE_SONAME)-Wl,$(SONAME_OPTION)$(SPACE)-Wl,$(<[1]:D=) -shared "$(>)" "$(LIBRARIES)" -l$(FINDLIBS-ST) -l$(FINDLIBS-SA) $(OPTIONS) $(USER_OPTIONS) } # Set up threading support. It's somewhat contrived, so perform it at the end,