1 dnl Process this file with autoconf to produce a configure script.
3 AM_INIT_AUTOMAKE(tinc, 1.0)
4 AM_CONFIG_HEADER(config.h)
6 # Enable GNU extensions.
7 # Define this here, not in acconfig's @TOP@ section, since definitions
8 # in the latter don't make it into the configure-time tests.
9 AC_DEFINE([_GNU_SOURCE])
10 AC_DEFINE([__USE_BSD])
12 dnl Checks for programs.
15 AC_PROG_GCC_TRADITIONAL
24 dnl Checks for libraries.
26 dnl Checks for header files.
28 AC_CHECK_HEADERS(fcntl.h limits.h sys/ioctl.h syslog.h unistd.h gmp.h gmp2/gmp.h \
31 dnl Checks for typedefs, structures, and compiler characteristics.
39 dnl Checks for library functions.
43 AC_CHECK_FUNCS(ftime socket select strtol strerror)
47 # Check for the GNU Multi Precision Library
49 AC_CHECK_LIB(gmp2, mpz_powm, [
52 AC_CHECK_LIB(gmp, mpz_powm, [
56 if test $libgmp = none; then
57 AC_MSG_ERROR(libgmp is not installed. Please grab it from your
58 nearest GNU mirror and install it (see README))
60 LIBS="$LIBS -l$libgmp"
63 AC_OUTPUT([Makefile src/Makefile cipher/Makefile cipher/blowfish/Makefile
64 cipher/idea/Makefile doc/Makefile lib/Makefile m4/Makefile redhat/Makefile])