* emultempl/elf32.em (gld${EMULATION_NAME}_check_ld_so_conf): Replace
authorAlan Modra <amodra@gmail.com>
Tue, 8 Jan 2013 06:10:39 +0000 (06:10 +0000)
committerAlan Modra <amodra@gmail.com>
Tue, 8 Jan 2013 06:10:39 +0000 (06:10 +0000)
"name" param with a bfd_link_needed_list pointer.  Update caller.
(gld${EMULATION_NAME}_check_ld_elf_hints): Likewise.

ld/ChangeLog
ld/emultempl/elf32.em

index 99f7b5abbe0cc6d3abd256a38bc1a12b7906cafd..70fe12fe072d29da839112987521a2b0e5df33f1 100644 (file)
@@ -1,3 +1,9 @@
+2013-01-08  Alan Modra  <amodra@gmail.com>
+
+       * emultempl/elf32.em (gld${EMULATION_NAME}_check_ld_so_conf): Replace
+       "name" param with a bfd_link_needed_link pointer.  Update caller.
+       (gld${EMULATION_NAME}_check_ld_elf_hints): Likewise.
+
 2013-01-08  Alan Modra  <amodra@gmail.com>
 
        * Makefile.am (ALL_EMULATION_SOURCES): Correct eavrxmega entries.
index d30a0ad40451ad822fa06f201fb9d812ba6b19ae..53d4e24d47051a70c57914c2951333ed8711dc69 100644 (file)
@@ -569,7 +569,8 @@ EOF
 #endif
 
 static bfd_boolean
-gld${EMULATION_NAME}_check_ld_elf_hints (const char *name, int force)
+gld${EMULATION_NAME}_check_ld_elf_hints (const struct bfd_link_needed_list *l,
+                                        int force)
 {
   static bfd_boolean initialized;
   static char *ld_elf_hints;
@@ -612,10 +613,9 @@ gld${EMULATION_NAME}_check_ld_elf_hints (const char *name, int force)
   if (ld_elf_hints == NULL)
     return FALSE;
 
-  needed.by = NULL;
-  needed.name = name;
-  return gld${EMULATION_NAME}_search_needed (ld_elf_hints, & needed,
-                                            force);
+  needed.by = l->by;
+  needed.name = l->name;
+  return gld${EMULATION_NAME}_search_needed (ld_elf_hints, &needed, force);
 }
 EOF
     # FreeBSD
@@ -787,7 +787,8 @@ gld${EMULATION_NAME}_parse_ld_so_conf
 }
 
 static bfd_boolean
-gld${EMULATION_NAME}_check_ld_so_conf (const char *name, int force)
+gld${EMULATION_NAME}_check_ld_so_conf (const struct bfd_link_needed_list *l,
+                                      int force)
 {
   static bfd_boolean initialized;
   static char *ld_so_conf;
@@ -824,8 +825,8 @@ gld${EMULATION_NAME}_check_ld_so_conf (const char *name, int force)
     return FALSE;
 
 
-  needed.by = NULL;
-  needed.name = name;
+  needed.by = l->by;
+  needed.name = l->name;
   return gld${EMULATION_NAME}_search_needed (ld_so_conf, &needed, force);
 }
 
@@ -1308,7 +1309,7 @@ if [ "x${USE_LIBPATH}" = xyes ] ; then
   case ${target} in
     *-*-freebsd* | *-*-dragonfly*)
       fragment <<EOF
-         if (gld${EMULATION_NAME}_check_ld_elf_hints (l->name, force))
+         if (gld${EMULATION_NAME}_check_ld_elf_hints (l, force))
            break;
 EOF
     # FreeBSD
@@ -1317,7 +1318,7 @@ EOF
     *-*-linux-* | *-*-k*bsd*-* | *-*-gnu*)
     # Linux
       fragment <<EOF
-         if (gld${EMULATION_NAME}_check_ld_so_conf (l->name, force))
+         if (gld${EMULATION_NAME}_check_ld_so_conf (l, force))
            break;
 
 EOF