2015-02-28 23:30:06 +00:00
|
|
|
# $FreeBSD$
|
|
|
|
|
|
|
|
TESTGROUP= ${.CURDIR:H:T}/${.CURDIR:T}
|
2016-05-04 23:20:53 +00:00
|
|
|
TESTSRC= ${SRCTOP}/cddl/contrib/opensolaris/cmd/dtrace/test/tst/${TESTGROUP}
|
2015-02-28 23:30:06 +00:00
|
|
|
TESTSDIR= ${TESTSBASE}/cddl/usr.sbin/dtrace/${TESTGROUP}
|
|
|
|
|
2016-05-04 23:20:53 +00:00
|
|
|
FILESGROUPS+= ${TESTGROUP}EXE
|
2015-02-28 23:30:06 +00:00
|
|
|
|
|
|
|
${TESTGROUP}EXE= ${TESTEXES}
|
|
|
|
${TESTGROUP}EXEMODE= 0555
|
2016-05-04 23:20:53 +00:00
|
|
|
${TESTGROUP}EXEPACKAGE= ${PACKAGE}
|
2015-02-28 23:30:06 +00:00
|
|
|
|
|
|
|
TESTWRAPPER= t_dtrace_contrib
|
|
|
|
ATF_TESTS_SH+= ${TESTWRAPPER}
|
|
|
|
TEST_METADATA.t_dtrace_contrib+= required_files="/usr/local/bin/ksh"
|
|
|
|
TEST_METADATA.t_dtrace_contrib+= required_user="root"
|
|
|
|
|
|
|
|
GENTEST?= ${.CURDIR:H:H}/tools/gentest.sh
|
|
|
|
EXCLUDE= ${.CURDIR:H:H}/tools/exclude.sh
|
2016-05-04 23:20:53 +00:00
|
|
|
${TESTWRAPPER}.sh: ${GENTEST} ${EXCLUDE} ${${PACKAGE}FILES}
|
2016-05-10 20:25:49 +00:00
|
|
|
sh ${GENTEST} -e ${EXCLUDE} ${TESTGROUP} ${${PACKAGE}FILES:S/ */ /} > ${.TARGET}
|
2015-02-28 23:30:06 +00:00
|
|
|
|
|
|
|
CLEANFILES+= ${TESTWRAPPER}.sh
|
|
|
|
|
|
|
|
.PATH: ${TESTSRC}
|
|
|
|
|
|
|
|
PROGS= ${CFILES:T:S/.c$/.exe/g}
|
|
|
|
.for prog in ${PROGS}
|
|
|
|
SRCS.${prog}+= ${prog:S/.exe$/.c/}
|
|
|
|
|
|
|
|
.if exists(${prog:S/^tst.//:S/.exe$/.d/})
|
|
|
|
SRCS.${prog}+= ${prog:S/^tst.//:S/.exe$/.d/}
|
|
|
|
.endif
|
|
|
|
.endfor
|
|
|
|
|
2015-11-09 02:29:38 +00:00
|
|
|
BINDIR= ${TESTSDIR}
|
|
|
|
MAN=
|
|
|
|
|
2015-02-28 23:30:06 +00:00
|
|
|
# Some tests depend on the internals of their corresponding test programs,
|
|
|
|
# so make sure the optimizer doesn't interfere with them.
|
|
|
|
CFLAGS+= -O0
|
|
|
|
|
|
|
|
# Test programs shouldn't be stripped; else we generally can't use the PID
|
|
|
|
# provider.
|
|
|
|
DEBUG_FLAGS= -g
|
|
|
|
STRIP=
|
|
|
|
|
|
|
|
.include <bsd.test.mk>
|