freebsd-src/unit-tests/opt-debug-cond.mk
Simon J. Gerraty 2061c94e6f Import bmake-20220418
Most relevant change:

	o ignore '.POSIX:' if not in first non-comment line
	of Makefile as specified by POSIX.
	add unit-tests for above.
2022-04-22 13:34:55 -07:00

25 lines
605 B
Makefile

# $NetBSD: opt-debug-cond.mk,v 1.3 2022/04/15 09:33:20 rillig Exp $
#
# Tests for the -dc command line option, which adds debug logging for the
# evaluation of conditional expressions, such as in .if directives and
# ${cond:?then:else} expressions.
.MAKEFLAGS: -dc
# expect: CondParser_Eval: ${:U12345} > ${:U55555}
# expect: Comparing 12345.000000 > 55555.000000
.if ${:U12345} > ${:U55555}
# expect: CondParser_Eval: "string" != "string"
# expect: Comparing "string" != "string"
.elif "string" != "string"
# expect: CondParser_Eval: "nonempty"
.elif "nonempty"
.endif
.MAKEFLAGS: -d0
all: .PHONY