freebsd-dev/contrib/bmake/unit-tests/opt-debug-cond.mk
Simon J. Gerraty 2f2a5ecdf8 Merge bmake-20220418
o ignore '.POSIX:' if not in first non-comment line
        of Makefile as specified by POSIX.
        add unit-tests for above.

Merge commit '92bfae0e6bd53a7a0d6fe55e70a916d86cf26e8b'
2022-04-22 13:42:11 -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