2020-12-14 23:57:31 +03:00
|
|
|
# $NetBSD: directive-endif.mk,v 1.4 2020/12/14 20:57:31 rillig Exp $
|
2020-08-16 15:07:50 +03:00
|
|
|
#
|
2020-08-16 17:25:16 +03:00
|
|
|
# Tests for the .endif directive.
|
2020-11-13 01:40:11 +03:00
|
|
|
#
|
|
|
|
# See also:
|
|
|
|
# Cond_EvalLine
|
2020-08-16 15:07:50 +03:00
|
|
|
|
|
|
|
# TODO: Implementation
|
|
|
|
|
2020-11-13 01:40:11 +03:00
|
|
|
.MAKEFLAGS: -dL
|
|
|
|
|
|
|
|
# Error: .endif does not take arguments
|
|
|
|
# XXX: Missing error message
|
|
|
|
.if 0
|
|
|
|
.endif 0
|
|
|
|
|
|
|
|
# Error: .endif does not take arguments
|
|
|
|
# XXX: Missing error message
|
|
|
|
.if 1
|
|
|
|
.endif 1
|
|
|
|
|
|
|
|
# Comments are allowed after an '.endif'.
|
|
|
|
.if 2
|
|
|
|
.endif # comment
|
|
|
|
|
2020-12-14 23:57:31 +03:00
|
|
|
# Only whitespace and comments are allowed after an '.endif', but nothing
|
|
|
|
# else.
|
|
|
|
# XXX: Missing error message
|
|
|
|
.if 1
|
|
|
|
.endif0
|
|
|
|
|
|
|
|
# Only whitespace and comments are allowed after an '.endif', but nothing
|
|
|
|
# else.
|
|
|
|
# XXX: Missing error message
|
|
|
|
.if 1
|
|
|
|
.endif/
|
|
|
|
|
|
|
|
# After an '.endif', no other letter must occur. This 'endifx' is not
|
|
|
|
# parsed as an 'endif', therefore another '.endif' must follow to balance
|
|
|
|
# the directives.
|
|
|
|
.if 1
|
|
|
|
.endifx
|
|
|
|
.endif # to close the preceding '.if'
|
|
|
|
|
2020-08-16 15:07:50 +03:00
|
|
|
all:
|
|
|
|
@:;
|