]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
Alexandre's suggestions.
authorAkim Demaille <akim@epita.fr>
Mon, 10 Jul 2000 14:03:12 +0000 (14:03 +0000)
committerAkim Demaille <akim@epita.fr>
Mon, 10 Jul 2000 14:03:12 +0000 (14:03 +0000)
* autoreconf.sh (update.sh): Use `ls -1dt' instead of `-lt'.
Use test instead of sed.
<automake>: If automake is used, always run it: it has its own
mechanism not to update if unneeded.

ChangeLog
autoreconf.in
autoreconf.sh
bin/autoreconf.in
doc/make-stds.texi

index cf7445f1ac5239b8cf4b4ad1ecc10064b0c98e72..061a8f8e34d69122b06b601c4c19256c376da941 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2000-07-10  Akim Demaille  <akim@epita.fr>
+
+       Alexandre's suggestions.
+
+       * autoreconf.sh (update.sh): Use `ls -1dt' instead of `-lt'.
+       Use test instead of sed.
+       <automake>: If automake is used, always run it: it has its own
+       mechanism not to update if unneeded.
+
 2000-07-10  Akim Demaille  <akim@epita.fr>
 
        * acspecific.m4 (_AC_PROG_ECHO): Modernize.
index 6b862db4abff1ffc6c5129eb3e39794bd336a58b..f2cf832f953f0fd544c216d10793defc7235fc48 100644 (file)
@@ -251,14 +251,9 @@ EOF
 
 # update.sh --
 # Exit 0 iff the first argument is not the most recent of all or is missing.
-# FIXME: Why do we need -l?  Dropping it would allow using fgrep.
 cat >$tmp/update.sh <<\EOF
 test -f "$1" || exit 0
-ls -lt "$@" |
-  sed 1q |
-  # This is not exact: we should be quoting the `.' etc. in $1.
-  grep "$1$" >/dev/null 2>&1 || exit 0
-exit 1
+test x`ls -1dt "$@" | sed 1q` != x"$1"
 EOF
 update="@SHELL@ $tmp/update.sh"
 
@@ -316,8 +311,10 @@ while read dir; do
   uses_automake=false
   test -f "Makefile.am" &&
     uses_automake=:
-  if $uses_automake &&
-     { $force || $install || $update Makefile.in Makefile.am; } then
+  # We should always run automake, and let it decide whether it shall
+  # update the file or not.  In fact, the effect of `$force' is already
+  # included in `$automake' via `--no-force'.
+  if $uses_automake; then
     $verbose running $automake in $dir >&2
     $automake
   fi
index 6b862db4abff1ffc6c5129eb3e39794bd336a58b..f2cf832f953f0fd544c216d10793defc7235fc48 100644 (file)
@@ -251,14 +251,9 @@ EOF
 
 # update.sh --
 # Exit 0 iff the first argument is not the most recent of all or is missing.
-# FIXME: Why do we need -l?  Dropping it would allow using fgrep.
 cat >$tmp/update.sh <<\EOF
 test -f "$1" || exit 0
-ls -lt "$@" |
-  sed 1q |
-  # This is not exact: we should be quoting the `.' etc. in $1.
-  grep "$1$" >/dev/null 2>&1 || exit 0
-exit 1
+test x`ls -1dt "$@" | sed 1q` != x"$1"
 EOF
 update="@SHELL@ $tmp/update.sh"
 
@@ -316,8 +311,10 @@ while read dir; do
   uses_automake=false
   test -f "Makefile.am" &&
     uses_automake=:
-  if $uses_automake &&
-     { $force || $install || $update Makefile.in Makefile.am; } then
+  # We should always run automake, and let it decide whether it shall
+  # update the file or not.  In fact, the effect of `$force' is already
+  # included in `$automake' via `--no-force'.
+  if $uses_automake; then
     $verbose running $automake in $dir >&2
     $automake
   fi
index 6b862db4abff1ffc6c5129eb3e39794bd336a58b..f2cf832f953f0fd544c216d10793defc7235fc48 100644 (file)
@@ -251,14 +251,9 @@ EOF
 
 # update.sh --
 # Exit 0 iff the first argument is not the most recent of all or is missing.
-# FIXME: Why do we need -l?  Dropping it would allow using fgrep.
 cat >$tmp/update.sh <<\EOF
 test -f "$1" || exit 0
-ls -lt "$@" |
-  sed 1q |
-  # This is not exact: we should be quoting the `.' etc. in $1.
-  grep "$1$" >/dev/null 2>&1 || exit 0
-exit 1
+test x`ls -1dt "$@" | sed 1q` != x"$1"
 EOF
 update="@SHELL@ $tmp/update.sh"
 
@@ -316,8 +311,10 @@ while read dir; do
   uses_automake=false
   test -f "Makefile.am" &&
     uses_automake=:
-  if $uses_automake &&
-     { $force || $install || $update Makefile.in Makefile.am; } then
+  # We should always run automake, and let it decide whether it shall
+  # update the file or not.  In fact, the effect of `$force' is already
+  # included in `$automake' via `--no-force'.
+  if $uses_automake; then
     $verbose running $automake in $dir >&2
     $automake
   fi
index f935158a5db13265b7a6773154fa0ec34874fa6b..8824e4f5557825fcc163003e6bd3f2b5f6edc190 100644 (file)
@@ -140,7 +140,7 @@ installation should not use any utilities directly except these:
 \r
 @c dd find\r
 @c gunzip gzip md5sum\r
-@c mkfifo mknod tee uname \r
+@c mkfifo mknod tee uname\r
 \r
 @example\r
 cat cmp cp diff echo egrep expr false grep install-info\r