make(1): add tests for the special .INCLUDES and .LIBS variables
This commit is contained in:
parent
3b8b408b28
commit
f0fdf22f6f
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: mi,v 1.910 2020/08/27 19:00:17 rillig Exp $
|
||||
# $NetBSD: mi,v 1.911 2020/08/28 03:51:06 rillig Exp $
|
||||
#
|
||||
# Note: don't delete entries from here - mark them as "obsolete" instead.
|
||||
#
|
||||
|
@ -5014,10 +5014,14 @@
|
|||
./usr/tests/usr.bin/make/unit-tests/varname-dot-alltargets.mk tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-curdir.exp tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-curdir.mk tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-includes.exp tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-includes.mk tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-includedfromdir.exp tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-includedfromdir.mk tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-includedfromfile.exp tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-includedfromfile.mk tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-libs.exp tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-libs.mk tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-make-dependfile.exp tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-make-dependfile.mk tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/make/unit-tests/varname-dot-make-expand_variables.exp tests-usr.bin-tests compattestfile,atf
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: Makefile,v 1.121 2020/08/28 02:45:51 rillig Exp $
|
||||
# $NetBSD: Makefile,v 1.122 2020/08/28 03:51:06 rillig Exp $
|
||||
#
|
||||
# Unit tests for make(1)
|
||||
#
|
||||
|
@ -272,8 +272,10 @@ TESTS+= varname
|
|||
TESTS+= varname-dollar
|
||||
TESTS+= varname-dot-alltargets
|
||||
TESTS+= varname-dot-curdir
|
||||
TESTS+= varname-dot-includes
|
||||
TESTS+= varname-dot-includedfromdir
|
||||
TESTS+= varname-dot-includedfromfile
|
||||
TESTS+= varname-dot-libs
|
||||
TESTS+= varname-dot-make-dependfile
|
||||
TESTS+= varname-dot-make-expand_variables
|
||||
TESTS+= varname-dot-make-exported
|
||||
|
|
|
@ -0,0 +1,2 @@
|
|||
.INCLUDES= -I. -I..
|
||||
exit status 0
|
|
@ -0,0 +1,20 @@
|
|||
# $NetBSD: varname-dot-includes.mk,v 1.1 2020/08/28 03:51:06 rillig Exp $
|
||||
#
|
||||
# Tests for the special .INCLUDES variable, which is not documented in the
|
||||
# manual page.
|
||||
#
|
||||
# It is yet unclear in which situations this feature is useful.
|
||||
|
||||
.SUFFIXES: .h
|
||||
|
||||
.PATH.h: . ..
|
||||
|
||||
.INCLUDES: .h
|
||||
|
||||
# The .INCLUDES variable is not yet available.
|
||||
.if defined(${.INCLUDES:Q})
|
||||
.error
|
||||
.endif
|
||||
|
||||
all:
|
||||
@echo .INCLUDES=${.INCLUDES:Q}
|
|
@ -0,0 +1,2 @@
|
|||
.LIBS= -L. -L..
|
||||
exit status 0
|
|
@ -0,0 +1,20 @@
|
|||
# $NetBSD: varname-dot-libs.mk,v 1.1 2020/08/28 03:51:06 rillig Exp $
|
||||
#
|
||||
# Tests for the special .LIBS variable, which is not documented in the
|
||||
# manual page.
|
||||
#
|
||||
# It is yet unclear in which situations this feature is useful.
|
||||
|
||||
.SUFFIXES: .a
|
||||
|
||||
.PATH.a: . ..
|
||||
|
||||
.LIBS: .a
|
||||
|
||||
# The .LIBS variable is not yet available.
|
||||
.if defined(${.LIBS:Q})
|
||||
.error
|
||||
.endif
|
||||
|
||||
all:
|
||||
@echo .LIBS=${.LIBS:Q}
|
Loading…
Reference in New Issue