quvi/const: Add quvi-object http cookie options
[libquvi-scripts.git] / configure.ac
blob251d172b950322ef14692f5fafd1989cc2143744
1 #                                               -*- Autoconf -*-
2 # Process this file with autoconf to produce a configure script.
4 AC_PREREQ([2.67])
6 AC_INIT([libquvi-scripts], m4_esyscmd([./gen-ver.sh -c | tr -d '\n']),
7         [http://quvi.sf.net/bugs/],[],[http://quvi.sf.net/])
9 AC_CONFIG_SRCDIR([tests/lib/env.c])
10 AC_CONFIG_HEADERS([config.h])
11 AC_CONFIG_AUX_DIR([config.aux])
12 AC_CONFIG_MACRO_DIR([m4])
14 AM_INIT_AUTOMAKE([1.11.1 -Wall -Werror dist-xz no-dist-gzip tar-ustar])
15 AM_SILENT_RULES([yes])
16 #AM_PROG_AR
18 LT_INIT([disable-static])
19 LT_PREREQ([2.2.6])
21 # Checks for programs.
22 AC_PROG_CC
23 AM_PROG_CC_C_O
24 AC_PROG_LN_S
26 AC_PATH_PROG([A2X], [a2x], [no])
27 AM_CONDITIONAL([HAVE_A2X], [test x"$A2X" != "xno"])
28 AC_SUBST([A2X])
30 # --with-tests
31 pkg_libquvi=libquvi-0.9
32 AC_ARG_WITH([tests],
33   [AS_HELP_STRING([--with-tests],
34     [Enable tests for scripts @<:@default=no@:>@])],
35   [PKG_CHECK_MODULES([libquvi], ["$pkg_libquvi" >= 0.9],
36     [libquvi_modver=`$PKG_CONFIG --modversion $pkg_libquvi 2>/dev/null`
37       PKG_CHECK_MODULES([glib], [glib-2.0 >= 2.24],
38       [PKG_CHECK_MODULES([libcurl], [libcurl >= 7.21], [with_tests=yes])])
39     ])
40   ], [with_tests=no])
41 AM_CONDITIONAL([WITH_TESTS], [test x"$with_tests" = "xyes"])
43 # --with-nsfw
44 AC_ARG_WITH([nsfw],
45   [AS_HELP_STRING([--with-nsfw],
46     [Install scripts marked as "NSFW" @<:@default=no@:>@])],
47   [], [with_nsfw=no])
48 AM_CONDITIONAL([WITH_NSFW], [test x"$with_nsfw" != "xno"])
50 # --with-fixme
51 AC_ARG_WITH([fixme],
52   [AS_HELP_STRING([--with-fixme],
53     [Install scripts marked as "FIXME" @<:@default=no@:>@])],
54   [], [with_fixme=no])
55 AM_CONDITIONAL([WITH_FIXME], [test x"$with_fixme" != "xno"])
57 # --with-geoblocked
58 AC_ARG_WITH([geoblocked],
59   [AS_HELP_STRING([--with-geoblocked],
60     [Install scripts marked as "geoblocked" @<:@default=yes@:>@])],
61   [], [with_geoblocked=yes])
62 AM_CONDITIONAL([WITH_GEOBLOCKED], [test x"$with_geoblocked" = "xyes"])
64 # --with-manual
65 AC_ARG_WITH([manual],
66   [AS_HELP_STRING([--with-manual],
67     [Install manual page(s) @<:@default=yes@:>@])],
68   [], [with_manual=yes])
69 AM_CONDITIONAL([WITH_MANUAL], [test x"$with_manual" != "xno"])
71 # Version: Major/minor -pair, used to symlink
72 # from
73 #   $prefix/share/libquvi-scripts/$version/
74 # to
75 #   $prefix/share/libquvi-scripts/$major.$minor/
76 VERSION_MM=`$srcdir/gen-ver.sh -c -m`
77 AC_SUBST([VERSION_MM])
79 VN_C=`$srcdir/gen-ver.sh -c` # Use this value in the .pc file
80 AC_SUBST([VN_C])
82 AC_CONFIG_FILES([
83   Makefile
84   doc/Makefile
85   doc/man7/Makefile
86   share/Makefile
87   tests/Makefile
88   tests/lib/Makefile
89   libquvi-scripts-0.9.pc])
90 AC_OUTPUT
92 AC_MSG_NOTICE([
93   version       ${VERSION}
94   prefix        ${prefix}
95   compiler      ${CC}
96   cflags        ${CFLAGS}
97 Testsuite options
98   with
99   - tests       ${with_tests}
100     - libquvi .pc modversion ${libquvi_modver}
101 Install options
102   with
103   - geoblocked  ${with_geoblocked}
104   - fixme       ${with_fixme}
105   - nsfw        ${with_nsfw}])