]> git.mxchange.org Git - flightgear.git/blobdiff - configure.ac
Functions should always return a value
[flightgear.git] / configure.ac
index 377725771a735e2f222e77d953c5c3b322e8bb02..3ea1d4f501d180400e3c1639993fb46afa048cee 100644 (file)
@@ -10,7 +10,7 @@ AC_PREREQ(2.52)
 dnl Initialize the automake stuff
 dnl set the $host variable based on local machine/os
 AC_CANONICAL_TARGET
-AM_INIT_AUTOMAKE(FlightGear, 1.99.5)
+AM_INIT_AUTOMAKE(FlightGear, 1.9.1)
 
 dnl Checks for programs.
 AC_PROG_MAKE_SET
@@ -20,6 +20,11 @@ AC_PROG_CXX
 AC_PROG_RANLIB
 AC_PROG_INSTALL
 AC_PROG_LN_S
+AX_BOOST_BASE([1.34.0])
+
+if test "x$BOOST_CPPFLAGS" != "x-I/usr/include" ; then
+   CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS"
+fi
 
 # specify the simgear location
 AC_ARG_WITH(simgear, [  --with-simgear=PREFIX   Specify the prefix path to SimGear])
@@ -46,14 +51,6 @@ if test "x$with_osg" != "x" ; then
     EXTRA_DIRS="${EXTRA_DIRS} $with_osg"
 fi
 
-# specify Boost location
-AC_ARG_WITH(osg, [  --with-boost=PREFIX       Specify the prefix path to Boost])
-
-if test "x$with_boost" != "x" ; then
-    echo "Boost prefix is $with_boost"
-    EXTRA_DIRS="${EXTRA_DIRS} $with_boost"
-fi
-
 dnl Determine an extra directories to add to include/lib search paths
 case "${host}" in
 *-apple-darwin* | *-*-mingw32*)
@@ -202,6 +199,7 @@ dnl check for some default libraries
 AC_SEARCH_LIBS(sqrt, [am ffm fm fastm m])
 AC_SEARCH_LIBS(ceil, m)
 AC_SEARCH_LIBS(dlclose, dl)
+AC_SEARCH_LIBS(clock_gettime, rt)
 
 base_LIBS="$LIBS"
 
@@ -398,7 +396,7 @@ if test "x$ac_cv_header_simgear_version_h" != "xyes"; then
     exit
 fi
 
-AC_MSG_CHECKING([for SimGear 1.99.5 or newer])
+AC_MSG_CHECKING([for SimGear 1.9.0 or newer])
 AC_TRY_RUN([
 #include <stdio.h>
 
@@ -408,8 +406,8 @@ AC_TRY_RUN([
 #define XSTRINGIFY(X) #X
 
 #define MIN_MAJOR 1
-#define MIN_MINOR 99
-#define MIN_MICRO 5
+#define MIN_MINOR 9
+#define MIN_MICRO 0
 
 int main() {
     int major, minor, micro;
@@ -513,15 +511,6 @@ if test "x$ac_cv_header_osg_Version" != "xyes"; then
     exit
 fi
 
-AC_CHECK_HEADER(boost/foreach.hpp)
-if test "x$ac_cv_header_boost_foreach_hpp" != "xyes"; then
-   echo
-   echo "You *must* have the Boost libraries installed."
-   echo
-   echo "configure aborted."
-   exit
-fi
-
 # Find the OSG libraries.  Note special handling for OS X frameworks
 case "${host}" in
 *-apple-darwin*)
@@ -618,7 +607,7 @@ dnl Check for Subversion library support
 save_LIBS=$LIBS
 save_CPPFLAGS=$CPPFLAGS
 LIBS=""
-CPPFLAGS="-I/usr/include/subversion-1 -I/usr/include/apr-1.0"
+CPPFLAGS="-I/usr/include/subversion-1 `apr-1-config --includes`"
 AC_CHECK_LIB(svn_client-1, svn_client_checkout3)
 AC_CHECK_HEADERS([svn_client.h])
 if test "x$ac_cv_header_svn_client_h" != "xyes"; then
@@ -636,6 +625,13 @@ fi
 LIBS=$save_LIBS
 CPPFLAGS=$save_CPPFLAGS
 
+AC_MSG_CHECKING([for feenableexcept])
+AC_LINK_IFELSE([AC_LANG_PROGRAM([[#define _GNU_SOURCE
+#include <fenv.h>]], [[feenableexcept(FE_DIVBYZERO)]])],
+[AC_DEFINE([HAVE_FEENABLEEXCEPT], 1, [define if system has fenableexcept])],
+AC_MSG_RESULT([yes]),
+AC_MSG_RESULT([no]))
+
 dnl Checks for header files.
 AC_HEADER_STDC
 AC_CHECK_HEADERS( \