1# $FreeBSD$ 2 3TESTSRC= ${SRCTOP}/contrib/netbsd-tests/lib/libm 4 5# All architectures on FreeBSD have fenv.h 6CFLAGS+= -DHAVE_FENV_H 7 8# Not sure why this isn't defined for all architectures, since most 9# have long double. 10.if ${MACHINE_CPUARCH} == "aarch64" || \ 11 ${MACHINE_CPUARCH} == "amd64" || \ 12 ${MACHINE_CPUARCH} == "i386" 13CFLAGS+= -D__HAVE_LONG_DOUBLE 14.endif 15 16NETBSD_ATF_TESTS_C= acos_test 17NETBSD_ATF_TESTS_C+= asin_test 18NETBSD_ATF_TESTS_C+= atan_test 19NETBSD_ATF_TESTS_C+= cbrt_test 20NETBSD_ATF_TESTS_C+= ceil_test 21NETBSD_ATF_TESTS_C+= cos_test 22NETBSD_ATF_TESTS_C+= cosh_test 23NETBSD_ATF_TESTS_C+= erf_test 24NETBSD_ATF_TESTS_C+= exp_test 25NETBSD_ATF_TESTS_C+= fmod_test 26NETBSD_ATF_TESTS_C+= infinity_test 27NETBSD_ATF_TESTS_C+= ldexp_test 28NETBSD_ATF_TESTS_C+= log_test 29NETBSD_ATF_TESTS_C+= pow_test 30NETBSD_ATF_TESTS_C+= precision_test 31NETBSD_ATF_TESTS_C+= round_test 32NETBSD_ATF_TESTS_C+= scalbn_test 33NETBSD_ATF_TESTS_C+= sin_test 34NETBSD_ATF_TESTS_C+= sinh_test 35NETBSD_ATF_TESTS_C+= sqrt_test 36NETBSD_ATF_TESTS_C+= tan_test 37NETBSD_ATF_TESTS_C+= tanh_test 38 39TAP_TESTS_C+= cexp_test 40TAP_TESTS_C+= conj_test 41TAP_TESTS_C+= csqrt_test 42TAP_TESTS_C+= ctrig_test 43TAP_TESTS_C+= exponential_test 44TAP_TESTS_C+= fenv_test 45TAP_TESTS_C+= fma_test 46TAP_TESTS_C+= fmaxmin_test 47TAP_TESTS_C+= ilogb_test 48TAP_TESTS_C+= invtrig_test 49TAP_TESTS_C+= invctrig_test 50TAP_TESTS_C+= logarithm_test 51TAP_TESTS_C+= lrint_test 52# XXX: the testcase crashes on all platforms, but only on head 53# (bug 205451) 54#TAP_TESTS_C+= lround_test 55TAP_TESTS_C+= nan_test 56TAP_TESTS_C+= nearbyint_test 57TAP_TESTS_C+= next_test 58TAP_TESTS_C+= rem_test 59TAP_TESTS_C+= trig_test 60 61.for t in ${TAP_TESTS_C} 62CFLAGS.$t+= -O0 63.endfor 64 65CSTD= c99 66 67#COPTS+= -Wfloat-equal 68 69IGNORE_PRAGMA= 70 71LIBADD+= m 72 73# Copied from lib/msun/Makefile 74.if ${MACHINE_CPUARCH} == "i386" 75ARCH_SUBDIR= i387 76.else 77ARCH_SUBDIR= ${MACHINE_CPUARCH} 78.endif 79 80.include "../${ARCH_SUBDIR}/Makefile.inc" 81 82# XXX: for some odd reason float.h doesn't tell the full story about what the 83# precision is. 84CFLAGS+= -DLDBL_PREC=${LDBL_PREC} 85 86.include <netbsd-tests.test.mk> 87 88.include <bsd.test.mk> 89