From be8b43b4c71024f374f49fdcec8de815fc5572a9 Mon Sep 17 00:00:00 2001 From: Ruslan Ermilov Date: Thu, 28 Nov 2002 13:21:32 +0000 Subject: [PATCH] Add a test for what was fixed in revisions 1.39 and 1.50 of make/parse.c (allow embedded `:' and `!' in target names). Approved by: re --- tools/build/make_check/Makefile | 9 +++++++++ tools/regression/usr.bin/make/Makefile | 9 +++++++++ 2 files changed, 18 insertions(+) diff --git a/tools/build/make_check/Makefile b/tools/build/make_check/Makefile index f4dec2efeda3..760433b50999 100644 --- a/tools/build/make_check/Makefile +++ b/tools/build/make_check/Makefile @@ -38,6 +38,9 @@ all: @echo "Running test modifiers" @${MAKE} modifiers || ${MAKE} failure @echo "PASS: Test modifiers detected no regression." + @echo "Running test funny_targets" + @${MAKE} funny_targets || ${MAKE} failure + @echo "PASS: Test funny_targets detected no regression." .if make(double) # Doubly-defined targets. make(1) will warn, but use the "right" one. If it @@ -81,6 +84,12 @@ modifiers: fi .endif +.if make(funny_targets) +funny_targets: colons::target exclamation!target +colons::target: +exclamation!target: +.endif + failure: @echo "FAIL: Test failed: regression detected. See above." @false diff --git a/tools/regression/usr.bin/make/Makefile b/tools/regression/usr.bin/make/Makefile index f4dec2efeda3..760433b50999 100644 --- a/tools/regression/usr.bin/make/Makefile +++ b/tools/regression/usr.bin/make/Makefile @@ -38,6 +38,9 @@ all: @echo "Running test modifiers" @${MAKE} modifiers || ${MAKE} failure @echo "PASS: Test modifiers detected no regression." + @echo "Running test funny_targets" + @${MAKE} funny_targets || ${MAKE} failure + @echo "PASS: Test funny_targets detected no regression." .if make(double) # Doubly-defined targets. make(1) will warn, but use the "right" one. If it @@ -81,6 +84,12 @@ modifiers: fi .endif +.if make(funny_targets) +funny_targets: colons::target exclamation!target +colons::target: +exclamation!target: +.endif + failure: @echo "FAIL: Test failed: regression detected. See above." @false