Module Name:    src
Committed By:   sjg
Date:           Wed Nov 18 01:12:00 UTC 2020

Modified Files:
        src/usr.bin/make/unit-tests: Makefile

Log Message:
Some tests need help with dash


To generate a diff of this commit:
cvs rdiff -u -r1.205 -r1.206 src/usr.bin/make/unit-tests/Makefile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.bin/make/unit-tests/Makefile
diff -u src/usr.bin/make/unit-tests/Makefile:1.205 src/usr.bin/make/unit-tests/Makefile:1.206
--- src/usr.bin/make/unit-tests/Makefile:1.205	Tue Nov 17 20:27:35 2020
+++ src/usr.bin/make/unit-tests/Makefile	Wed Nov 18 01:12:00 2020
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.205 2020/11/17 20:27:35 rillig Exp $
+# $NetBSD: Makefile,v 1.206 2020/11/18 01:12:00 sjg Exp $
 #
 # Unit tests for make(1)
 #
@@ -427,6 +427,15 @@ FLAGS.doterror=		# none, especially not 
 FLAGS.varname-empty=	-dv '$${:U}=cmdline-u' '=cmdline-plain'
 
 # Some tests need extra postprocessing.
+SED_CMDS.export= \
+       -e '/^[^=_A-Za-z0-9]*=/d'
+# these all share the same requirement
+.for t in export-all export-env
+SED_CMDS.$t= ${SED_CMDS.export}
+.endfor
+SED_CMDS.directive-export-gmake= \
+	${:D dash is a pain } \
+	-e /non-zero/d
 SED_CMDS.job-output-long-lines= \
 	${:D Job separators on their own line are ok. } \
 	-e '/^--- job-[ab] ---$$/d' \
@@ -451,7 +460,10 @@ SED_CMDS.opt-debug-jobs+=	-e 's,JobFinis
 # The "-q" may be there or not, see jobs.c, variable shells.
 SED_CMDS.opt-debug-jobs+=	-e 's,^\(.Command: sh\) -q,\1,'
 SED_CMDS.var-op-shell+=	-e 's,^${.SHELL:T}: [ 0-9:]*,,'
-SED_CMDS.var-op-shell+=	-e '/command/s,No such.*,not found,'
+SED_CMDS.var-op-shell+=	-e '/command/{ s,^[1-9]: ,,;s,No such.*,not found,; }'
+SED_CMDS.vardebug= \
+	${:D canonicalize .SHELL } \
+	-e 's,${.SHELL},/bin/sh,'
 SED_CMDS.vardebug+=	-e 's,${.SHELL},</path/to/shell>,'
 SED_CMDS.varmod-subst-regex+= \
 			-e 's,\(Regex compilation error:\).*,\1 (details omitted),'

Reply via email to