source: git/libpolys/configure.ac @ c0bbad

spielwiese
Last change on this file since c0bbad was c0bbad, checked in by Oleksandr Motsak <motsak@…>, 10 years ago
Minor BS cleanup
  • Property mode set to 100644
File size: 3.8 KB
RevLine 
[997a5b2]1AC_INIT([libpolys], [4.0.0])
[ab788d]2
[8184703]3AC_CONFIG_MACRO_DIR([../m4])
4AC_CONFIG_AUX_DIR([.])
[d11524]5AC_CONFIG_SRCDIR([reporter/reporter.h])
[996cc8]6AC_CONFIG_HEADER([_config.h])
[ab788d]7
[b3d84d]8AM_MAINTAINER_MODE([enable])
9
[24a77fb]10AM_INIT_AUTOMAKE([-Wall foreign subdir-objects]) # -Wno-extra-portability -Werror silent-rules
[25761d]11m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
[280286e]12m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
[2e984a]13
[84c376]14dnl Check if build env is sane
15AM_SANITY_CHECK
16
[ba5e9e]17# Add pre'prefixed config
[996cc8]18AX_PREFIX_CONFIG_H([libpolysconfig.h],[],[_config.h])
[ba5e9e]19
[f86531]20# - Check for CC and CXX but be careful about CFLAGS.
[7d160bb]21SING_RESET_FLAGS()
22SING_CHECK_SET_ARGS()
23
[f86531]24AC_PROG_CC
25AC_PROG_CXX
[e078e0]26AM_PROG_CC_C_O
27AC_PROG_LN_S
28AC_PROG_INSTALL
29
[4c5b46]30# Turn off shared libraries during beta-testing, since they
31# make the build process take too long.
[80c102]32LT_INIT
33# ([shared])
34# LT_INIT(dlopen disable-static) # doesn't work on PowerPC!
[72b880]35
[4aa8610]36# Checks for libraries.
[9af8a63]37LB_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]38LB_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)]))
[c70920]39## LB_CHECK_FLINT(2.3,,AC_MSG_WARN([Unable to find FLINT (which is strongly recommended) on your machine: please use --with-flint=PATH_TO_DIR_CONTAINING_LIB_AND_INCLUDE (see also ./configure --help if you do not understand what we are talking about)]))
40
[643b1eb]41
[720156]42# Checks for library functions.
43AC_FUNC_ERROR_AT_LINE
[eb2d25]44AC_CHECK_FUNCS([memmove memset pow sqrt strchr setenv putenv])
[ec0d9b]45AC_FUNC_VPRINTF
46AC_FUNC_MALLOC
[84c376]47AC_CHECK_FUNC([vsnprintf], [AC_DEFINE([HAVE_VSNPRINTF], [1], [Define if vsnprintf exists.])])
[720156]48
[d11524]49# Checks for header files.
50AC_HEADER_STDC
[84c376]51AC_STDC_HEADERS
[56bce65]52AC_CHECK_HEADERS([stdlib.h string.h unistd.h pwd.h sys/param.h limits.h float.h execinfo.h])
53
54# If the compiler supports GCC C++ ABI name demangling (has header
55#   cxxabi.h and abi::__cxa_demangle() function), define
56#   HAVE_GCC_ABI_DEMANGLE
57AX_CXX_GCC_ABI_DEMANGLE
[d11524]58
59# Checks for typedefs, structures, and compiler characteristics.
60AC_C_CONST
61AC_C_INLINE
[720156]62AC_HEADER_STDBOOL
63AC_TYPE_SIZE_T
[d11524]64
[ea5f3f6]65# SING_CHECK_PIPE
[d11524]66
67# check for cpu properties
68AC_CHECK_SIZEOF(long,4)
69SING_CHECK_CPU
70
[720156]71#check for host:
72AC_CANONICAL_HOST
[da7a28]73
[720156]74case $host_os in
[da7a28]75  *cygwin* ) AX_APPEND_LINK_FLAGS([-Wl,-Bdynamic]);;
[720156]76esac
77
[84c376]78dnl INCLUDES=""
[da7a28]79dnl dnl OS specific flags and options (does work without the following:)
[84c376]80dnl case "$host" in
81dnl     *-*-freebsd*)
82dnl         LIBS="$LIBS -L/usr/local/lib -lc"
83dnl     CFLAGS="$CFLAGS -I/usr/local/include"
84dnl     INCLUDES="$INCLUDES -I/usr/local/include"
85dnl     ;;
86dnl esac       
87dnl AC_SUBST(INCLUDES)
88
[ec0d9b]89SING_CHECK_P_PROCS
[568cf0]90SING_CHECK_ARITH_RINGS
[45e35b]91SING_CHECK_FACTORY
92SING_CHECK_PLURAL
[bea370]93
[964389]94# AC_SUBST(PREFIX)
[f284db]95# AC_DEFINE_UNQUOTED(INSTALL_PREFIX,"$PREFIX",Prefix)
[964389]96
[f3ea6ce]97AC_DEFINE([SINGULAR],[1],[SINGULAR])
98AC_DEFINE([DISABLE_GMP_CPP],[1],[DISABLE_GMP_CPP])
99AC_DEFINE([NOSTREAMIO],[1],[DISABLE_GMP_CPP])
100
[c1e7a6]101AX_PYTHON_DEFAULT()
102AX_PYTHON_WITH_VERSION([2.4])
103
[c70920]104AC_DEFINE_UNQUOTED([NTL_CFLAGS],"$NTL_CFLAGS",[NTL_CFLAGS])
105AC_DEFINE_UNQUOTED([NTL_LIBS],"$NTL_LIBS",[NTL_LIBS])
106
107AC_DEFINE_UNQUOTED([GMP_CFLAGS],"$GMP_CFLAGS",[GMP_CFLAGS])
108AC_DEFINE_UNQUOTED([GMP_LIBS],"$GMP_LIBS",[GMP_LIBS])
109
110# AC_DEFINE_UNQUOTED([FLINT_CFLAGS],"$FLINT_CFLAGS",[FLINT_CFLAGS])
111# AC_DEFINE_UNQUOTED([FLINT_LIBS],"$FLINT_LIBS",[FLINT_LIBS])
112
[047597]113## AC_DEFINE([HAVE_POLYEXTENSIONS], [1], [Enable the algebraic & transcendental extensions])
114
[014b65]115AC_CONFIG_FILES([Makefile])
[d11524]116AC_CONFIG_FILES([misc/Makefile])
117AC_CONFIG_FILES([reporter/Makefile])
[720156]118AC_CONFIG_FILES([coeffs/Makefile])
[ec0d9b]119AC_CONFIG_FILES([polys/Makefile])
[4aa8610]120AC_CONFIG_FILES([tests/Makefile])
[996cc8]121AC_CONFIG_FILES([libpolys-config libpolys.pc  misc/auxiliary.h])
[014b65]122AC_OUTPUT
Note: See TracBrowser for help on using the repository browser.