[ab788d] | 1 | AC_INIT([libpolys], [3.1.2.sw]) |
---|
| 2 | |
---|
[8184703] | 3 | AC_CONFIG_MACRO_DIR([../m4]) |
---|
| 4 | AC_CONFIG_AUX_DIR([.]) |
---|
[d11524] | 5 | AC_CONFIG_SRCDIR([reporter/reporter.h]) |
---|
[41dde6] | 6 | AC_CONFIG_HEADER([config.h misc/auxiliary.h]) |
---|
[ab788d] | 7 | |
---|
[ea0001] | 8 | AM_MAINTAINER_MODE |
---|
[24a77fb] | 9 | AM_INIT_AUTOMAKE([-Wall foreign subdir-objects]) # -Wno-extra-portability -Werror silent-rules |
---|
[2e984a] | 10 | m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES]) |
---|
[280286e] | 11 | m4_ifdef([AM_PROG_AR], [AM_PROG_AR]) |
---|
[2e984a] | 12 | |
---|
[84c376] | 13 | dnl Check if build env is sane |
---|
| 14 | AM_SANITY_CHECK |
---|
| 15 | |
---|
[f86531] | 16 | # - Check for CC and CXX but be careful about CFLAGS. |
---|
[7d160bb] | 17 | SING_RESET_FLAGS() |
---|
| 18 | SING_CHECK_SET_ARGS() |
---|
| 19 | |
---|
[f86531] | 20 | AC_PROG_CC |
---|
| 21 | AC_PROG_CXX |
---|
[e078e0] | 22 | AM_PROG_CC_C_O |
---|
| 23 | AC_PROG_LN_S |
---|
| 24 | AC_PROG_INSTALL |
---|
| 25 | |
---|
[4c5b46] | 26 | # Turn off shared libraries during beta-testing, since they |
---|
| 27 | # make the build process take too long. |
---|
[80c102] | 28 | LT_INIT |
---|
| 29 | # ([shared]) |
---|
| 30 | # LT_INIT(dlopen disable-static) # doesn't work on PowerPC! |
---|
[72b880] | 31 | |
---|
[4aa8610] | 32 | # Checks for libraries. |
---|
[9af8a63] | 33 | LB_CHECK_GMP(3.1.1,,AC_MSG_ERROR([Unable to find GMP on your machine: please use --with-gmp=PATH_TO_DIR_CONTAINING_LIB_AND_INCLUDE (see also ./configure --help if you do not understand what we are talking about)])) |
---|
[643b1eb] | 34 | LB_CHECK_NTL(5.0,,AC_MSG_WARN([Unable to find NTL (which is strongly recommended) on your machine: please use --with-ntl=PATH_TO_DIR_CONTAINING_LIB_AND_INCLUDE (see also ./configure --help if you do not understand what we are talking about)])) |
---|
| 35 | |
---|
[720156] | 36 | # Checks for library functions. |
---|
| 37 | AC_FUNC_ERROR_AT_LINE |
---|
[eb2d25] | 38 | AC_CHECK_FUNCS([memmove memset pow sqrt strchr setenv putenv]) |
---|
[ec0d9b] | 39 | AC_FUNC_VPRINTF |
---|
| 40 | AC_FUNC_MALLOC |
---|
[84c376] | 41 | AC_CHECK_FUNC([vsnprintf], [AC_DEFINE([HAVE_VSNPRINTF], [1], [Define if vsnprintf exists.])]) |
---|
[720156] | 42 | |
---|
[d11524] | 43 | # Checks for header files. |
---|
| 44 | AC_HEADER_STDC |
---|
[84c376] | 45 | AC_STDC_HEADERS |
---|
[56bce65] | 46 | AC_CHECK_HEADERS([stdlib.h string.h unistd.h pwd.h sys/param.h limits.h float.h execinfo.h]) |
---|
| 47 | |
---|
| 48 | # If the compiler supports GCC C++ ABI name demangling (has header |
---|
| 49 | # cxxabi.h and abi::__cxa_demangle() function), define |
---|
| 50 | # HAVE_GCC_ABI_DEMANGLE |
---|
| 51 | AX_CXX_GCC_ABI_DEMANGLE |
---|
[d11524] | 52 | |
---|
| 53 | # Checks for typedefs, structures, and compiler characteristics. |
---|
| 54 | AC_C_CONST |
---|
| 55 | AC_C_INLINE |
---|
[720156] | 56 | AC_HEADER_STDBOOL |
---|
| 57 | AC_TYPE_SIZE_T |
---|
[d11524] | 58 | |
---|
[ea5f3f6] | 59 | # SING_CHECK_PIPE |
---|
[d11524] | 60 | |
---|
| 61 | # check for cpu properties |
---|
| 62 | AC_CHECK_SIZEOF(long,4) |
---|
| 63 | SING_CHECK_CPU |
---|
| 64 | |
---|
[720156] | 65 | #check for host: |
---|
| 66 | AC_CANONICAL_HOST |
---|
| 67 | case $host_os in |
---|
| 68 | *cygwin* ) LIBPREFIX="-Xlinker -Bdynamic";; |
---|
| 69 | * ) LIBPREFIX="";; |
---|
| 70 | esac |
---|
| 71 | |
---|
[84c376] | 72 | dnl INCLUDES="" |
---|
| 73 | dnl dnl OS specific flags and options |
---|
| 74 | dnl case "$host" in |
---|
| 75 | dnl *-*-freebsd*) |
---|
| 76 | dnl LIBS="$LIBS -L/usr/local/lib -lc" |
---|
| 77 | dnl CFLAGS="$CFLAGS -I/usr/local/include" |
---|
| 78 | dnl INCLUDES="$INCLUDES -I/usr/local/include" |
---|
| 79 | dnl ;; |
---|
| 80 | dnl esac |
---|
| 81 | dnl AC_SUBST(INCLUDES) |
---|
| 82 | |
---|
[ec0d9b] | 83 | SING_CHECK_P_PROCS |
---|
[568cf0] | 84 | SING_CHECK_ARITH_RINGS |
---|
[45e35b] | 85 | SING_CHECK_FACTORY |
---|
| 86 | SING_CHECK_PLURAL |
---|
[bea370] | 87 | |
---|
[964389] | 88 | # AC_SUBST(PREFIX) |
---|
[f284db] | 89 | # AC_DEFINE_UNQUOTED(INSTALL_PREFIX,"$PREFIX",Prefix) |
---|
[964389] | 90 | |
---|
[f3ea6ce] | 91 | AC_DEFINE([SINGULAR],[1],[SINGULAR]) |
---|
| 92 | AC_DEFINE([DISABLE_GMP_CPP],[1],[DISABLE_GMP_CPP]) |
---|
| 93 | AC_DEFINE([NOSTREAMIO],[1],[DISABLE_GMP_CPP]) |
---|
| 94 | |
---|
[c1e7a6] | 95 | AX_PYTHON_DEFAULT() |
---|
| 96 | AX_PYTHON_WITH_VERSION([2.4]) |
---|
| 97 | |
---|
[047597] | 98 | ## AC_DEFINE([HAVE_POLYEXTENSIONS], [1], [Enable the algebraic & transcendental extensions]) |
---|
| 99 | |
---|
[014b65] | 100 | AC_CONFIG_FILES([Makefile]) |
---|
[d11524] | 101 | AC_CONFIG_FILES([misc/Makefile]) |
---|
| 102 | AC_CONFIG_FILES([reporter/Makefile]) |
---|
[720156] | 103 | AC_CONFIG_FILES([coeffs/Makefile]) |
---|
[ec0d9b] | 104 | AC_CONFIG_FILES([polys/Makefile]) |
---|
[4aa8610] | 105 | AC_CONFIG_FILES([tests/Makefile]) |
---|
[c5917f1] | 106 | AC_CONFIG_FILES([libpolys-config]) |
---|
[014b65] | 107 | AC_OUTPUT |
---|