summaryrefslogtreecommitdiff
path: root/ld/testsuite/config/default.exp
diff options
context:
space:
mode:
authorH.J. Lu <hjl@lucon.org>2003-05-16 05:04:34 +0000
committerH.J. Lu <hjl@lucon.org>2003-05-16 05:04:34 +0000
commit5cd5a3ce3e34d2f6929dc3a5bd9bae9496c85888 (patch)
tree6acc2c9035b9858de87cce9b65aa87b91d9d2acb /ld/testsuite/config/default.exp
parentce3f48481780e407ba0f76ca7e47fbd70048ecb4 (diff)
downloadbinutils-redhat-5cd5a3ce3e34d2f6929dc3a5bd9bae9496c85888.tar.gz
2003-05-15 H.J. Lu <hongjiu.lu@intel.com>
* config/default.exp (gcc_ld_flag): New. Make the newly built linker available to gcc. * lib/ld-lib.exp (default_ld_simple_link): Pass $gcc_ld_flag to gcc. * ld-elfvers/vers.exp: Use "ld_simple_link $CC" to build shared libraries. * ld-elfvsb/elfvsb.exp: Likewise. * ld-elfweak/elfweak.exp: Likewise. * ld-shared/shared.exp: Likewise. * ld-elfvers/vers.exp: Use "-Wl,-rpath,." to build shared libraries. * ld-elfvsb/elfvsb.exp: Likewise. * ld-elfvsb/elfvsb.exp: Remove xfail for powerpc-*-linux*. * ld-elfweak/elfweak.exp: Use PIC for shared libraries.
Diffstat (limited to 'ld/testsuite/config/default.exp')
-rw-r--r--ld/testsuite/config/default.exp9
1 files changed, 9 insertions, 0 deletions
diff --git a/ld/testsuite/config/default.exp b/ld/testsuite/config/default.exp
index 432a1a8d0a..e883e875c4 100644
--- a/ld/testsuite/config/default.exp
+++ b/ld/testsuite/config/default.exp
@@ -60,6 +60,15 @@ if {![file isdirectory tmpdir/gas]} then {
}
set gcc_gas_flag "-B[pwd]/tmpdir/gas/"
+# Make a symlink from tmpdir/ld to the linker in the build tree, so
+# that we can use a -B option to gcc to force it to use the newly
+# built linker.
+if {![file isdirectory tmpdir/ld]} then {
+ catch "exec mkdir tmpdir/ld" status
+ catch "exec ln -s ../../ld-new tmpdir/ld/ld" status
+}
+set gcc_ld_flag "-B[pwd]/tmpdir/ld/"
+
# The mips64-*-linux-gnu compiler defaults to the N32 ABI after
# installed, but to the O32 ABI in the build tree, because of some
# specs-file hacks. Make sure we use an ABI that is compatible with