1 AC_DEFUN([AX_CHECK_NTL], [
3 SAVE_CPPFLAGS="$CPPFLAGS"
4 SAVE_LDFLAGS="$LDFLAGS"
5 CPPFLAGS="$NTL_CPPFLAGS $CPPFLAGS"
6 LDFLAGS="$NTL_LDFLAGS $LDFLAGS"
8 AC_CHECK_HEADER([NTL/ZZ.h],[],[bv_no_ntl=true])
14 ],:,AC_MSG_ERROR(ntl not compiled with gmp support))
16 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
20 [AC_MSG_ERROR(Upgrade NTL or configure with NTL_STD_CXX=on)])
23 AC_CHECK_LIB(ntl, main,[],[bv_no_ntl=true])
24 if test "$bv_no_ntl" = "true"; then
25 AC_MSG_ERROR(Need ntl)
27 CPPFLAGS="$SAVE_CPPFLAGS"
28 LDFLAGS="$SAVE_LDFLAGS"