svn commit: r291883 - user/ngie/make_check/share/mk
Garrett Cooper
ngie at FreeBSD.org
Sun Dec 6 01:46:54 UTC 2015
Author: ngie
Date: Sun Dec 6 01:46:52 2015
New Revision: 291883
URL: https://svnweb.freebsd.org/changeset/base/291883
Log:
Check for the KYUA package as a dependency of `make check`
Provide a helpful error message if/when it's not installed
Document KYUA_PREFIX
Modified:
user/ngie/make_check/share/mk/bsd.README
user/ngie/make_check/share/mk/suite.test.mk
Modified: user/ngie/make_check/share/mk/bsd.README
==============================================================================
--- user/ngie/make_check/share/mk/bsd.README Sun Dec 6 01:13:18 2015 (r291882)
+++ user/ngie/make_check/share/mk/bsd.README Sun Dec 6 01:46:52 2015 (r291883)
@@ -450,10 +450,12 @@ It has seven targets:
build the test programs.
check:
runs the test programs from the object directory; if the
- Makefile does not itself define the target test, the
- targets beforecheck and aftercheck may also be used to
- cause actions immediately before and after the test
- target is executed.
+ Makefile does not itself define the target test, the targets
+ beforecheck and aftercheck may also be used to cause actions
+ immediately before and after the test target is executed.
+
+ The devel/kyua package must be installed before invoking this
+ target.
clean:
remove the test programs and any object files.
cleandir:
@@ -492,6 +494,10 @@ KYUAFILE If 'auto' (the default), genera
subdirectories providing helper programs or data files
only).
+KYUA_PREFIX The --prefix for the kyua package.
+
+ The value of KYUA_PREFIX defaults to /usr/local .
+
ATF_TESTS_C The names of the ATF C test programs to build.
ATF_TESTS_CXX The names of the ATF C++ test programs to build.
Modified: user/ngie/make_check/share/mk/suite.test.mk
==============================================================================
--- user/ngie/make_check/share/mk/suite.test.mk Sun Dec 6 01:13:18 2015 (r291882)
+++ user/ngie/make_check/share/mk/suite.test.mk Sun Dec 6 01:46:52 2015 (r291883)
@@ -90,10 +90,8 @@ Kyuafile: Makefile
_kyuafile= ${DESTDIR}${TESTSDIR}/Kyuafile
-KYUA?= ${KYUA_PREFIX}/bin/kyua
+KYUA= ${KYUA_PREFIX}/bin/kyua
-realcheck: .PHONY
-.if exists(${KYUA})
# Definition of the "make check" target and supporting variables.
#
# This target, by necessity, can only work for native builds (i.e. a FreeBSD
@@ -103,5 +101,16 @@ realcheck: .PHONY
# Due to the dependencies of the binaries built by the source tree and how they
# are used by tests, it is highly possible for a execution of "make test" to
# report bogus results unless the new binaries are put in place.
+
+${KYUA}:
+ @echo
+ @echo "kyua binary not installed at expected location (${.TARGET})"
+ @echo
+ @echo "Please install via pkg install, or specify the path to the kyua"
+ @echo "package via the \$${KYUA_PREFIX} variable, e.g. "
+ @echo "KYUA_PREFIX=\"${KYUA_PREFIX}\""
+ @false
+
+realcheck: .PHONY
+realcheck: ${KYUA}
@${KYUA} test -k ${DESTDIR}${TESTSDIR}/Kyuafile
-.endif
More information about the svn-src-user
mailing list