* To get a faithful and correct rebuild, run:
./bootstrap && ./config.status --recheck && make clean all
-* Usually, it is best to run again latest stable versions of Autoconf,
- Libtool, etc., since that is what most users will do. Sometimes it may
- be necessary to use the development versions due to bugs fixed,
- etc. Whatever is first in PATH wins.
+* Usually, it is best to run against the latest stable versions of
+ Autoconf, Libtool, etc., since that is what most users will
+ do. However, sometimes it may be necessary to use the development
+ versions due to bugs fixed, etc. Whatever is first in PATH wins.
(Some background: https://bugs.gnu.org/11347)
* The Automake git tree currently carries three basic branches:
to follow. See the further points below for clarifications and minor
corrections.
- topic: brief description (this is the "summary line")
+ topic: brief description (this is the "summary line").
<reference to relevant bugs, if any>
# nanosecond, matching clock_gettime. However, it is probably not
# possible to delay execution of a shell script for less than one
# millisecond, due to process creation overhead and scheduling
-# granularity, so we don't check for anything finer than that.
+# granularity, so we don't check for anything finer than that. (See below.)
AC_DEFUN([_AM_FILESYSTEM_TIMESTAMP_RESOLUTION], [dnl
AC_REQUIRE([_AM_SLEEP_FRACTIONAL_SECONDS])
-AC_CACHE_CHECK([filesystem timestamp resolution], am_cv_filesystem_timestamp_resolution, [dnl
+AC_CACHE_CHECK([filesystem timestamp resolution],
+ am_cv_filesystem_timestamp_resolution, [dnl
# Default to the worst case.
am_cv_filesystem_timestamp_resolution=2
# Only try to go finer than 1s if sleep can do it.
am_try_resolutions=1
if $am_cv_sleep_fractional_seconds; then
+ # Even a millisecond often causes a bunch of false positives,
+ # so just try a hundredth of a second. The time saved between .001 and
+ # .01 is not terribly consequential.
am_try_resolutions="0.01 0.1 $am_try_resolutions"
fi
: > conftest.ts3
# Make sure ls -t actually works. Do 'set' in a subshell so we don't
-# clobber the current shell's arguments.
+# clobber the current shell's arguments. (Outer-level square brackets
+# are for m4; be careful, it's easy to get confused.)
if (
set X `[ls -t conftest.ts[12]]` &&
{
- test "$[*]" != "X conftest.ts1 conftest.ts2" ||
- test "$[*]" != "X conftest.ts2 conftest.ts1";
+ test "$[]*" != "X conftest.ts1 conftest.ts2" ||
+ test "$[]*" != "X conftest.ts2 conftest.ts1";
}
); then :; else
# If neither matched, then we have a broken ls. This can happen
["Bad output from ls -t: \"`[ls -t conftest.ts[12]]`\""],
[AS_MESSAGE_LOG_FD])
AC_MSG_FAILURE([ls -t produces unexpected output.
-Make sure there is not a broken alias in your environment.])
+Make sure there is not a broken ls alias in your environment.])
fi
for am_try_res in $am_try_resolutions; do
test "$[]2" = conftest.ts3 &&
test "$[]3" = conftest.ts2 &&
test "$[]4" = conftest.ts1); then
- am_cv_filesystem_timestamp_resolution=$am_try_res
- break
+ #
+ # Ok, ls -t worked. We have one more thing to check: make.
+ # It can happen that everything else supports the subsecond mtimes,
+ # but make doesn't, notably on macOS, which ships make 3.81 from
+ # 2006 (the last one released under GPLv2). https://bugs.gnu.org/68808
+ #
+ # So, first let's create a Makefile:
+ rm -f conftest.mk
+ echo 'conftest.ts1: conftest.ts2' >conftest.mk
+ echo ' touch conftest.ts2' >>conftest.mk
+ #
+ # Now, running
+ # touch conftest.ts1; touch conftest.ts2; make
+ # should touch ts1 because ts2 is newer. This could happen by luck,
+ # but most often, it will fail if make's support is insufficient. So
+ # test for several consecutive successes.
+ #
+ # (We reuse conftest.ts[12] because we still want to modify existing
+ # files, not create new ones, per above.)
+ n=0
+ make_ok=true
+ until test $n -eq 4; do
+ echo one > conftest.ts1
+ sleep $am_try_res
+ echo two > conftest.ts2 # ts2 should now be newer than ts1
+ if make -f conftest.mk | grep 'up to date' >/dev/null; then
+ make_ok=false
+ break # out of $n loop
+ fi
+ n=`expr $n + 1`
+ done
+ if $make_ok; then
+ # Everything we know to check worked out, so call this resolution good.
+ am_cv_filesystem_timestamp_resolution=$am_try_res
+ break # out of resolution loop
+ fi
+ # Otherwise, we'll go on to check the next resolution.
fi
done
rm -f conftest.ts?
+# (end _am_filesystem_timestamp_resolution)
])])
# AM_SANITY_CHECK
am_system_acdir=""
;;
*)
- echo "$me: variable 'am_running_installcheck' has invalid"
+ echo "$me: variable 'am_running_installcheck' has invalid" \
"value '$am_running_installcheck'" >&2
exit 99
;;
GNU_GCJ=${AM_TESTSUITE_GNU_GCJ-${GNU_GCJ-'@GNU_GCJ@'}}
GNU_GCJFLAGS=${AM_TESTSUITE_GNU_GCJFLAGS-${GNU_GCJFLAGS-'@GNU_GCJFLAGS@'}}
-# No all versions of Tex support '--version', so we use a configure
+# Not all versions of Tex support '--version', so we use a configure
# check to decide if tex is available. This decision is embodied in
# this variable.
TEX=${AM_TESTSUITE_TEX-'@TEX@'}
grep 'Features:.*subsecond-mtime' > /dev/null 2>&1 &&
$AUTOM4TE --version 2>&1 |
grep 'Features:.*subsecond-mtime' > /dev/null 2>&1; then
- :
+ # subsecond-mtime should be supported; use the timestamp
+ # resolution that we determined. If it hasn't been determined,
+ # that's a bug somewhere.
+ if test -n "$am_cv_filesystem_timestamp_resolution"; then
+ #echo "$me: got $am_cv_filesystem_timestamp_resolution" >&2
+ MTIME_RESOLUTION=$am_cv_filesystem_timestamp_resolution
+ else
+ # ends up in test-suite.log.
+ echo "$me: subsecond-mtime supported per automake and auto4mte" \
+ "--version, but am_cv_filesystem_timestamp_resolution not set;" \
+ "that's an error somewhere. Proceeding with value 1." >&2
+ MTIME_RESOLUTION=1
+ fi
else
+ #echo "$me: --version doesn't support subsecond-mtime" >&2
+ #$AUTOMAKE --version >&2
+ #$AUTOM4TE --version >&2
+ #
MTIME_RESOLUTION=1
# we must not sleep for fractional seconds when autom4te does not
# support subsecond-mtimes, even when sleep supports it. See bug#67670.
esac
# This sleep variable is used explicitly in some tests to avoid
-# too-quick creation. I (Karl) believe that was an incomplete workaround
+# too-quick creation. Seems likely this was an incomplete workaround
# for this whole subsecond-mtime problem. With this set to "sleep 1",
-# there were still random parallelization failures, without also setting
-# am_cv_sleep_fractional_seconds=false as above.
+# there were still random parallelization failures; setting
+# am_cv_sleep_fractional_seconds=false as above was still needed.
#
sleep="sleep $MTIME_RESOLUTION"