summaryrefslogtreecommitdiff
path: root/configure.ac
blob: 9a351a71491477b672c9b348be167b25d91f8aa7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#                                               -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.

AC_PREREQ(2.61)
AC_INIT(mpc, 0.4.7, mpc-discuss@lists.gforge.inria.fr)
AC_CONFIG_SRCDIR([mpc-impl.h])
AC_CONFIG_HEADER([config.h])

AM_INIT_AUTOMAKE([1.9 -Wall -Werror])
AM_MAINTAINER_MODE

AM_CFLAGS="-O2 -g"

dnl Extra arguments to configure
AC_ARG_WITH([mpfr],
            AC_HELP_STRING([--with-mpfr=DIR],
                           [MPFR install directory]),
            [
            CPPFLAGS="$CPPFLAGS -I$withval/include"
            LDFLAGS="$LDFLAGS -L$withval/lib"
            ])
AC_ARG_WITH([gmp],
            AC_HELP_STRING([--with-gmp=DIR],
                           [GMP install directory]),
            [
            CPPFLAGS="$CPPFLAGS -I$withval/include"
            LDFLAGS="$LDFLAGS -L$withval/lib"
            ])

# Checks for programs.
AC_PROG_CC
AC_PROG_LIBTOOL

# Checks for libraries.
AC_CHECK_LIB([mpfr], [mpfr_clear],,
             AC_MSG_ERROR([MPC library needs the MPFR library]))

# Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS([limits.h stdlib.h])

# Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST
AC_TYPE_SIZE_T

# Checks for library functions.

AC_CONFIG_FILES([Makefile])
AC_OUTPUT