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 tests/make: reproduce filesystem loo...
details: https://anonhg.NetBSD.org/src/rev/0c7a688807b8
branches: trunk
changeset: 361132:0c7a688807b8
user: rillig <rillig%NetBSD.org@localhost>
date: Fri Feb 11 23:44:18 2022 +0000
description:
tests/make: reproduce filesystem lookup of .PHONY nodes
As described in PR toolchain/15164.
diffstat:
usr.bin/make/unit-tests/deptgt-phony.exp | 41 ++++++++++++++++++++++++++++++++
usr.bin/make/unit-tests/deptgt-phony.mk | 27 +++++++++++++++++++-
2 files changed, 66 insertions(+), 2 deletions(-)
diffs (83 lines):
diff -r a5785665f405 -r 0c7a688807b8 usr.bin/make/unit-tests/deptgt-phony.exp
--- a/usr.bin/make/unit-tests/deptgt-phony.exp Fri Feb 11 23:20:09 2022 +0000
+++ b/usr.bin/make/unit-tests/deptgt-phony.exp Fri Feb 11 23:44:18 2022 +0000
@@ -1,1 +1,42 @@
+Expanding "depsrc-phony-pr-15164-*-wildcard"...
+Expanding "deptgt-phony-pr-15164-*-wildcard"...
+Searching for .depend ...
+ failed.
+Searching for .depend ...
+ /usr/share/mk ...
+ failed.
+Wildcard expanding "all"...
+Searching for all ...
+ failed.
+Found 'all' as '(not found)'
+SuffFindDeps "all"
+ No known suffix on all. Using .NULL suffix
+adding suffix rules
+Wildcard expanding "depsrc-phony-pr-15164-*-wildcard"...
+Expanding "depsrc-phony-pr-15164-*-wildcard"...
+
+Wildcard expanding "deptgt-phony-pr-15164-*-wildcard"...
+Expanding "deptgt-phony-pr-15164-*-wildcard"...
+
+Searching for all ...
+ failed.
+SuffFindDeps "depsrc-phony-pr-15164"
+ No valid suffix on depsrc-phony-pr-15164
+SuffFindDeps "deptgt-phony-pr-15164"
+ No valid suffix on deptgt-phony-pr-15164
+: Making depsrc-phony-pr-15164
+: Making deptgt-phony-pr-15164
+Wildcard expanding "all"...
+Searching for all ...
+ failed.
+Found 'all' as '(not found)'
+SuffFindDeps ".END"
+ No known suffix on .END. Using .NULL suffix
+adding suffix rules
+Searching for .END ...
+ failed.
+Wildcard expanding ".END"...
+Searching for .END ...
+ failed.
+Found '.END' as '(not found)'
exit status 0
diff -r a5785665f405 -r 0c7a688807b8 usr.bin/make/unit-tests/deptgt-phony.mk
--- a/usr.bin/make/unit-tests/deptgt-phony.mk Fri Feb 11 23:20:09 2022 +0000
+++ b/usr.bin/make/unit-tests/deptgt-phony.mk Fri Feb 11 23:44:18 2022 +0000
@@ -1,8 +1,31 @@
-# $NetBSD: deptgt-phony.mk,v 1.2 2020/08/16 14:25:16 rillig Exp $
+# $NetBSD: deptgt-phony.mk,v 1.3 2022/02/11 23:44:18 rillig Exp $
#
# Tests for the special target .PHONY in dependency declarations.
# TODO: Implementation
all:
- @:;
+
+
+# https://gnats.netbsd.org/15164 describes that .PHONY targets are still
+# looked up in directories, even though .PHONY means that these targets do
+# _not_ correspond to actual files.
+#
+# expect: Expanding "depsrc-phony-pr-15164-*-wildcard"...
+# expect: Expanding "deptgt-phony-pr-15164-*-wildcard"...
+.MAKEFLAGS: -dds
+depsrc-phony-pr-15164: .PHONY
+ : Making ${.TARGET}
+depsrc-phony-pr-15164-*-wildcard: .PHONY
+ : Making ${.TARGET}
+
+.PHONY: deptgt-phony-pr-15164
+deptgt-phony-pr-15164:
+ : Making ${.TARGET}
+
+.PHONY: deptgt-phony-pr-15164-*-wildcard
+deptgt-phony-pr-15164-*-wildcard:
+ : Making ${.TARGET}
+
+all: depsrc-phony-pr-15164 depsrc-phony-pr-15164-*-wildcard
+all: deptgt-phony-pr-15164 deptgt-phony-pr-15164-*-wildcard
Home |
Main Index |
Thread Index |
Old Index