ld: Replace --rpath with -Wl,--rpath
authorH.J. Lu <hjl.tools@gmail.com>
Tue, 8 Aug 2017 21:13:46 +0000 (14:13 -0700)
committerH.J. Lu <hjl.tools@gmail.com>
Tue, 8 Aug 2017 21:16:02 +0000 (14:16 -0700)
"--rpath ../bfd/.libs ../bfd/.libs/libbfd.so" isn't a valid compiler
command-line option.  We should use -Wl,--rpath instead of --rpath.

PR ld/21923
* configure.ac (TESTBFDLIB): Replace --rpath with -Wl,--rpath
for --disable-static.
* configure: Regenerated.

ld/ChangeLog
ld/configure
ld/configure.ac

index 645c0fe636cfb45646b824936a6ec6145a235027..65ddf6b145a9a88006c035b59b3769ea2f86452b 100644 (file)
@@ -1,3 +1,10 @@
+2017-08-08  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR ld/21923
+       * configure.ac (TESTBFDLIB): Replace --rpath with -Wl,--rpath
+       for --disable-static.
+       * configure: Regenerated.
+
 2017-08-08  Romain Geissler  <romain.geissler@gmail.com>
            Alan Modra  <amodra@gmail.com>
 
index de709d3a82c82b09e0c65daeaf82ee9d09eaf240..f1d1f0e9e8680367451777f313ec851778792312 100755 (executable)
@@ -17298,7 +17298,7 @@ EMULATION_LIBPATH=$all_libpath
 
 
 if test x${enable_static} = xno; then
-  TESTBFDLIB="--rpath ../bfd/.libs ../bfd/.libs/libbfd.so"
+  TESTBFDLIB="-Wl,--rpath ../bfd/.libs ../bfd/.libs/libbfd.so"
 else
   TESTBFDLIB="../bfd/.libs/libbfd.a"
 fi
index 99d127bd11b367721478158a5f22f470f20fdbcd..9bada13208928cf38561617d88e49ff57a8cd1f8 100644 (file)
@@ -470,7 +470,7 @@ EMULATION_LIBPATH=$all_libpath
 AC_SUBST(EMULATION_LIBPATH)
 
 if test x${enable_static} = xno; then
-  TESTBFDLIB="--rpath ../bfd/.libs ../bfd/.libs/libbfd.so"
+  TESTBFDLIB="-Wl,--rpath ../bfd/.libs ../bfd/.libs/libbfd.so"
 else
   TESTBFDLIB="../bfd/.libs/libbfd.a"
 fi