1 dnl Process this file with autoconf to produce a configure script.
3 AM_INIT_AUTOMAKE(tinc, 1.0pre2)
4 AM_CONFIG_HEADER(config.h)
6 dnl Include the macros from the m4/ directory
9 # Enable GNU extensions.
10 # Define this here, not in acconfig's @TOP@ section, since definitions
11 # in the latter don't make it into the configure-time tests.
12 AC_DEFINE([_GNU_SOURCE], [__USE_BSD])
16 dnl Checks for programs.
19 AC_PROG_GCC_TRADITIONAL
29 dnl Checks for libraries.
31 dnl Checks for header files.
33 AC_CHECK_HEADERS(fcntl.h limits.h sys/ioctl.h syslog.h unistd.h gmp.h gmp2/gmp.h \
36 dnl Checks for typedefs, structures, and compiler characteristics.
43 dnl Checks for library functions.
47 AC_CHECK_FUNCS(ftime socket select strtol strerror)
51 # Check for the GNU Multi Precision Library
53 AC_CHECK_LIB(gmp2, mpz_powm, [
56 AC_CHECK_LIB(gmp3, mpz_powm, [
59 AC_CHECK_LIB(gmp, mpz_powm, [
63 if test $libgmp = none; then
64 AC_MSG_ERROR(libgmp is not installed. Please grab it from your
65 nearest GNU mirror and install it (see README))
67 LIBS="$LIBS -l$libgmp"
70 AC_CHECK_LIB(dl, dlopen, [
74 AC_OUTPUT([Makefile src/Makefile cipher/Makefile
75 cipher/blowfish/Makefile doc/Makefile intl/Makefile lib/Makefile
76 m4/Makefile po/Makefile.in redhat/Makefile debian/Makefile])