bug#11346: automake-1.12 - one test fails (due to truncated timestamp)
On Thu, 26 Apr 2012, Stefano Lattarini wrote: because you should still have the paperwork from the ObjC++ integration. I wasn't involved in the project yet back then, so I wasn't aware you had the paperwork in place already. Now I am :-) Hi Stefano, and the whole ObjC++ integration (one of two reasons I was waiting for 1.12) somehow got lost. I still have the old patches 0001-2009-07-22-Support-for-Objective-C.patch from 2009-07-22 etc, but could also apply them to the current git version and send you these. I may, however, have problem to modernize the test cases. Regards Peter
bug#11346: automake-1.12 - one test fails (due to truncated timestamp)
On 04/26/2012 11:38 AM, Stefano Lattarini wrote: > Will push shortly then. > Pushed now. I'm thus closing this bug report. Thanks, Stefano
bug#11346: automake-1.12 - one test fails (due to truncated timestamp)
tags 11346 + patch thanks On 04/26/2012 11:32 AM, Peter Breitenlohner wrote: > On Thu, 26 Apr 2012, Stefano Lattarini wrote: > >> Good idea. Can you confirm that the attached patch solves your problem? > > Hi Stefano, > > it does indeed. > Good. Will push shortly then. > BTW: The "Copyright-paperwork-exempt: yes" should be unnecessary > Will remove it then. > because you should still have the paperwork from the ObjC++ integration. > I wasn't involved in the project yet back then, so I wasn't aware you had the paperwork in place already. Now I am :-) Thanks, Stefano
bug#11346: automake-1.12 - one test fails (due to truncated timestamp)
On Thu, 26 Apr 2012, Stefano Lattarini wrote: Good idea. Can you confirm that the attached patch solves your problem? Hi Stefano, it does indeed. BTW: The "Copyright-paperwork-exempt: yes" should be unnecessary because you should still have the paperwork from the ObjC++ integration. Regards Peter
bug#11346: automake-1.12 - one test fails (due to truncated timestamp)
On 04/26/2012 10:26 AM, Peter Breitenlohner wrote: > Hi, > Hi Peter, thanks for the report (and the fix ;-) > I just fetched automake-1.12, built it on our no-distro x86-linux-gnu > system > > uname -r: 2.6.28.6-x86_64 (most binaries are 32-bit) > /lib/libc-2.3.6.so > /lib64/libc-2.3.6.so > > and got one test suite failure. > > FAIL: t/self-check-is_newest.tap 19 - is_newest u x > > It seems that 'touch -r x u' (on jfs) has truncated the timestamp, but I > have also seen timestamps rounded upwards to the next second (I think). > > Therefore I would suggest to replace > touch -r x u > in self-check-is_newest.tap by > touch -r x x; touch -r x u > such that x's time first gets rounded (up or down) to the next second and > then transferred to u. > Good idea. Can you confirm that the attached patch solves your problem? Thanks, Stefano >From b3baa4f5f2312617c6f115b271efc48f84d908db Mon Sep 17 00:00:00 2001 Message-Id: From: Stefano Lattarini Date: Thu, 26 Apr 2012 10:52:48 +0200 Subject: [PATCH] tests: fix a spurious failure due to truncated timestamps Fixes automake bug#11346. * t/self-check-is_newest.tap: Apparently, on some systems (or file systems), "touch -r" can truncate timestamps :-( Work around that. Co-authored-by: Peter Breitenlohner Copyright-paperwork-exempt: yes Signed-off-by: Stefano Lattarini --- t/self-check-is_newest.tap | 14 -- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/t/self-check-is_newest.tap b/t/self-check-is_newest.tap index 76b69ac..842c411 100755 --- a/t/self-check-is_newest.tap +++ b/t/self-check-is_newest.tap @@ -24,6 +24,16 @@ plan_ 21 Y () { command_ok_ "is_newest $*" is_newest "$@"; } N () { command_ok_ "not is_newest $*" not is_newest "$@"; } +# A simple "touch -r" might not work, since on some file systems, and/or +# with some 'touch' versions, it might truncate the timestamp (or even +# rounded it upwards maybe). So the first (apparently redundant) 'touch' +# invocation below ensures that the timestamp gets "normalized" in a way +# that allows it to be correctly copied by the second 'touch' invocation. +copy_timestamp () +{ + touch -r "$1" "$1" && touch -r "$1" "$2" +} + : > a $sleep : > b @@ -38,7 +48,7 @@ Y c b Y c c Y c a b c -touch -r c d +copy_timestamp c d stat c d || : # For debugging. @@ -69,7 +79,7 @@ done Y x/foo x N x x/foo -touch -r x u +copy_timestamp x u Y x u Y u x -- 1.7.9.5
bug#11346: automake-1.12 - one test fails (due to truncated timestamp)
Hi, I just fetched automake-1.12, built it on our no-distro x86-linux-gnu system uname -r: 2.6.28.6-x86_64 (most binaries are 32-bit) /lib/libc-2.3.6.so /lib64/libc-2.3.6.so and got one test suite failure. FAIL: t/self-check-is_newest.tap 19 - is_newest u x It seems that 'touch -r x u' (on jfs) has truncated the timestamp, but I have also seen timestamps rounded upwards to the next second (I think). Therefore I would suggest to replace touch -r x u in self-check-is_newest.tap by touch -r x x; touch -r x u such that x's time first gets rounded (up or down) to the next second and then transferred to u. Regards Peter Breitenlohner