]> sourceware.org Git - automake.git/commitdiff
2001-02-03 Ville Laurikari <vlaurika@hutcs.cs.hut.fi>
authorTom Tromey <tromey@redhat.com>
Sun, 4 Feb 2001 03:51:18 +0000 (03:51 +0000)
committerTom Tromey <tromey@redhat.com>
Sun, 4 Feb 2001 03:51:18 +0000 (03:51 +0000)
* depcomp (aix): New side-effect dependency tracking mode, for
the C for AIX compiler.
* m4/depend.m4 (AM_DEPENDENCIES): Recreate `conftest.c' and
`conftest.h' for each test.

ChangeLog
depcomp
lib/depcomp
m4/depend.m4

index 7c9aafe5620215878b37c779237bb5912c592e1c..e58cccc5eb7b1232e1a56ed422e29b2b21180f7a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2001-02-03  Ville Laurikari <vlaurika@hutcs.cs.hut.fi>
+
+       * depcomp (aix): New side-effect dependency tracking mode, for
+       the C for AIX compiler.
+       * m4/depend.m4 (AM_DEPENDENCIES): Recreate `conftest.c' and
+       `conftest.h' for each test.
+
 2001-02-03  Tom Tromey  <tromey@redhat.com>
 
        * automake.texi (Dist): Updated to mention caveat of putting
diff --git a/depcomp b/depcomp
index 3014997348153d33cdf7f2d93323b1548e6e243a..b0f2e97db90d62a61fbf54e64f5c17b9f556d20f 100755 (executable)
--- a/depcomp
+++ b/depcomp
@@ -159,6 +159,20 @@ sgi)
   rm -f "$tmpdepfile"
   ;;
 
+aix)
+  # The C for AIX Compiler uses -M and outputs the dependencies
+  # in a .u file.
+  tmpdepfile=`echo "$object" | sed 's/\(.*\)\..*$/\1.u/'`
+  if test "$libtool" = yes; then
+    "$@" -Wc,-M
+  else
+    "$@" -M
+  fi
+  if test $? -eq 0 && test -f "$tmpdepfile"; then
+    mv "$tmpdepfile" "$depfile"
+  fi
+  ;;
+
 #nosideeffect)
   # This comment above is used by automake to tell side-effect
   # dependency tracking mechanisms from slower ones.
index 3014997348153d33cdf7f2d93323b1548e6e243a..b0f2e97db90d62a61fbf54e64f5c17b9f556d20f 100755 (executable)
@@ -159,6 +159,20 @@ sgi)
   rm -f "$tmpdepfile"
   ;;
 
+aix)
+  # The C for AIX Compiler uses -M and outputs the dependencies
+  # in a .u file.
+  tmpdepfile=`echo "$object" | sed 's/\(.*\)\..*$/\1.u/'`
+  if test "$libtool" = yes; then
+    "$@" -Wc,-M
+  else
+    "$@" -M
+  fi
+  if test $? -eq 0 && test -f "$tmpdepfile"; then
+    mv "$tmpdepfile" "$depfile"
+  fi
+  ;;
+
 #nosideeffect)
   # This comment above is used by automake to tell side-effect
   # dependency tracking mechanisms from slower ones.
index d4aea487bf9433cdcbd13f1a3b955b1f5cb5079b..8f63a3d642b0256aa8d51a68aa564e7729d84d54 100644 (file)
@@ -38,11 +38,15 @@ AC_CACHE_CHECK([dependency style of $depcc],
   # in D'.
   mkdir confdir
   cd confdir
-  echo '#include "conftest.h"' > conftest.c
-  echo 'int i;' > conftest.h
 
   am_cv_$1_dependencies_compiler_type=none
   for depmode in `sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < "$am_depcomp"`; do
+    # We need to recreate these files for each test, as the compiler may
+    # overwrite some of them when testing with obscure command lines.
+    # This happens at least with the AIX C compiler.
+    echo '#include "conftest.h"' > conftest.c
+    echo 'int i;' > conftest.h
+
     case "$depmode" in
     nosideeffect)
       # after this tag, mechanisms are not by side-effect, so they'll
This page took 0.035876 seconds and 5 git commands to generate.