]> git.ipfire.org Git - thirdparty/libtool.git/commitdiff
* libtool.m4 (AC_PROG_NM): Fix macro so that it
authorMo DeJong <mdejong@redhat.com>
Mon, 10 Jul 2000 09:42:18 +0000 (09:42 +0000)
committerAlexandre Oliva <aoliva@redhat.com>
Mon, 10 Jul 2000 09:42:18 +0000 (09:42 +0000)
finds a cross NM on the PATH.

ChangeLog
libtool.m4

index 8d7fd8f78fe2cab8c94ece6cba980a91e0a78126..de7a81b179d439d3834a0b4728669945f49a02c9 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2000-07-10  Mo DeJong  <mdejong@redhat.com>
+
+       * libtool.m4 (AC_PROG_NM): Fix macro so that it
+       finds a cross NM on the PATH.
+
 2000-07-10  Maciej W. Rozycki  <macro@ds2.pg.gda.pl>
 
        * Makefile.am (libtool): Pass $(host_alias) to ltconfig.
index 35b62736849d295c3fb2c83f7c3e4bff2effc838..6788fe845739935cd3918fca4f92073362f8fc38 100644 (file)
@@ -324,18 +324,19 @@ else
   IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
   for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
     test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/nm || test -f $ac_dir/nm$ac_exeext ; then
+    tmp_nm=$ac_dir/${ac_tool_prefix}nm
+    if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then
       # Check to see if the nm accepts a BSD-compat flag.
       # Adding the `sed 1q' prevents false positives on HP-UX, which says:
       #   nm: unknown option "B" ignored
-      if ($ac_dir/nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
-       ac_cv_path_NM="$ac_dir/nm -B"
+      if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
+       ac_cv_path_NM="$tmp_nm -B"
        break
-      elif ($ac_dir/nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
-       ac_cv_path_NM="$ac_dir/nm -p"
+      elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
+       ac_cv_path_NM="$tmp_nm -p"
        break
       else
-       ac_cv_path_NM=${ac_cv_path_NM="$ac_dir/nm"} # keep the first match, but
+       ac_cv_path_NM=${ac_cv_path_NM="$tmp_nm"} # keep the first match, but
        continue # so that we can try to find one that supports BSD flags
       fi
     fi