]> git.ipfire.org Git - thirdparty/libtool.git/commitdiff
ltconfig.in : Under AIX 4&5 check $NM for GNUness and remove -C if so.
authorRobert Boehne <rboehne@ricardo-us.com>
Thu, 15 Feb 2001 21:55:40 +0000 (21:55 +0000)
committerRobert Boehne <rboehne@gnu.org>
Thu, 15 Feb 2001 21:55:40 +0000 (21:55 +0000)
ChangeLog
ltconfig.in

index 04a86f3d9d02d4d6a1f85f6409772a43363d6902..c4886b623989b9056ca671ca15443cd953961e8d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2001-02-15  Robert Boehne  <rboehne@ricardo-us.com>
+       
+       * ltconfig.in: Under AIX 4&5 check to see if we're using
+        GNU nm, if so, remove -C from the options to $NM.  The -C
+        is required to demangle with AIX nm, but -C means don't
+        demangle to GNU nm.
+
 2001-02-15  Robert Boehne  <rboehne@ricardo-us.com>
        
        * ltcf-cxx.sh: Only check for broken collect2 under
index 35cccef0d4b6286964d857949a0d1e79f9c91972..f41cfb73c9e6f1db2572663e1606021f0c803390 100755 (executable)
@@ -964,7 +964,13 @@ aix4* | aix5*)
       library_names_spec='${libname}${release}.a $libname.a'
       soname_spec='${libname}${release}.so$major.o'
     fi
-    export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
+    # If we're using GNU nm, then we don't want the "-C" option.
+    # -C means demangle to AIX nm, but means don't demangle with GNU nm
+    if $NM -V 2>&1 | egrep '(GNU)' > /dev/null; then
+      export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
+    else
+      export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
+    fi
     shlibpath_var=LIBPATH
     deplibs_check_method='pass_all'
   fi