1139823Simp# $NetBSD: opt-no-action-runflags.mk,v 1.1 2020/12/09 07:57:52 rillig Exp $
21541Srgrimes#
31541Srgrimes# Tests for the -n command line option, which runs almost no commands,
41541Srgrimes# combined with the RunFlags '@', '-', '+' for individual commands.
51541Srgrimes#
61541Srgrimes# See also:
71541Srgrimes#	opt-jobs-no-action.mk
81541Srgrimes#		The corresponding test with the -j option
91541Srgrimes
101541Srgrimes.MAKEFLAGS: -n
111541Srgrimes
121541Srgrimesall: .PHONY combined
131541Srgrimes
141541SrgrimesSILENT.no=	# none
151541SrgrimesSILENT.yes=	@
161541SrgrimesALWAYS.no=	# none
171541SrgrimesALWAYS.yes=	+
181541SrgrimesIGNERR.no=	echo running
191541SrgrimesIGNERR.yes=	-echo running; false
201541Srgrimes#
211541Srgrimescombined: .PHONY
221541Srgrimes	@+echo hide-from-output 'begin $@'; echo
231541Srgrimes.for silent in no yes
241541Srgrimes.  for always in no yes
251541Srgrimes.    for ignerr in no yes
261541Srgrimes	@+echo hide-from-output silent=${silent} always=${always} ignerr=${ignerr}
271541Srgrimes	${SILENT.${silent}}${ALWAYS.${always}}${IGNERR.${ignerr}}
281541Srgrimes	@+echo hide-from-output
291541Srgrimes.    endfor
301541Srgrimes.  endfor
311541Srgrimes.endfor
321541Srgrimes	@+echo hide-from-output 'end $@'
331541Srgrimes