]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
* tests/mktests.sh: Handle DOS issues: directory separator, single
authorAkim Demaille <akim@epita.fr>
Fri, 26 Jan 2001 11:59:49 +0000 (11:59 +0000)
committerAkim Demaille <akim@epita.fr>
Fri, 26 Jan 2001 11:59:49 +0000 (11:59 +0000)
dot in file names, and one actual bug: when set -e, running
(false; true) will of course fail, use (false || true).
From Tim Van Holder.

ChangeLog
tests/Makefile.in
tests/mktests.sh

index 47cd0d1889c1bb73ea37e8b691b32c95e765de1d..b7cffd01673e8558fc74c63f5c3f75d35ccce04f 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2001-01-26  Akim Demaille  <akim@epita.fr>
+
+       * tests/mktests.sh: Handle DOS issues: directory separator, single
+       dot in file names, and one actual bug: when set -e, running
+       (false; true) will of course fail, use (false || true).
+       From Tim Van Holder.
+
 2001-01-26  Tim Van Holder <tim.van.holder@pandora.be>
 
        * tests/Makefile.am (testsuite): Use testsuite.tmp, not
index fa04a0ca3d1997d5271690fbb4fdec93e3394d40..69037cc1e8d17157f7c69491c6d6c9c8d3a2b578 100644 (file)
@@ -86,7 +86,7 @@ CLEANFILES = debug-*.sh macro configure configure.in configure.ac              c
 DISTCLEANFILES = atconfig testsuite
 mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
 CONFIG_CLEAN_FILES =  atconfig
-DIST_COMMON =  README Makefile.am Makefile.in atconfig.in
+DIST_COMMON =  README Makefile.am Makefile.in atconfig.in configure
 
 
 PACKAGE = @PACKAGE@
@@ -203,9 +203,9 @@ testsuite: $(top_srcdir)/m4sugar.m4 $(top_srcdir)/m4sh.m4 \
            $(SUITE)
        $(M4) -I $(srcdir) -I $(top_srcdir) atspecific.m4 suite.at | \
           sed -e 's/[  ]*$$//' | \
-         sed -e '/^$$/N;/\n$$/D' > $@-tmp
-       chmod +x $@-tmp
-       mv $@-tmp $@
+         sed -e '/^$$/N;/\n$$/D' >$@.tmp
+       chmod +x $@.tmp
+       mv $@.tmp $@
 
 acgeneral.at: mktests.sh $(MACRO_FILES)
        cd $(srcdir) && ./mktests.sh $(MACRO_FILES)
index e498318544508ffe90f99ad8182ba7f484a7c9a6..69251d591cea7eb3fc628c57f4bebe50981d5ed3 100755 (executable)
 # because we used some non portable tool, but we just don't care: this
 # shell script is a maintainer tool, and we do expect good tools.
 
-as_me=`echo "$0" | sed 's,.*/,,'`
+as_me=`echo "$0" | sed 's,.*[\\/],,'`
 
 trap 'echo "'"$as_me"': failed.  To proceed run make check." >&2
-      rm -f acdefuns audefuns requires $as_me.tat
+      rm -f acdefuns audefuns requires *.tat
       for file in "$@"
       do
-        touch `echo "$file" | sed "s,.*/,,;s/\..*/.at/"`
+        touch `echo "$file" | sed "s,.*[\\/],,;s/\..*/.at/"`
       done
       trap 0
       exit 1' \
@@ -71,6 +71,7 @@ cat $src |
 exclude_list='^ac_cv_prog_(gcc|gxx|g77)$
 '
 
+
 # ac_exclude_list
 # ---------------
 # The test `ac-macros.at' tries to run all the macros of Autoconf to check
@@ -171,7 +172,7 @@ au_exclude_egrep=`echo "$exclude_list$au_exclude_list" | tr '
 
 for file in $src
 do
-  base=`echo "$file" | sed 's,.*/,,;s/\..*//'`
+  base=`echo "$file" | sed 's,.*[\\/],,;s/\..*//'`
   # Get the list of macros which are defined in Autoconf level.
   # Get rid of the macros we are not interested in.
   cat $file |
@@ -180,14 +181,14 @@ do
     sort |
     uniq |
     # Watch out we are `set -e': don't fail.
-    ( egrep -v "$ac_exclude_egrep";: ) >acdefuns
+    ( egrep -v "$ac_exclude_egrep" || true) >acdefuns
 
   # Get the list of macros which are defined in Autoupdate level.
   cat $file |
     sed -n 's/^AU_DEFUN(\[*\([a-zA-Z][a-zA-Z0-9_]*\).*$/\1/p' |
     sort |
     uniq |
-    ( egrep -v "$au_exclude_egrep";: ) > audefuns
+    ( egrep -v "$au_exclude_egrep" || true) > audefuns
 
   # Filter out required macros.
   {
@@ -211,11 +212,11 @@ MK_EOF
        echo "AT_CHECK_AU_MACRO([$macro])"
       fi
     done
-  } >$as_me.tat
+  } >$base.tat
 
   # In one atomic step so that if something above fails, the trap
   # preserves the old version of the file.
-  mv $as_me.tat $base.at
+  mv $base.tat $base.at
 done
 
 rm -f acdefuns audefuns requires