arm: allow to build with DODEBUG=y
[uclibc-ng.git] / test / math / Makefile.in
blob3874001515583efb0d057ea393bf2994ef6ffaf4
1 # uClibc math tests
2 # Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
4 # libm-test.c is a generated file used by the tests internally so skip it
5 TESTS_DISABLED := libm-test
7 # gamma (removed from TESTS, need to add "small errors are ok" machinery there)
8 TESTS_DISABLED += gamma
9 ifeq ($(UCLIBC_HAS_LONG_DOUBLE_MATH),)
10 TESTS_DISABLED += test-ldouble test-ildoubl compile_test c99_test
11 CFLAGS_basic-test := -DNO_LONG_DOUBLE
12 endif
13 ifeq ($(DO_C99_MATH),)
14 TESTS_DISABLED += test-float test-ifloat test-double test-idouble rint signgam ilogb
15 endif
16 ifeq ($(UCLIBC_HAS_FPU),)
17 TESTS_DISABLED += test-fpucw
18 endif
20 DODIFF_rint := 1
21 DODIFF_signgam := 1
23 # NOTE: For basic-test we must disable the floating point optimization.
24 # Only for sh architecture because in the other architecture are disabled.
25 ifeq ($(TARGET_ARCH),sh)
26 CFLAGS_basic-test += -mieee
27 endif
28 EXTRA_CFLAGS := -fno-builtin
29 EXTRA_LDFLAGS := -lm
31 PERL := perl
33 MDEPS := $(wildcard test-*.c)
34 $(MDEPS): libm-test.c
36 ULP_SUFFIX :=
37 ifeq ($(TARGET_ARCH),mips)
38 ULP_SUFFIX:=$(if $(CONFIG_MIPS_N64_ABI),64,32)
39 endif
41 TARGET_ULP := $(if $(wildcard libm-test-ulps-$(TARGET_ARCH)$(ULP_SUFFIX)),$(TARGET_ARCH)$(ULP_SUFFIX),generic)
43 libm-test.c: libm-test-ulps-$(TARGET_ULP) libm-test.inc gen-libm-test.pl
44 $(Q)$(PERL) ./gen-libm-test.pl -u libm-test-ulps-$(TARGET_ULP) ./libm-test.inc -o "." 2>&1 > /dev/null
46 EXTRA_CLEAN := libm-test.c libm-test-ulps.h