bug-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

GNU make 4.1 features/archives test failure on OpenBSD


From: Christian Weisgerber
Subject: GNU make 4.1 features/archives test failure on OpenBSD
Date: Tue, 25 Nov 2014 19:09:44 +0100
User-agent: Mutt/1.5.23 (2014-03-12)

When running the GNU make 4.1 regression test suite on OpenBSD 5.6,
the final features/archivers test fails.  This is a problem with the
test.

features/archives ....................................... FAILED (9/10 passed)

------------------->
*** work/features/archives.base.9       Tue Nov 25 18:53:44 2014
--- work/features/archives.log.9        Tue Nov 25 18:53:44 2014
***************
*** 1 ****
- make: Nothing to be done for 'default'.
--- 0 ----
<-------------------

Here's the respective archives.mk.6 makefile:

------------------->

DIR = artest
vpath % $(DIR)
default: lib(foo)
(%): %.vhd ; @cd $(DIR) && touch $(*F) && $(AR) $(ARFLAGS) $@ $(*F) >/dev/null 
2>&1 && rm $(*F)
.PHONY: default
<-------------------

It is invoked twice.  The idea is that there should be "nothing to be
done" on the second invokation.

The problem is that OpenBSD's ar(1) (GNU ar 2.15) skips zero-length
files.  E.g.:

$ rm -f foo lib
$ touch foo
$ ar rv lib foo
ar: creating lib
$ ar tv lib
$ 

The other tests succeed because the touch() function from test_driver.pl
actually creates non-zero files.

With a change like the one below, this regression test will pass
just fine on OpenBSD.

------------------->
--- tests/scripts/features/archives.orig        Sun Oct  5 18:24:51 2014
+++ tests/scripts/features/archives     Tue Nov 25 18:40:08 2014
@@ -83,7 +83,7 @@ run_make_test(q!
 DIR = artest
 vpath % $(DIR)
 default: lib(foo)
-(%): %.vhd ; @cd $(DIR) && touch $(*F) && $(AR) $(ARFLAGS) $@ $(*F) >/dev/null 
2>&1 && rm $(*F)
+(%): %.vhd ; @cd $(DIR) && echo foo >$(*F) && $(AR) $(ARFLAGS) $@ $(*F) 
>/dev/null 2>&1 && rm $(*F)
 .PHONY: default
 !,
               '', "");
<-------------------

-- 
Christian "naddy" Weisgerber                          address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]