2 # Process this file with autoconf to produce a configure script.
6 AC_INIT([cclive], m4_esyscmd([./gen-ver.sh -c | tr -d '\n']),
7 [http://cclive.sf.net/bugs/],[],[http://cclive.sf.net/])
9 AC_CONFIG_SRCDIR([src/cc/application.cpp])
10 AC_CONFIG_HEADERS([config.h])
11 AC_CONFIG_AUX_DIR([config.aux])
12 AC_CONFIG_MACRO_DIR([m4])
15 AC_USE_SYSTEM_EXTENSIONS
17 AC_DEFINE_UNQUOTED([CANONICAL_TARGET], "$target",
18 [Define to canonical target])
20 AM_INIT_AUTOMAKE([1.11.1 -Wall -Werror dist-xz no-dist-gzip tar-ustar])
21 AM_SILENT_RULES([yes])
23 # GNU Automake 1.12 requires this macro. Earlier versions do not
24 # recognize this macro. Work around this.
25 m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
27 LT_INIT([disable-static])
30 # Checks for programs.
36 AC_DEFINE_UNQUOTED([CXXFLAGS], "$CXXFLAGS", [Define to compiler flags])
37 AC_DEFINE_UNQUOTED([CXX], "$CXX", [Define to compiler])
39 AC_PATH_PROG([DATE], [date], [no])
40 AS_IF([test x"$DATE" != "xno"], [build_time=`$DATE +"%F %T %z"`])
41 AC_DEFINE_UNQUOTED([BUILD_TIME], ["$build_time"], [We have build time])
43 AC_PATH_PROG([A2X], [a2x], [no])
44 AM_CONDITIONAL([HAVE_A2X], [test x"$A2X" != "xno"])
47 AS_IF([test x"$A2X" = "xno" && test -d "$srcdir/.git"],
48 AC_MSG_ERROR([a2x is required to create man pages when building from git])])
50 # Checks for libraries.
53 PKG_CHECK_MODULES([libquvi], [libquvi-0.9 >= 0.9],
55 AC_DEFINE([HAVE_LIBQUVI_0_9], [1], [We have libquvi 0.9])
58 [PKG_CHECK_MODULES([libquvi], [libquvi >= 0.4])])
59 AM_CONDITIONAL([HAVE_LIBQUVI_0_9], [test x"$have_libquvi_0_9" = "xyes"])
61 PKG_CHECK_MODULES([libcurl], [libcurl >= 7.18.0])
62 PKG_CHECK_MODULES([libpcre], [libpcre >= 8.02])
63 PKG_CHECK_MODULES([libpcrecpp], [libpcrecpp >= 8.02])
64 PKG_CHECK_MODULES([glibmm], [glibmm-2.4 >= 2.24])
65 PKG_CHECK_MODULES([glib], [glib-2.0 >= 2.24])
67 BOOST_REQUIRE([1.49.0])
68 # Boost: Header-only libs
71 # Boost: Libs requiring linking
78 # Checks for header files.
79 AC_CHECK_HEADERS([sys/ioctl.h unistd.h sys/types.h sys/stat.h signal.h])
81 # Checks for typedefs, structures, and compiler characteristics.
87 # Checks for library functions.
88 AC_CHECK_FUNCS([strerror strstr getpid signal memset setlocale])
94 VN=`$srcdir/gen-ver.sh`
95 AC_DEFINE_UNQUOTED([VN],["$VN"], [We have version number from gen-ver.sh])
99 [AS_HELP_STRING([--with-manual],
100 [Install manual page(s) @<:@default=yes@:>@])],
103 AM_CONDITIONAL([WITH_MANUAL], [test x"$with_manual" != "xno"])
107 [AS_HELP_STRING([--enable-ccl],
108 [Symlink from 'cclive' executable to 'ccl' @<:@default=yes@:>@])],
111 AM_CONDITIONAL([ENABLE_CCL], [test x"$enable_ccl" = "xyes"])
132 add ccl symlink: ${enable_ccl}
133 install manual : ${with_manual}])
135 # vim: set ts=2 sw=2 tw=72 expandtab: