aboutsummaryrefslogtreecommitdiff
path: root/ld/emultempl
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2006-02-09 01:05:10 +0000
committerH.J. Lu <hjl.tools@gmail.com>2006-02-09 01:05:10 +0000
commitc1446dbab7c44c23025d02d045c826ecb4c3de37 (patch)
tree92b51c03980840f741bd5d79a7bf53db60df9286 /ld/emultempl
parent0d47446427843e4f69a7ffbc0fe39341e3ff8f6a (diff)
downloadgdb-c1446dbab7c44c23025d02d045c826ecb4c3de37.zip
gdb-c1446dbab7c44c23025d02d045c826ecb4c3de37.tar.gz
gdb-c1446dbab7c44c23025d02d045c826ecb4c3de37.tar.bz2
2006-02-08 H.J. Lu <hongjiu.lu@intel.com>
PR ld/2290 * NEWS: Updated for the Linux linker search order change. * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Call gld${EMULATION_NAME}_check_ld_so_conf before checking default search directories for DT_NEEDED entries.
Diffstat (limited to 'ld/emultempl')
-rw-r--r--ld/emultempl/elf32.em23
1 files changed, 12 insertions, 11 deletions
diff --git a/ld/emultempl/elf32.em b/ld/emultempl/elf32.em
index 703248a..048917f 100644
--- a/ld/emultempl/elf32.em
+++ b/ld/emultempl/elf32.em
@@ -919,6 +919,18 @@ cat >>e${EMULATION_NAME}.c <<EOF
EOF
fi
+if [ "x${USE_LIBPATH}" = xyes ] ; then
+ case ${target} in
+ *-*-linux-* | *-*-k*bsd*-*)
+ # Linux
+ cat >>e${EMULATION_NAME}.c <<EOF
+ if (gld${EMULATION_NAME}_check_ld_so_conf (l->name, force))
+ break;
+
+EOF
+ ;;
+ esac
+fi
cat >>e${EMULATION_NAME}.c <<EOF
len = strlen (l->name);
for (search = search_head; search != NULL; search = search->next)
@@ -937,17 +949,6 @@ cat >>e${EMULATION_NAME}.c <<EOF
if (search != NULL)
break;
EOF
-if [ "x${USE_LIBPATH}" = xyes ] ; then
- case ${target} in
- *-*-linux-* | *-*-k*bsd*-*)
- cat >>e${EMULATION_NAME}.c <<EOF
- if (gld${EMULATION_NAME}_check_ld_so_conf (l->name, force))
- break;
-EOF
- # Linux
- ;;
- esac
-fi
cat >>e${EMULATION_NAME}.c <<EOF
}