diff options
author | Alan Modra <amodra@gmail.com> | 2004-01-28 13:31:30 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2004-01-28 13:31:30 +0000 |
commit | 1dd3bf68768e9cbde1b69d64bdc0b8e9203e5f7d (patch) | |
tree | 7d302d9a6b5c958b73a74591f7061872c70f5755 | |
parent | 2a35147e4a88775fe96037345ab9f54fb10d3a1e (diff) | |
download | gdb-1dd3bf68768e9cbde1b69d64bdc0b8e9203e5f7d.zip gdb-1dd3bf68768e9cbde1b69d64bdc0b8e9203e5f7d.tar.gz gdb-1dd3bf68768e9cbde1b69d64bdc0b8e9203e5f7d.tar.bz2 |
* genscripts.sh: Apply $LIBPATH_SUFFIX to $tool_lib and $libdir too.
-rw-r--r-- | ld/ChangeLog | 4 | ||||
-rwxr-xr-x | ld/genscripts.sh | 18 |
2 files changed, 18 insertions, 4 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog index 25d53d6..78682f6 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,7 @@ +2004-01-28 Alan Modra <amodra@bigpond.net.au> + + * genscripts.sh: Apply $LIBPATH_SUFFIX to $tool_lib and $libdir too. + 2004-01-24 Jakub Jelinek <jakub@redhat.com> * emulparams/elf64_ia64.sh: Put .rela.opd into diff --git a/ld/genscripts.sh b/ld/genscripts.sh index 4c7226a..4069d68 100755 --- a/ld/genscripts.sh +++ b/ld/genscripts.sh @@ -128,10 +128,20 @@ fi if [ "x${LIB_PATH}" = "x" ] && [ "x${USE_LIBPATH}" = xyes ] ; then LIB_PATH2= - if [ x"$use_sysroot" != xyes ] ; then - LIB_PATH2=${libdir} + + libs=${NATIVE_LIB_DIRS} + if [ "x${use_sysroot}" != "xyes" ] ; then + case " ${libs} " in + *" ${libdir} "*) ;; + *) libs="${libdir} ${libs}" + esac + case " ${libs} " in + *" ${tool_lib} "*) ;; + *) libs="${tool_lib} ${libs}" + esac fi - for lib in ${NATIVE_LIB_DIRS}; do + + for lib in ${libs}; do # The "=" is harmless if we aren't using a sysroot, but also needless. if [ "x${use_sysroot}" = "xyes" ] ; then lib="=${lib}" @@ -161,13 +171,13 @@ if [ "x${LIB_PATH}" = "x" ] && [ "x${USE_LIBPATH}" = xyes ] ; then esac fi done + case :${LIB_PATH}:${LIB_PATH2}: in *:: | ::*) LIB_PATH=${LIB_PATH}${LIB_PATH2} ;; *) LIB_PATH=${LIB_PATH}:${LIB_PATH2} ;; esac fi - # Always search $(tooldir)/lib, aka /usr/local/TARGET/lib, except for # sysrooted configurations and when LIBPATH=":". if [ "x${use_sysroot}" != "xyes" ] ; then |