1# $FreeBSD$ 2 3PACKAGE= tests 4 5TESTSRC= ${SRCTOP}/contrib/netbsd-tests/kernel 6.PATH: ${SRCTOP}/sys/kern 7 8TESTSDIR= ${TESTSBASE}/sys/kern 9 10#ATF_TESTS_C+= kcov 11ATF_TESTS_C+= kern_copyin 12ATF_TESTS_C+= kern_descrip_test 13ATF_TESTS_C+= kill_zombie 14ATF_TESTS_C+= memfd_test 15ATF_TESTS_C+= ptrace_test 16TEST_METADATA.ptrace_test+= timeout="15" 17ATF_TESTS_C+= reaper 18ATF_TESTS_C+= sigaltstack 19PLAIN_TESTS_C+= subr_unit_test 20ATF_TESTS_C+= sys_getrandom 21ATF_TESTS_C+= unix_passfd_test 22ATF_TESTS_C+= unix_seqpacket_test 23TEST_METADATA.unix_seqpacket_test+= timeout="15" 24ATF_TESTS_C+= unix_socketpair_test 25ATF_TESTS_C+= waitpid_nohang 26ATF_TESTS_C+= pdeathsig 27 28ATF_TESTS_SH+= coredump_phnum_test 29ATF_TESTS_SH+= sonewconn_overflow 30TEST_METADATA.sonewconn_overflow+= required_programs="python" 31TEST_METADATA.sonewconn_overflow+= required_user="root" 32ATF_TESTS_SH+= sendfile_test 33 34${PACKAGE}FILES+= sonewconn_overflow.py 35${PACKAGE}FILESMODE_sonewconn_overflow.py=0555 36 37BINDIR= ${TESTSDIR} 38PROGS+= coredump_phnum_helper 39PROGS+= pdeathsig_helper 40PROGS+= sendfile_helper 41 42CFLAGS.sys_getrandom+= -I${SRCTOP}/sys/contrib/zstd/lib 43LIBADD.sys_getrandom+= zstd 44LIBADD.sys_getrandom+= c 45LIBADD.sys_getrandom+= pthread 46LIBADD.ptrace_test+= pthread 47LIBADD.unix_seqpacket_test+= pthread 48LIBADD.kcov+= pthread 49LIBADD.sendfile_helper+= pthread 50 51NETBSD_ATF_TESTS_C+= lockf_test 52NETBSD_ATF_TESTS_C+= mqueue_test 53NETBSD_ATF_TESTS_C+= sysv_test 54 55CFLAGS.mqueue_test+= -I${SRCTOP}/tests 56LIBADD.mqueue_test+= rt 57 58.if ${MACHINE_ARCH} == "amd64" || \ 59 ${MACHINE_ARCH} == "i386" || \ 60 ${MACHINE_ARCH} == "aarch64" 61ATF_TESTS_C+= libkern_crc32 62.if ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "i386" 63LDADD.libkern_crc32+= ${SRCTOP}/sys/libkern/x86/crc32_sse42.c 64.else 65LDADD.libkern_crc32+= ${SRCTOP}/sys/libkern/arm64/crc32c_armv8.S 66.endif 67.endif 68 69# subr_unit.c contains functions whose prototypes lie in headers that cannot be 70# included in userland. But as far as subr_unit_test goes, they're effectively 71# static. So it's ok to disable -Wmissing-prototypes for this program. 72CFLAGS.subr_unit.c+= -Wno-missing-prototypes 73SRCS.subr_unit_test+= subr_unit.c 74 75WARNS?= 3 76 77TESTS_SUBDIRS+= acct 78TESTS_SUBDIRS+= execve 79TESTS_SUBDIRS+= pipe 80 81.include <netbsd-tests.test.mk> 82 83.include <bsd.test.mk> 84