From unknown Sun Jun 22 00:59:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13107: timestamp bug when files are created just before make is run Resent-From: Mikulas Patocka Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-automake@gnu.org Resent-Date: Thu, 06 Dec 2012 22:18:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 13107 X-GNU-PR-Package: automake X-GNU-PR-Keywords: To: bug-make@gnu.org, 13107@debbugs.gnu.org X-Debbugs-Original-To: bug-make@gnu.org, bug-automake@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.135483226311583 (code B ref -1); Thu, 06 Dec 2012 22:18:02 +0000 Received: (at submit) by debbugs.gnu.org; 6 Dec 2012 22:17:43 +0000 Received: from localhost ([127.0.0.1]:57431 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TgjlG-00030l-Hv for submit@debbugs.gnu.org; Thu, 06 Dec 2012 17:17:43 -0500 Received: from eggs.gnu.org ([208.118.235.92]:46483) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TgjXI-0002gC-3g for submit@debbugs.gnu.org; Thu, 06 Dec 2012 17:03:17 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TgjWy-0001Sr-P3 for submit@debbugs.gnu.org; Thu, 06 Dec 2012 17:03:01 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:55901) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgjWy-0001Sn-My for submit@debbugs.gnu.org; Thu, 06 Dec 2012 17:02:56 -0500 Received: from eggs.gnu.org ([208.118.235.92]:57797) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgjWv-0007cs-RT for bug-automake@gnu.org; Thu, 06 Dec 2012 17:02:56 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TgjWs-0001R1-5x for bug-automake@gnu.org; Thu, 06 Dec 2012 17:02:53 -0500 Received: from artax.karlin.mff.cuni.cz ([195.113.26.195]:40212) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgjWr-0001Qs-Vn; Thu, 06 Dec 2012 17:02:50 -0500 Received: by artax.karlin.mff.cuni.cz (Postfix, from userid 17421) id 269FA98070; Thu, 6 Dec 2012 23:02:48 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by artax.karlin.mff.cuni.cz (Postfix) with ESMTP id 239A398062; Thu, 6 Dec 2012 23:02:48 +0100 (CET) Date: Thu, 6 Dec 2012 23:02:48 +0100 (CET) From: Mikulas Patocka Message-ID: User-Agent: Alpine 2.00 (DEB 1167 2008-08-23) X-Personality-Disorder: Schizoid MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -4.2 (----) X-Mailman-Approved-At: Thu, 06 Dec 2012 17:17:42 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.2 (----) Hi Try this Makefile: --- a : b echo build a touch a b : c echo build b touch b --- and run this script: touch b;sleep 1;touch a c;make You see "echo build b build b touch b" but it doesn't remake a. The apparent problem is that after make rebuilds b, it compares b's time with a's time, finds that the times are equal (because a was touched just before make was run) and doesn't rebuild a. I think it is a bug - when b is finished, make should find out whether the rule for b modified the file b (if b's time is greater or equal than the time when the rule for b was started, then b may have been modified) and rebuild a in this case. --- This bug is causing real-world problems in automake-generated Makefiles. This is a simplified piece of Makefile from automake: all : config.h $(MAKE) all-am config.h : stamp-h1 echo build config.h stamp-h1 : config.h.in echo build stamp-h1 rm -f stamp-h1 touch config.h touch stamp-h1 config.h.in : am__configure_deps echo build config.h.in rm -f stamp-h1 touch config.h.in all-am : echo ALL-AM Now, if you run this script, you trigger the bug: touch config.h.in;sleep 1;touch am__configure_deps;sleep 1;touch config.h stamp-h1;make - you see "build config.h.in", but the other files are not rebuild and all-am is executed (the essential thing to trigger the bug is that make is run in the same second in which config.h and stamp-h1 were created) The problem that really happens in a real build: * The user runs autoheader && aclocal && automake && autoconf && ./configure && make -j4 * Configure runs ./config.status, ./config.status writes config.h and stamp-h1 * Make sees that am__configure_deps is newer than config.h.in * Make runs the rule for config.h.in. It sets the new timestamp for config.h.in and deletes stamp-h1 * Now make sees that config.h.in has the same time as stamp-h1 (the timestamp is read from make's cache even if stamp-h1 no longer exists) * Because of the same timestamp, make doesn't run the commands for stamp-h1 and config.h * Make executes a subprocess to build the rule all-am * The subprocess doesn't have the file cache of the parent process, so the subprocess knows that stamp-h1 is missing * The subprocess sees a dependency config.h->stamp-h1, stamp-h1 doesn't exist * The subprocess executes the rule for stamp-h1 which regenerates config.h - the problem is that this rule is executed in parallel with other rules that build C files that include config.h - changing config.h while it is being used results in build failure Another possible solution for this bug would be to remove rm -f stamp-h1 from config.h.in rule, but there is some complex explanation in /usr/local/share/automake-1.12/am/remake-hdr.am why rm -f stamp-h1 is there so it would likely fix one bug and trigger another one. So it would be better to fix this in make. Mikulas From unknown Sun Jun 22 00:59:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13107: timestamp bug when files are created just before make is run Resent-From: Philip Guenther Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-automake@gnu.org Resent-Date: Fri, 07 Dec 2012 00:24:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13107 X-GNU-PR-Package: automake X-GNU-PR-Keywords: To: Mikulas Patocka Cc: 13107@debbugs.gnu.org, bug-make@gnu.org X-Debbugs-Original-Cc: bug-automake@gnu.org, bug-make@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.135483981722582 (code B ref -1); Fri, 07 Dec 2012 00:24:01 +0000 Received: (at submit) by debbugs.gnu.org; 7 Dec 2012 00:23:37 +0000 Received: from localhost ([127.0.0.1]:57495 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tglj6-0005sA-Iv for submit@debbugs.gnu.org; Thu, 06 Dec 2012 19:23:37 -0500 Received: from eggs.gnu.org ([208.118.235.92]:36782) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TglGW-0005Cv-Ej for submit@debbugs.gnu.org; Thu, 06 Dec 2012 18:54:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TglGF-0003m4-R4 for submit@debbugs.gnu.org; Thu, 06 Dec 2012 18:53:48 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-102.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, T_DKIM_INVALID, USER_IN_WHITELIST autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:53277) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TglGB-0003kw-WF for submit@debbugs.gnu.org; Thu, 06 Dec 2012 18:53:47 -0500 Received: from eggs.gnu.org ([208.118.235.92]:48118) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TglGA-0005LM-Rh for bug-automake@gnu.org; Thu, 06 Dec 2012 18:53:43 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TglG9-0003j3-8Y for bug-automake@gnu.org; Thu, 06 Dec 2012 18:53:42 -0500 Received: from mail-qa0-f41.google.com ([209.85.216.41]:48732) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TglG9-0003iz-4j; Thu, 06 Dec 2012 18:53:41 -0500 Received: by mail-qa0-f41.google.com with SMTP id o19so1683305qap.0 for ; Thu, 06 Dec 2012 15:53:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=gGibXBWXDSdVfUvFXh4tSuIxtk8ghq5UW1oFnc1uNGo=; b=vWfxUTkVIprjSHXvfjsCu3T90vnk5LFJmNC7aLagQWpfoCmG+19ND2yzFWlCVaYLf4 nqS8CZE7HOpRBkcEH4wv6NNNJteMjms5w0Mb7hMioLzTCbpUiQUMeog2d0Zab39Wjkn+ zOFnpNNK0ttz4+L02tjqenZHbE1Y2uKhZbnVqQ5O9p3DZzP8Ay83DNfasYl/mKx26T3b gkJ5svzAcR4DDkgVQUWPX6Lstgl4bV5I25fnm+4YC3xqkXo1Vhn/XM3Xv7a2am/fjQpY 1FXUt/rfdUEqY/vRhdKRTJNeWvoFBqKTMRV/C3rO6u3HAjm3QcuoktjTXqw6p3I8+9WT V9/w== MIME-Version: 1.0 Received: by 10.229.205.18 with SMTP id fo18mr1248169qcb.24.1354838020433; Thu, 06 Dec 2012 15:53:40 -0800 (PST) Received: by 10.49.25.232 with HTTP; Thu, 6 Dec 2012 15:53:40 -0800 (PST) In-Reply-To: References: Date: Thu, 6 Dec 2012 15:53:40 -0800 Message-ID: From: Philip Guenther Content-Type: text/plain; charset=ISO-8859-1 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -3.4 (---) X-Mailman-Approved-At: Thu, 06 Dec 2012 19:23:35 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.2 (----) On Thu, Dec 6, 2012 at 2:02 PM, Mikulas Patocka wrote: > The apparent problem is that after make rebuilds b, it compares b's time > with a's time, finds that the times are equal (because a was touched just > before make was run) and doesn't rebuild a. > > I think it is a bug - when b is finished, make should find out whether the > rule for b modified the file b (if b's time is greater or equal than the > time when the rule for b was started, then b may have been modified) and > rebuild a in this case. That's not the rule that make has always followed and, indeed, is required by the standard to follow. To quote POSIX: The make utility attempts to perform the actions required to ensure that the specified targets are up-to-date. A target is considered out-of-date if it is older than any of its prerequisites or if it does not exist. The make utility shall treat all prerequisites as targets themselves and recursively ensure that they are up-to-date, processing them in the order in which they appear in the rule. The make utility shall use the modification times of files to determine whether the corresponding targets are out-of-date. The fact that the timestamp on a prerequisite has changed do *not* mean that it's newer than the target; it may have been copied from some other file which, while newer, is still older than the target file. So the change to the make algorithm described in the paragraph above that starts "I think it is a bug" would not be correct; something more precise about what timestamps would be considered "newer" would be necessary. Note that this problem doesn't arise on systems with high precision file timestamps. Many systems have provided those since the mid 90's; I'm appalled that the modern system that process the involved shell commands fast enough for this to regularly be a problem don't provide microsecond or better timestamp precision. > This bug is causing real-world problems in automake-generated Makefiles. > This is a simplified piece of Makefile from automake: > all : config.h > $(MAKE) all-am > > config.h : stamp-h1 > echo build config.h > > stamp-h1 : config.h.in > echo build stamp-h1 > rm -f stamp-h1 > touch config.h > touch stamp-h1 > > config.h.in : am__configure_deps > echo build config.h.in > rm -f stamp-h1 > touch config.h.in > > all-am : > echo ALL-AM > > Now, if you run this script, you trigger the bug: > > touch config.h.in;sleep 1;touch am__configure_deps;sleep 1;touch config.h stamp-h1;make > > - you see "build config.h.in", but the other files are not rebuild and > all-am is executed > (the essential thing to trigger the bug is that make is run in the same > second in which config.h and stamp-h1 were created) ... > Another possible solution for this bug would be to remove rm -f stamp-h1 > from config.h.in rule, but there is some complex explanation in > /usr/local/share/automake-1.12/am/remake-hdr.am why rm -f stamp-h1 is > there so it would likely fix one bug and trigger another one. Hmm, adding a "sleep 1" after that rm -f and before the touch config.h.in would work without reintroducing the issue described in that explanation, no? Philip Guenther From unknown Sun Jun 22 00:59:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13107: timestamp bug when files are created just before make is run Resent-From: Mikulas Patocka Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-automake@gnu.org Resent-Date: Fri, 07 Dec 2012 01:57:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13107 X-GNU-PR-Package: automake X-GNU-PR-Keywords: To: Philip Guenther Cc: 13107@debbugs.gnu.org, bug-make@gnu.org X-Debbugs-Original-Cc: bug-automake@gnu.org, bug-make@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.135484537930623 (code B ref -1); Fri, 07 Dec 2012 01:57:01 +0000 Received: (at submit) by debbugs.gnu.org; 7 Dec 2012 01:56:19 +0000 Received: from localhost ([127.0.0.1]:57548 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TgnAo-0007xr-NE for submit@debbugs.gnu.org; Thu, 06 Dec 2012 20:56:19 -0500 Received: from eggs.gnu.org ([208.118.235.92]:54926) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TgnAm-0007xk-8O for submit@debbugs.gnu.org; Thu, 06 Dec 2012 20:56:17 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TgnAS-0007p0-RQ for submit@debbugs.gnu.org; Thu, 06 Dec 2012 20:56:00 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:52277) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgnAS-0007or-OC for submit@debbugs.gnu.org; Thu, 06 Dec 2012 20:55:56 -0500 Received: from eggs.gnu.org ([208.118.235.92]:38034) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgnAP-0002li-Um for bug-automake@gnu.org; Thu, 06 Dec 2012 20:55:56 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TgnAM-0007oB-ST for bug-automake@gnu.org; Thu, 06 Dec 2012 20:55:53 -0500 Received: from artax.karlin.mff.cuni.cz ([195.113.26.195]:38542) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgnAM-0007o2-Cd; Thu, 06 Dec 2012 20:55:50 -0500 Received: by artax.karlin.mff.cuni.cz (Postfix, from userid 17421) id E794498070; Fri, 7 Dec 2012 02:55:48 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by artax.karlin.mff.cuni.cz (Postfix) with ESMTP id E158898062; Fri, 7 Dec 2012 02:55:48 +0100 (CET) Date: Fri, 7 Dec 2012 02:55:48 +0100 (CET) From: Mikulas Patocka In-Reply-To: Message-ID: References: User-Agent: Alpine 2.00 (DEB 1167 2008-08-23) X-Personality-Disorder: Schizoid MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -4.2 (----) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.2 (----) On Thu, 6 Dec 2012, Philip Guenther wrote: > On Thu, Dec 6, 2012 at 2:02 PM, Mikulas Patocka > wrote: > > The apparent problem is that after make rebuilds b, it compares b's time > > with a's time, finds that the times are equal (because a was touched just > > before make was run) and doesn't rebuild a. > > > > I think it is a bug - when b is finished, make should find out whether the > > rule for b modified the file b (if b's time is greater or equal than the > > time when the rule for b was started, then b may have been modified) and > > rebuild a in this case. > > That's not the rule that make has always followed and, indeed, is > required by the standard to follow. To quote POSIX: > > The make utility attempts to perform the actions required to ensure > that the specified targets are up-to-date. A target is considered > out-of-date if it is older than any of its prerequisites or if > it does not > exist. The make utility shall treat all prerequisites as targets > themselves and recursively ensure that they are up-to-date, processing > them in the order in which they appear in the rule. The make utility > shall use the modification times of files to determine whether the > corresponding targets are out-of-date. > > The fact that the timestamp on a prerequisite has changed do *not* > mean that it's newer than the target; it may have been copied from > some other file which, while newer, is still older than the target > file. So the change to the make algorithm described in the paragraph > above that starts "I think it is a bug" would not be correct; > something more precise about what timestamps would be considered > "newer" would be necessary. > > > Note that this problem doesn't arise on systems with high precision > file timestamps. Many systems have provided those since the mid 90's; > I'm appalled that the modern system that process the involved shell > commands fast enough for this to regularly be a problem don't provide > microsecond or better timestamp precision. Yes, but it is very counterintuitive to remake file "b" and not remake file "a" that depends on "b" when asked to make file "a". It may be ok according to the standard, but not what the user wants. > > This bug is causing real-world problems in automake-generated Makefiles. > > This is a simplified piece of Makefile from automake: > > all : config.h > > $(MAKE) all-am > > > > config.h : stamp-h1 > > echo build config.h > > > > stamp-h1 : config.h.in > > echo build stamp-h1 > > rm -f stamp-h1 > > touch config.h > > touch stamp-h1 > > > > config.h.in : am__configure_deps > > echo build config.h.in > > rm -f stamp-h1 > > touch config.h.in > > > > all-am : > > echo ALL-AM > > > > Now, if you run this script, you trigger the bug: > > > > touch config.h.in;sleep 1;touch am__configure_deps;sleep 1;touch config.h stamp-h1;make > > > > - you see "build config.h.in", but the other files are not rebuild and > > all-am is executed > > (the essential thing to trigger the bug is that make is run in the same > > second in which config.h and stamp-h1 were created) > ... > > Another possible solution for this bug would be to remove rm -f stamp-h1 > > from config.h.in rule, but there is some complex explanation in > > /usr/local/share/automake-1.12/am/remake-hdr.am why rm -f stamp-h1 is > > there so it would likely fix one bug and trigger another one. > > Hmm, adding a "sleep 1" after that rm -f and before the touch > config.h.in would work without reintroducing the issue described in > that explanation, no? > > > Philip Guenther Yes it fixes it, you can add "sleep 1" to automake there, that fixes the bug. Mikulas From unknown Sun Jun 22 00:59:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13107: timestamp bug when files are created just before make is run Resent-From: Mikulas Patocka Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-automake@gnu.org Resent-Date: Fri, 07 Dec 2012 02:17:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13107 X-GNU-PR-Package: automake X-GNU-PR-Keywords: To: Philip Guenther Cc: 13107@debbugs.gnu.org, bug-make@gnu.org X-Debbugs-Original-Cc: bug-automake@gnu.org, bug-make@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.13548466213310 (code B ref -1); Fri, 07 Dec 2012 02:17:01 +0000 Received: (at submit) by debbugs.gnu.org; 7 Dec 2012 02:17:01 +0000 Received: from localhost ([127.0.0.1]:57557 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TgnUq-0000rK-Iu for submit@debbugs.gnu.org; Thu, 06 Dec 2012 21:17:01 -0500 Received: from eggs.gnu.org ([208.118.235.92]:57491) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TgnUo-0000rC-2X for submit@debbugs.gnu.org; Thu, 06 Dec 2012 21:16:58 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TgnUU-0004Nf-Ot for submit@debbugs.gnu.org; Thu, 06 Dec 2012 21:16:42 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:55609) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgnUU-0004NY-LQ for submit@debbugs.gnu.org; Thu, 06 Dec 2012 21:16:38 -0500 Received: from eggs.gnu.org ([208.118.235.92]:40603) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgnUR-0005z4-I5 for bug-automake@gnu.org; Thu, 06 Dec 2012 21:16:38 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TgnUO-0004N8-RY for bug-automake@gnu.org; Thu, 06 Dec 2012 21:16:35 -0500 Received: from artax.karlin.mff.cuni.cz ([195.113.26.195]:36785) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgnUO-0004N3-Kf; Thu, 06 Dec 2012 21:16:32 -0500 Received: by artax.karlin.mff.cuni.cz (Postfix, from userid 17421) id 19CE498070; Fri, 7 Dec 2012 03:16:31 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by artax.karlin.mff.cuni.cz (Postfix) with ESMTP id 135A798062; Fri, 7 Dec 2012 03:16:31 +0100 (CET) Date: Fri, 7 Dec 2012 03:16:31 +0100 (CET) From: Mikulas Patocka In-Reply-To: Message-ID: References: User-Agent: Alpine 2.00 (DEB 1167 2008-08-23) X-Personality-Disorder: Schizoid MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -4.2 (----) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.2 (----) On Thu, 6 Dec 2012, Philip Guenther wrote: > Note that this problem doesn't arise on systems with high precision > file timestamps. Many systems have provided those since the mid 90's; > I'm appalled that the modern system that process the involved shell > commands fast enough for this to regularly be a problem don't provide > microsecond or better timestamp precision. BTW. on Linux, high precision timestamps have really kernel-tick precision, not nanosecond precision. So the first example that I posted doesn't always work correctly on Linux with 100HZ tick - with sufficiently fast computer, touch "a" and the rule to make "b" is executed in the same tick - so "a" isn't rebuilt. Mikulas From unknown Sun Jun 22 00:59:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13107: timestamp bug when files are created just before make is run Resent-From: Andreas Schwab Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-automake@gnu.org Resent-Date: Mon, 10 Dec 2012 16:55:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13107 X-GNU-PR-Package: automake X-GNU-PR-Keywords: To: Mikulas Patocka Cc: guenther@gmail.com, 13107@debbugs.gnu.org, bug-make@gnu.org X-Debbugs-Original-Cc: Philip Guenther , bug-automake@gnu.org, bug-make@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.135515847232278 (code B ref -1); Mon, 10 Dec 2012 16:55:02 +0000 Received: (at submit) by debbugs.gnu.org; 10 Dec 2012 16:54:32 +0000 Received: from localhost ([127.0.0.1]:35766 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Ti6ch-0008OZ-K9 for submit@debbugs.gnu.org; Mon, 10 Dec 2012 11:54:32 -0500 Received: from eggs.gnu.org ([208.118.235.92]:60451) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1ThzxU-0005VF-L6 for submit@debbugs.gnu.org; Mon, 10 Dec 2012 04:47:33 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Thzwn-00081Y-R3 for submit@debbugs.gnu.org; Mon, 10 Dec 2012 04:46:58 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:52889) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Thzwn-00081I-OG for submit@debbugs.gnu.org; Mon, 10 Dec 2012 04:46:49 -0500 Received: from eggs.gnu.org ([208.118.235.92]:43536) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Thzwg-0005DP-9w for bug-automake@gnu.org; Mon, 10 Dec 2012 04:46:49 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ThzwR-0007r2-8Y for bug-automake@gnu.org; Mon, 10 Dec 2012 04:46:42 -0500 Received: from cantor2.suse.de ([195.135.220.15]:43273 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ThzwR-0007lp-2E; Mon, 10 Dec 2012 04:46:27 -0500 Received: from relay1.suse.de (unknown [195.135.220.254]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx2.suse.de (Postfix) with ESMTP id C0232A3B99; Mon, 10 Dec 2012 10:45:45 +0100 (CET) From: Andreas Schwab References: X-Yow: .. If I had heart failure right now, I couldn't be a more fortunate man!! Date: Mon, 10 Dec 2012 10:45:45 +0100 In-Reply-To: (Mikulas Patocka's message of "Fri, 7 Dec 2012 03:16:31 +0100 (CET)") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.90 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -4.2 (----) X-Mailman-Approved-At: Mon, 10 Dec 2012 11:54:30 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -5.5 (-----) Mikulas Patocka writes: > BTW. on Linux, high precision timestamps have really kernel-tick > precision, not nanosecond precision. The precision is as high as what the best hardware timer provides, independent of the configured value of HZ. Andreas. -- Andreas Schwab, SUSE Labs, schwab@suse.de GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0EEA B9D7 "And now for something completely different." From unknown Sun Jun 22 00:59:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13107: timestamp bug when files are created just before make is run References: Resent-From: Karl Berry Original-Sender: "Debbugs-submit" Resent-CC: bug-automake@gnu.org Resent-Date: Sun, 12 Jul 2020 01:24:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13107 X-GNU-PR-Package: automake X-GNU-PR-Keywords: To: 13107@debbugs.gnu.org Received: via spool by 13107-submit@debbugs.gnu.org id=B13107.15945170331884 (code B ref 13107); Sun, 12 Jul 2020 01:24:01 +0000 Received: (at 13107) by debbugs.gnu.org; 12 Jul 2020 01:23:53 +0000 Received: from localhost ([127.0.0.1]:45172 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1juQie-0000UJ-Og for submit@debbugs.gnu.org; Sat, 11 Jul 2020 21:23:52 -0400 Received: from freefriends.org ([96.88.95.60]:47290) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1juQiZ-0000U3-2O; Sat, 11 Jul 2020 21:23:51 -0400 X-Envelope-From: karl@freefriends.org Received: from freefriends.org (freefriends.org [96.88.95.60]) by freefriends.org (8.14.7/8.14.7) with ESMTP id 06C1NjVp008711 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sat, 11 Jul 2020 19:23:46 -0600 Received: (from apache@localhost) by freefriends.org (8.14.7/8.14.7/Submit) id 06C1Njrm008710; Sat, 11 Jul 2020 19:23:45 -0600 Date: Sat, 11 Jul 2020 19:23:45 -0600 Message-Id: <202007120123.06C1Njrm008710@freefriends.org> From: Karl Berry In-Reply-To: X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Given the zero response, it seems undesirable to add even minor complexity to support something which may no longer be needed. Closing. -k From unknown Sun Jun 22 00:59:25 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Mikulas Patocka Subject: bug#13107: closed (Re: bug#13107: timestamp bug when files are created just before make is run) Message-ID: References: <202007120123.06C1Njrm008710@freefriends.org> X-Gnu-PR-Message: they-closed 13107 X-Gnu-PR-Package: automake Reply-To: 13107@debbugs.gnu.org Date: Sun, 12 Jul 2020 01:24:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1594517042-1914-1" This is a multi-part message in MIME format... ------------=_1594517042-1914-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #13107: timestamp bug when files are created just before make is run which was filed against the automake package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 13107@debbugs.gnu.org. --=20 13107: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D13107 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1594517042-1914-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 13107-done) by debbugs.gnu.org; 12 Jul 2020 01:23:53 +0000 Received: from localhost ([127.0.0.1]:45174 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1juQie-0000UL-UX for submit@debbugs.gnu.org; Sat, 11 Jul 2020 21:23:53 -0400 Received: from freefriends.org ([96.88.95.60]:47290) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1juQiZ-0000U3-2O; Sat, 11 Jul 2020 21:23:51 -0400 X-Envelope-From: karl@freefriends.org Received: from freefriends.org (freefriends.org [96.88.95.60]) by freefriends.org (8.14.7/8.14.7) with ESMTP id 06C1NjVp008711 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sat, 11 Jul 2020 19:23:46 -0600 Received: (from apache@localhost) by freefriends.org (8.14.7/8.14.7/Submit) id 06C1Njrm008710; Sat, 11 Jul 2020 19:23:45 -0600 Date: Sat, 11 Jul 2020 19:23:45 -0600 Message-Id: <202007120123.06C1Njrm008710@freefriends.org> From: Karl Berry To: 13107@debbugs.gnu.org Subject: Re: bug#13107: timestamp bug when files are created just before make is run In-Reply-To: X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 13107-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Given the zero response, it seems undesirable to add even minor complexity to support something which may no longer be needed. Closing. -k ------------=_1594517042-1914-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 6 Dec 2012 22:17:43 +0000 Received: from localhost ([127.0.0.1]:57431 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TgjlG-00030l-Hv for submit@debbugs.gnu.org; Thu, 06 Dec 2012 17:17:43 -0500 Received: from eggs.gnu.org ([208.118.235.92]:46483) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TgjXI-0002gC-3g for submit@debbugs.gnu.org; Thu, 06 Dec 2012 17:03:17 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TgjWy-0001Sr-P3 for submit@debbugs.gnu.org; Thu, 06 Dec 2012 17:03:01 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:55901) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgjWy-0001Sn-My for submit@debbugs.gnu.org; Thu, 06 Dec 2012 17:02:56 -0500 Received: from eggs.gnu.org ([208.118.235.92]:57797) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgjWv-0007cs-RT for bug-automake@gnu.org; Thu, 06 Dec 2012 17:02:56 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TgjWs-0001R1-5x for bug-automake@gnu.org; Thu, 06 Dec 2012 17:02:53 -0500 Received: from artax.karlin.mff.cuni.cz ([195.113.26.195]:40212) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgjWr-0001Qs-Vn; Thu, 06 Dec 2012 17:02:50 -0500 Received: by artax.karlin.mff.cuni.cz (Postfix, from userid 17421) id 269FA98070; Thu, 6 Dec 2012 23:02:48 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by artax.karlin.mff.cuni.cz (Postfix) with ESMTP id 239A398062; Thu, 6 Dec 2012 23:02:48 +0100 (CET) Date: Thu, 6 Dec 2012 23:02:48 +0100 (CET) From: Mikulas Patocka To: bug-make@gnu.org, bug-automake@gnu.org Subject: timestamp bug when files are created just before make is run Message-ID: User-Agent: Alpine 2.00 (DEB 1167 2008-08-23) X-Personality-Disorder: Schizoid MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -4.2 (----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Thu, 06 Dec 2012 17:17:42 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.2 (----) Hi Try this Makefile: --- a : b echo build a touch a b : c echo build b touch b --- and run this script: touch b;sleep 1;touch a c;make You see "echo build b build b touch b" but it doesn't remake a. The apparent problem is that after make rebuilds b, it compares b's time with a's time, finds that the times are equal (because a was touched just before make was run) and doesn't rebuild a. I think it is a bug - when b is finished, make should find out whether the rule for b modified the file b (if b's time is greater or equal than the time when the rule for b was started, then b may have been modified) and rebuild a in this case. --- This bug is causing real-world problems in automake-generated Makefiles. This is a simplified piece of Makefile from automake: all : config.h $(MAKE) all-am config.h : stamp-h1 echo build config.h stamp-h1 : config.h.in echo build stamp-h1 rm -f stamp-h1 touch config.h touch stamp-h1 config.h.in : am__configure_deps echo build config.h.in rm -f stamp-h1 touch config.h.in all-am : echo ALL-AM Now, if you run this script, you trigger the bug: touch config.h.in;sleep 1;touch am__configure_deps;sleep 1;touch config.h stamp-h1;make - you see "build config.h.in", but the other files are not rebuild and all-am is executed (the essential thing to trigger the bug is that make is run in the same second in which config.h and stamp-h1 were created) The problem that really happens in a real build: * The user runs autoheader && aclocal && automake && autoconf && ./configure && make -j4 * Configure runs ./config.status, ./config.status writes config.h and stamp-h1 * Make sees that am__configure_deps is newer than config.h.in * Make runs the rule for config.h.in. It sets the new timestamp for config.h.in and deletes stamp-h1 * Now make sees that config.h.in has the same time as stamp-h1 (the timestamp is read from make's cache even if stamp-h1 no longer exists) * Because of the same timestamp, make doesn't run the commands for stamp-h1 and config.h * Make executes a subprocess to build the rule all-am * The subprocess doesn't have the file cache of the parent process, so the subprocess knows that stamp-h1 is missing * The subprocess sees a dependency config.h->stamp-h1, stamp-h1 doesn't exist * The subprocess executes the rule for stamp-h1 which regenerates config.h - the problem is that this rule is executed in parallel with other rules that build C files that include config.h - changing config.h while it is being used results in build failure Another possible solution for this bug would be to remove rm -f stamp-h1 from config.h.in rule, but there is some complex explanation in /usr/local/share/automake-1.12/am/remake-hdr.am why rm -f stamp-h1 is there so it would likely fix one bug and trigger another one. So it would be better to fix this in make. Mikulas ------------=_1594517042-1914-1-- From unknown Sun Jun 22 00:59:25 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Karl Berry Subject: bug#41843: closed (Re: bug#13107: timestamp bug when files are created just before make is run) Message-ID: References: <202007120123.06C1Njrm008710@freefriends.org> <202006140124.05E1OpS3021966@freefriends.org> X-Gnu-PR-Message: they-closed 41843 X-Gnu-PR-Package: automake Reply-To: 41843@debbugs.gnu.org Date: Sun, 12 Jul 2020 01:24:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1594517042-1914-3" This is a multi-part message in MIME format... ------------=_1594517042-1914-3 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #13107: timestamp bug when files are created just before make is run which was filed against the automake package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 41843@debbugs.gnu.org. --=20 13107: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D13107 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1594517042-1914-3 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 13107-done) by debbugs.gnu.org; 12 Jul 2020 01:23:53 +0000 Received: from localhost ([127.0.0.1]:45174 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1juQie-0000UL-UX for submit@debbugs.gnu.org; Sat, 11 Jul 2020 21:23:53 -0400 Received: from freefriends.org ([96.88.95.60]:47290) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1juQiZ-0000U3-2O; Sat, 11 Jul 2020 21:23:51 -0400 X-Envelope-From: karl@freefriends.org Received: from freefriends.org (freefriends.org [96.88.95.60]) by freefriends.org (8.14.7/8.14.7) with ESMTP id 06C1NjVp008711 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sat, 11 Jul 2020 19:23:46 -0600 Received: (from apache@localhost) by freefriends.org (8.14.7/8.14.7/Submit) id 06C1Njrm008710; Sat, 11 Jul 2020 19:23:45 -0600 Date: Sat, 11 Jul 2020 19:23:45 -0600 Message-Id: <202007120123.06C1Njrm008710@freefriends.org> From: Karl Berry To: 13107@debbugs.gnu.org Subject: Re: bug#13107: timestamp bug when files are created just before make is run In-Reply-To: X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 13107-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Given the zero response, it seems undesirable to add even minor complexity to support something which may no longer be needed. Closing. -k ------------=_1594517042-1914-3 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 14 Jun 2020 01:25:09 +0000 Received: from localhost ([127.0.0.1]:42662 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jkHOW-0001Ol-JS for submit@debbugs.gnu.org; Sat, 13 Jun 2020 21:25:08 -0400 Received: from lists.gnu.org ([209.51.188.17]:43170) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jkHOV-0001Od-0h for submit@debbugs.gnu.org; Sat, 13 Jun 2020 21:25:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40378) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jkHOU-0000uK-MG; Sat, 13 Jun 2020 21:25:06 -0400 Received: from freefriends.org ([96.88.95.60]:41634) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jkHOQ-0005q3-Vt; Sat, 13 Jun 2020 21:25:04 -0400 X-Envelope-From: karl@freefriends.org Received: from freefriends.org (freefriends.org [96.88.95.60]) by freefriends.org (8.14.7/8.14.7) with ESMTP id 05E1OrGV021969 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sat, 13 Jun 2020 19:24:54 -0600 Received: (from apache@localhost) by freefriends.org (8.14.7/8.14.7/Submit) id 05E1OpS3021966; Sat, 13 Jun 2020 19:24:51 -0600 Date: Sat, 13 Jun 2020 19:24:51 -0600 Message-Id: <202006140124.05E1OpS3021966@freefriends.org> From: Karl Berry To: mikulas@artax.karlin.mff.cuni.cz Subject: Re: timestamp bug when files are created just before make is run In-Reply-To: Received-SPF: pass client-ip=96.88.95.60; envelope-from=karl@freefriends.org; helo=freefriends.org X-detected-operating-system: by eggs.gnu.org: First seen = 2020/06/13 21:25:00 X-ACL-Warn: Detected OS = Linux 3.11 and newer [fuzzy] X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-Spam-Score: -1.4 (-) X-Debbugs-Envelope-To: submit Cc: guenther@gmail.com, bug-automake@gnu.org, bug-make@gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.4 (--) Regarding https://debbugs.gnu.org/cgi/bugreport.cgi?bug=13107 (from December 2012, sorry) ... [From Mikulas] > > config.h.in : am__configure_deps > > echo build config.h.in > > rm -f stamp-h1 > > touch config.h.in [...] > Hmm, adding a "sleep 1" after that rm -f and before the touch > config.h.in would work without reintroducing the issue described in > that explanation, no? > Philip Guenther [Mikulas again] Yes it fixes it, you can add "sleep 1" to automake there, that fixes the bug. Does this bug still come up? Is it worth considering adding the sleep 1 to automake after the rm -f? All those sleeps might add up, though. An alternative would be a variable for a command (that does nothing by default) that could be overridden in a project that needs to worry about this problem. That would be safe in that it would have no visible impact, but I'm not inclined to do so unless it would actually be used. Anyone out there who wants it? --thanks, karl. ------------=_1594517042-1914-3--