aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac16
1 files changed, 15 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index 6188dd50d136..0b386b075724 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,6 +1,6 @@
# Process this file with autoconf to produce a configure script.
-# Copyright (C) 1984-2009 Mark Nudelman
+# Copyright (C) 1984-2011 Mark Nudelman
#
# You may distribute under the terms of either the GNU General Public
# License or the Less License, as specified in the README file.
@@ -195,6 +195,8 @@ AH_TEMPLATE([HAVE_REGEXEC2],
[])
AH_TEMPLATE([HAVE_VOID],
[Define HAVE_VOID if your compiler supports the "void" type.])
+AH_TEMPLATE([HAVE_FLOAT],
+ [Define HAVE_FLOAT if your compiler supports the "double" type.])
AH_TEMPLATE([HAVE_CONST],
[Define HAVE_CONST if your compiler supports the "const" modifier.])
AH_TEMPLATE([HAVE_STAT_INO],
@@ -366,6 +368,18 @@ AC_ARG_WITH(secure,
[ --with-secure Compile in secure mode],
AC_DEFINE(SECURE_COMPILE, 1), AC_DEFINE(SECURE_COMPILE, 0))
+# Should we use floating point?
+AC_MSG_CHECKING(for floating point)
+AC_ARG_WITH(no-float,
+ [ --with-no-float Do not use floating point],
+ WANT_NO_FLOAT=1, WANT_NO_FLOAT=0)
+if test $WANT_NO_FLOAT = 0; then
+ AC_TRY_LINK(, [double f1 = 12.5; double f2 = f1*f1/2.5;],
+ [AC_MSG_RESULT(yes); AC_DEFINE(HAVE_FLOAT)], [AC_MSG_RESULT(no)])
+else
+ AC_MSG_RESULT(disabled by user)
+fi
+
# Checks for regular expression functions.
have_regex=no
have_posix_regex=unknown