summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac19
1 files changed, 19 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 9cdb5efe..e1fc2e77 100644
--- a/configure.ac
+++ b/configure.ac
@@ -109,6 +109,25 @@ else
AC_MSG_FAILURE("Could not find gmp library (set CPPFLAGS and LDFLAGS?)")
fi
+# check for mpfr
+AC_CACHE_CHECK(
+ [if libmpfr is available],
+ [libmpfr_avail_cv_],
+ [libmpfr_save_libs=$LIBS
+ LIBS="-lmpfr $LIBS"
+ AC_LANG_PUSH(C++)
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <mpfr.h>]], [[mpfr_t bar;
+ mpfr_init(bar);
+ mpfr_clear(bar);]])],[libmpfr_avail_cv_=true],[libmpfr_avail_cv_=false])
+ AC_LANG_POP
+ LIBS=$libmpfr_save_libs])
+
+if [test x$libmpfr_avail_cv_ = xtrue ]; then
+ LIBS="-lmpfr $LIBS"
+else
+ AC_MSG_FAILURE("Could not find mpfr library (set CPPFLAGS and LDFLAGS?)")
+fi
+
# check for boost_regex
AC_CACHE_CHECK(
[if boost_regex is available],