aboutsummaryrefslogtreecommitdiff
path: root/ld/emultempl/armelf.em
diff options
context:
space:
mode:
Diffstat (limited to 'ld/emultempl/armelf.em')
-rw-r--r--ld/emultempl/armelf.em18
1 files changed, 12 insertions, 6 deletions
diff --git a/ld/emultempl/armelf.em b/ld/emultempl/armelf.em
index 6512ee3..ee6aa76 100644
--- a/ld/emultempl/armelf.em
+++ b/ld/emultempl/armelf.em
@@ -193,7 +193,8 @@ gld${EMULATION_NAME}_open_dynamic_archive (arch, search, entry)
EOF
if [ "x${host}" = "x${target}" ] ; then
- if [ "x${DEFAULT_EMULATION}" = "x${EMULATION_NAME}" ] ; then
+ case " ${EMULATION_LIBPATH} " in
+ *" ${EMULATION_NAME} "*)
cat >>e${EMULATION_NAME}.c <<EOF
/* For a native linker, check the file /etc/ld.so.conf for directories
@@ -278,7 +279,8 @@ gld${EMULATION_NAME}_check_ld_so_conf (name, force)
}
EOF
- fi
+ ;;
+ esac
fi
cat >>e${EMULATION_NAME}.c <<EOF
@@ -368,13 +370,15 @@ gld${EMULATION_NAME}_after_open ()
}
EOF
if [ "x${host}" = "x${target}" ] ; then
- if [ "x${DEFAULT_EMULATION}" = "x${EMULATION_NAME}" ] ; then
+ case " ${EMULATION_LIBPATH} " in
+ *" ${EMULATION_NAME} "*)
cat >>e${EMULATION_NAME}.c <<EOF
lib_path = (const char *) getenv ("LD_LIBRARY_PATH");
if (gld${EMULATION_NAME}_search_needed (lib_path, l->name, force))
break;
EOF
- fi
+ ;;
+ esac
fi
cat >>e${EMULATION_NAME}.c <<EOF
len = strlen (l->name);
@@ -394,12 +398,14 @@ cat >>e${EMULATION_NAME}.c <<EOF
break;
EOF
if [ "x${host}" = "x${target}" ] ; then
- if [ "x${DEFAULT_EMULATION}" = "x${EMULATION_NAME}" ] ; then
+ case " ${EMULATION_LIBPATH} " in
+ *" ${EMULATION_NAME} "*)
cat >>e${EMULATION_NAME}.c <<EOF
if (gld${EMULATION_NAME}_check_ld_so_conf (l->name, force))
break;
EOF
- fi
+ ;;
+ esac
fi
cat >>e${EMULATION_NAME}.c <<EOF
}