Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/make/unit-tests make(1): add test for dependencies o...
details: https://anonhg.NetBSD.org/src/rev/19433838b82f
branches: trunk
changeset: 956187:19433838b82f
user: rillig <rillig%NetBSD.org@localhost>
date: Fri Oct 23 19:54:35 2020 +0000
description:
make(1): add test for dependencies of the form '%.o: %.c'
diffstat:
distrib/sets/lists/tests/mi | 4 +++-
usr.bin/make/unit-tests/Makefile | 3 ++-
usr.bin/make/unit-tests/dep-percent.exp | 3 +++
usr.bin/make/unit-tests/dep-percent.mk | 14 ++++++++++++++
usr.bin/make/unit-tests/dep-wildcards.exp | 1 +
5 files changed, 23 insertions(+), 2 deletions(-)
diffs (71 lines):
diff -r 5aba2bda1999 -r 19433838b82f distrib/sets/lists/tests/mi
--- a/distrib/sets/lists/tests/mi Fri Oct 23 19:48:17 2020 +0000
+++ b/distrib/sets/lists/tests/mi Fri Oct 23 19:54:35 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.948 2020/10/23 19:23:00 rillig Exp $
+# $NetBSD: mi,v 1.949 2020/10/23 19:54:35 rillig Exp $
#
# Note: don't delete entries from here - mark them as "obsolete" instead.
#
@@ -4635,6 +4635,8 @@
./usr/tests/usr.bin/make/unit-tests/dep-exclam.mk tests-usr.bin-tests compattestfile,atf
./usr/tests/usr.bin/make/unit-tests/dep-none.exp tests-usr.bin-tests compattestfile,atf
./usr/tests/usr.bin/make/unit-tests/dep-none.mk tests-usr.bin-tests compattestfile,atf
+./usr/tests/usr.bin/make/unit-tests/dep-percent.exp tests-usr.bin-tests compattestfile,atf
+./usr/tests/usr.bin/make/unit-tests/dep-percent.mk tests-usr.bin-tests compattestfile,atf
./usr/tests/usr.bin/make/unit-tests/dep-var.exp tests-usr.bin-tests compattestfile,atf
./usr/tests/usr.bin/make/unit-tests/dep-var.mk tests-usr.bin-tests compattestfile,atf
./usr/tests/usr.bin/make/unit-tests/dep-wildcards.exp tests-usr.bin-tests compattestfile,atf
diff -r 5aba2bda1999 -r 19433838b82f usr.bin/make/unit-tests/Makefile
--- a/usr.bin/make/unit-tests/Makefile Fri Oct 23 19:48:17 2020 +0000
+++ b/usr.bin/make/unit-tests/Makefile Fri Oct 23 19:54:35 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.173 2020/10/23 19:23:01 rillig Exp $
+# $NetBSD: Makefile,v 1.174 2020/10/23 19:54:35 rillig Exp $
#
# Unit tests for make(1)
#
@@ -78,6 +78,7 @@
TESTS+= dep-double-colon-indep
TESTS+= dep-exclam
TESTS+= dep-none
+TESTS+= dep-percent
TESTS+= dep-var
TESTS+= dep-wildcards
TESTS+= depsrc
diff -r 5aba2bda1999 -r 19433838b82f usr.bin/make/unit-tests/dep-percent.exp
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/usr.bin/make/unit-tests/dep-percent.exp Fri Oct 23 19:54:35 2020 +0000
@@ -0,0 +1,3 @@
+make: don't know how to make dep-percent.o (continuing)
+`all' not remade because of errors.
+exit status 0
diff -r 5aba2bda1999 -r 19433838b82f usr.bin/make/unit-tests/dep-percent.mk
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/usr.bin/make/unit-tests/dep-percent.mk Fri Oct 23 19:54:35 2020 +0000
@@ -0,0 +1,14 @@
+# $NetBSD: dep-percent.mk,v 1.1 2020/10/23 19:54:35 rillig Exp $
+#
+# Test for transformation rules of the form '%.o: %.c', which are supported
+# by GNU make but not this make.
+
+.SUFFIXES: .c .o
+
+all: dep-percent.o
+
+%.o: %.c
+ : 'Making ${.TARGET} from ${.IMPSRC} or ${.ALLSRC}.'
+
+dep-percent.c:
+ : 'Making ${.TARGET} out of nothing.'
diff -r 5aba2bda1999 -r 19433838b82f usr.bin/make/unit-tests/dep-wildcards.exp
--- a/usr.bin/make/unit-tests/dep-wildcards.exp Fri Oct 23 19:48:17 2020 +0000
+++ b/usr.bin/make/unit-tests/dep-wildcards.exp Fri Oct 23 19:54:35 2020 +0000
@@ -4,6 +4,7 @@
dep-double-colon.mk
dep-exclam.mk
dep-none.mk
+dep-percent.mk
dep-var.mk
dep-wildcards.mk
exit status 0
Home |
Main Index |
Thread Index |
Old Index