From 6dd8c765d3c328fb2b86fcf2afa9efaf9a235470 Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Wed, 23 Aug 2000 23:03:00 +0000 Subject: [PATCH] 2000-08-23 H.J. Lu * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Get the current runpath list from bfd_elf_get_runpath_list () before search. --- ld/ChangeLog | 6 ++++++ ld/emultempl/elf32.em | 50 ++++++++++++++------------------------------------ 2 files changed, 20 insertions(+), 36 deletions(-) diff --git a/ld/ChangeLog b/ld/ChangeLog index 0335d58..245b262 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,9 @@ +2000-08-23 H.J. Lu + + * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Get + the current runpath list from bfd_elf_get_runpath_list () + before search. + 2000-08-22 H.J. Lu * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Search diff --git a/ld/emultempl/elf32.em b/ld/emultempl/elf32.em index dee6e8c..9698e9f 100644 --- a/ld/emultempl/elf32.em +++ b/ld/emultempl/elf32.em @@ -570,34 +570,11 @@ static void gld${EMULATION_NAME}_after_open () { struct bfd_link_needed_list *needed, *l; -EOF -if [ "x${host}" = "x${target}" ] ; then - case " ${EMULATION_LIBPATH} " in - *" ${EMULATION_NAME} "*) -cat >>e${EMULATION_NAME}.c <>e${EMULATION_NAME}.c <>e${EMULATION_NAME}.c <>e${EMULATION_NAME}.c <>e${EMULATION_NAME}.c <>e${EMULATION_NAME}.c <>e${EMULATION_NAME}.c <next) @@ -658,6 +623,18 @@ cat >>e${EMULATION_NAME}.c <>e${EMULATION_NAME}.c <>e${EMULATION_NAME}.c <name, force)) @@ -683,7 +660,8 @@ cat >>e${EMULATION_NAME}.c <next) + rp = bfd_elf_get_runpath_list (output_bfd, &link_info); + for (; !found && rp != NULL; rp = rp->next) { found = (rp->by == l->by && gld${EMULATION_NAME}_search_needed (rp->name, -- 2.7.4