From 77be14516370de017a2ed0c75f6fd313d9c02dc8 Mon Sep 17 00:00:00 2001 From: Alexandre Duret-Lutz Date: Thu, 31 Jul 2003 21:18:24 +0000 Subject: [PATCH] * lib/depcomp (aix): Support AIX Compiler version 6. --- ChangeLog | 4 ++++ lib/depcomp | 19 +++++++++++++------ 2 files changed, 17 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index bae8e597..70bb4253 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2003-07-31 Ralf Wildenhues (tiny change) + + * lib/depcomp (aix): Support AIX Compiler version 6. + 2003-07-31 Alexandre Duret-Lutz * automake.texi (A Shared Library): Rewrite and split into diff --git a/lib/depcomp b/lib/depcomp index 78a8b992..86f7f153 100755 --- a/lib/depcomp +++ b/lib/depcomp @@ -172,19 +172,25 @@ sgi) aix) # The C for AIX Compiler uses -M and outputs the dependencies - # in a .u file. This file always lives in the current directory. - # Also, the AIX compiler puts `$object:' at the start of each line; - # $object doesn't have directory information. - stripped=`echo "$object" | sed -e 's,^.*/,,' -e 's/\(.*\)\..*$/\1/'` + # in a .u file. In older versions, this file always lives in the + # current directory. Also, the AIX compiler puts `$object:' at the + # start of each line; $object doesn't have directory information. + # Version 6 uses the directory in both cases. + stripped=`echo "$object" | sed 's/\(.*\)\..*$/\1/'` tmpdepfile="$stripped.u" - outname="$stripped.o" if test "$libtool" = yes; then "$@" -Wc,-M else "$@" -M fi - stat=$? + + if test -f "$tmpdepfile"; then : + else + stripped=`echo "$stripped" | sed 's,^.*/,,'` + tmpdepfile="$stripped.u" + fi + if test $stat -eq 0; then : else rm -f "$tmpdepfile" @@ -192,6 +198,7 @@ aix) fi if test -f "$tmpdepfile"; then + outname="$stripped.o" # Each line is of the form `foo.o: dependent.h'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. -- 2.43.5