+2002-04-07 Alexandre Duret-Lutz <duret_g@epita.fr>
+
+ * Makefile.am (maintainer-check): Check for `sleep 1' uses in the
+ test suite. Suggest `sleep 2' instead.
+ * tests/confsub.test: Use `sleep 2'.
+
2002-04-04 Paul Eggert <eggert@twinsun.com>
* lib/am/subdirs.am:
echo 'the above lines.' 1>&2; \
exit 1; \
fi
+## Never use `sleep 1' to create files with different timestamps.
+## Use `sleep 2' instead. Some filesystems (e.g., Windows') have only
+## a 2sec resolution.
+ @if egrep '\bsleep +1\b' $(srcdir)/tests/*.test; then \
+ echo 'Do not use "sleep 1" in the above tests. Use "sleep 2" instead.' 1>&2; \
+ exit 1; \
+ fi
# Tag before making distribution. Also, don't make a distribution if
# (which will cause the Makefiles to be regenerated when you run `make');
# (2) otherwise, pass the desired values on the `make' command line.
$(RECURSIVE_TARGETS):
- @set fnord $(MAKEFLAGS); amf=$$2; \
+ @set fnord $$MAKEFLAGS; amf=$$2; \
dot_seen=no; \
target=`echo $@ | sed s/-recursive//`; \
list='$(SUBDIRS)'; for subdir in $$list; do \
mostlyclean-recursive clean-recursive distclean-recursive \
maintainer-clean-recursive:
- @set fnord $(MAKEFLAGS); amf=$$2; \
+ @set fnord $$MAKEFLAGS; amf=$$2; \
dot_seen=no; \
case "$@" in \
distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
dir=''; \
fi; \
if test -d $$d/$$file; then \
- cp -pR $$d/$$file $(distdir)$$dir \
- || exit 1; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+ fi; \
+ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
else \
test -f $(distdir)/$$file \
|| cp -p $$d/$$file $(distdir)/$$file \
echo 'the above lines.' 1>&2; \
exit 1; \
fi
+ @if egrep '\bsleep +1\b' $(srcdir)/tests/*.test; then \
+ echo 'Do not use "sleep 1" in the above tests. Use "sleep 2" instead.' 1>&2; \
+ exit 1; \
+ fi
# Tag before making distribution. Also, don't make a distribution if
# checks fail. Also, make sure the NEWS file is up-to-date.