summaryrefslogtreecommitdiff
path: root/testsuite/mk/test.mk
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/mk/test.mk')
-rw-r--r--testsuite/mk/test.mk10
1 files changed, 10 insertions, 0 deletions
diff --git a/testsuite/mk/test.mk b/testsuite/mk/test.mk
index 6e6def19ab..cb4b3747f5 100644
--- a/testsuite/mk/test.mk
+++ b/testsuite/mk/test.mk
@@ -100,6 +100,10 @@ HAVE_PROFILING := $(shell if [ -f $(subst \,/,$(GHC_PRIM_LIBDIR))/GHC/PrimopWrap
HAVE_GDB := $(shell if gdb --version > /dev/null 2> /dev/null; then echo YES; else echo NO; fi)
HAVE_READELF := $(shell if readelf --version > /dev/null 2> /dev/null; then echo YES; else echo NO; fi)
+# we need a better way to find which backend is selected and if --check flag is
+# used
+BIGNUM_GMP := $(shell "$(GHC_PKG)" field ghc-bignum exposed-modules | grep GMP)
+
ifeq "$(HAVE_VANILLA)" "YES"
RUNTEST_OPTS += -e config.have_vanilla=True
else
@@ -156,6 +160,12 @@ else
RUNTEST_OPTS += -e config.have_readelf=False
endif
+ifeq "$(BIGNUM_GMP)" ""
+RUNTEST_OPTS += -e config.have_fast_bignum=False
+else
+RUNTEST_OPTS += -e config.have_fast_bignum=True
+endif
+
ifeq "$(GhcDynamicByDefault)" "YES"
RUNTEST_OPTS += -e config.ghc_dynamic_by_default=True
CABAL_MINIMAL_BUILD = --enable-shared --disable-library-vanilla