~ubuntu-branches/ubuntu/quantal/lxc/quantal-201205292108

« back to all changes in this revision

Viewing changes to configure.ac

  • Committer: Bazaar Package Importer
  • Author(s): Guido Trotter, Stéphane Graber, Guido Trotter
  • Date: 2010-01-10 10:40:21 UTC
  • mfrom: (1.1.2 upstream) (3.1.2 sid)
  • Revision ID: james.westby@ubuntu.com-20100110104021-z8rj5zw5mlvra08l
Tags: 0.6.4-1
[ Stéphane Graber ]
* Upgrade standards-version to 3.8.3
* Drop the copy of etc/* from rules as "etc" is no longer in the tarball

[ Guido Trotter ]
* New Upstream Version
* Update libcap2-dev dependency to libcap-dev
* Install upstream-built man pages via debian/lxc.manpages
* Drop unneeded docbook-utils build dependency

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#                                               -*- Autoconf -*-
2
2
# Process this file with autoconf to produce a configure script.
3
3
 
4
 
AC_INIT([lxc], [0.6.3])
 
4
AC_INIT([lxc], [0.6.4])
5
5
 
6
6
AC_CONFIG_SRCDIR([configure.ac])
7
7
AC_CONFIG_AUX_DIR([config])
10
10
AC_CANONICAL_HOST
11
11
AM_PROG_CC_C_O
12
12
AC_GNU_SOURCE
13
 
AC_PROG_LIBTOOL
14
13
AC_CHECK_PROG(SETCAP, setcap, yes, no, $PATH$PATH_SEPARATOR/sbin)
15
 
AC_CHECK_PROG(DOCBOOK, docbook2man, yes, no)
16
 
AM_CONDITIONAL(ENABLE_DOCBOOK, test x$DOCBOOK = xyes)
 
14
 
 
15
AC_ARG_ENABLE([doc],
 
16
        [AC_HELP_STRING([--enable-doc], [make mans (require docbook2man installed) [default=auto]])],
 
17
        [], [enable_doc=auto])
 
18
 
 
19
if test "x$enable_doc" = "xyes" -o "x$enable_doc" = "xauto"; then
 
20
        AC_CHECK_PROG(have_docbook, [docbook2man], [yes], [no])
 
21
 
 
22
        test "x$have_docbook" = "xno" -a "x$enable_doc" = "xyes" && \
 
23
                AC_MSG_ERROR([docbook2man required by man request, but not found])
 
24
fi
 
25
 
 
26
AM_CONDITIONAL([ENABLE_DOCBOOK], [test "x$have_docbook" = "xyes"])
 
27
 
 
28
AC_ARG_ENABLE([examples],
 
29
        [AC_HELP_STRING([--disable-examples], [do not install configuration examples])],
 
30
        [], [enable_examples=yes])
 
31
 
 
32
AM_CONDITIONAL([ENABLE_EXAMPLES], [test "x$enable_examples" = "xyes"])
 
33
 
17
34
AS_AC_EXPAND(PREFIX, $prefix)
18
35
AS_AC_EXPAND(LIBDIR, $libdir)
19
36
AS_AC_EXPAND(BINDIR, $bindir)
22
39
AS_AC_EXPAND(SYSCONFDIR, $sysconfdir)
23
40
AS_AC_EXPAND(DATADIR, $datadir)
24
41
AS_AC_EXPAND(LOCALSTATEDIR, $localstatedir)
25
 
AS_AC_EXPAND(LXCPATH, "${localstatedir}/lib/lxc")
 
42
AS_AC_EXPAND(DOCDIR, $docdir)
 
43
 
 
44
AC_ARG_WITH([config-path],
 
45
        [AC_HELP_STRING(
 
46
                [--with-config-path=dir],
 
47
                [lxc configuration repository]
 
48
        )], [], [with_config_path="${localstatedir}/lib/lxc"])
 
49
 
26
50
AS_AC_EXPAND(LXC_GENERATE_DATE, "$(date)")
 
51
AS_AC_EXPAND(LXCPATH, "${with_config_path}")
 
52
AH_TEMPLATE([LXCPATH], [lxc configuration repository])
 
53
AH_TEMPLATE([LXCLIBEXECDIR], [lxc executable library path])
 
54
AC_DEFINE_UNQUOTED(LXCPATH, "$LXCPATH")
 
55
AC_DEFINE_UNQUOTED(LXCLIBEXECDIR, "$LIBEXECDIR")
27
56
 
28
 
AC_CHECK_HEADERS([linux/netlink.h linux/genetlink.h], [], AC_MSG_ERROR([netlink headers not found. Please install the linux kernel headers.]),
29
 
[#include <linux/types.h>
30
 
#include <bits/sockaddr.h>
31
 
#include <linux/socket.h>])
 
57
AC_CHECK_HEADERS([linux/netlink.h linux/genetlink.h],
 
58
                 [],
 
59
                 AC_MSG_ERROR([netlink headers not found. Please install the linux kernel headers.]),
 
60
                 [#include <sys/socket.h>
 
61
                 ])
32
62
 
33
63
AC_CHECK_HEADERS([sys/capability.h], [], AC_MSG_ERROR([please install libcap-devel.]),
34
64
[#include <sys/types.h>
45
75
  CFLAGS="$CFLAGS -Wall"
46
76
fi
47
77
 
48
 
LXC_MAJOR_VERSION=$(echo $PACKAGE_VERSION | cut -d. -f1)
49
 
LXC_MINOR_VERSION=$(echo $PACKAGE_VERSION | cut -d. -f2)
50
 
LXC_MICRO_VERSION=$(echo $PACKAGE_VERSION | cut -d. -f3)
51
 
 
52
 
AC_ARG_WITH([kernel-release],
53
 
 [AC_HELP_STRING([--with-kernel-release=RELEASE],
54
 
                [specify the "uname -r"-value to build for])],
55
 
        [KERNEL_RELEASE="${withval}"],
56
 
        [KERNEL_RELEASE=`uname -r`])
57
 
 
58
 
AC_ARG_ENABLE(test, [  --enable-test    compile test program [default=no]],, enable_test=no)
59
 
AM_CONDITIONAL(ENABLE_TEST, test x$enable_test = xyes)
60
 
 
61
 
AC_SUBST(LXC_MAJOR_VERSION)
62
 
AC_SUBST(LXC_MINOR_VERSION)
63
 
AC_SUBST(LXC_MICRO_VERSION)
64
 
 
65
78
AC_CONFIG_FILES([
66
79
        Makefile
67
80
        lxc.pc
87
100
        doc/common_options.sgml
88
101
        doc/see_also.sgml
89
102
 
 
103
        doc/examples/Makefile
 
104
        doc/examples/lxc-macvlan.conf
 
105
        doc/examples/lxc-no-netns.conf
 
106
        doc/examples/lxc-empty-netns.conf
 
107
        doc/examples/lxc-phys.conf
 
108
        doc/examples/lxc-veth.conf
 
109
        doc/examples/lxc-complex-config
 
110
 
90
111
        scripts/Makefile
91
112
        scripts/lxc-debian
92
113
        scripts/lxc-fedora
100
121
        src/lxc/lxc-checkconfig
101
122
        src/lxc/lxc-setcap
102
123
        src/lxc/lxc-version
103
 
 
104
 
        etc/Makefile
105
 
        etc/lxc-macvlan.conf
106
 
        etc/lxc-no-netns.conf
107
 
        etc/lxc-empty-netns.conf
108
 
        etc/lxc-phys.conf
109
 
        etc/lxc-veth.conf
110
 
        etc/lxc-complex-config
111
 
 
112
 
        test/Makefile
 
124
        src/lxc/lxc-create
 
125
        src/lxc/lxc-destroy
 
126
 
113
127
])
114
128
AC_CONFIG_COMMANDS([default],[[]],[[]])
115
129
AC_OUTPUT
116
130
 
117
 
if test "x$DOCBOOK" = "xno"; then
118
 
   AC_MSG_NOTICE([
119
 
 
120
 
Warning:
121
 
--------
122
 
The docbook tool is not installed, the man pages won't be generated.
123
 
If you want the man pages, install docbook and rerun 'configure'.
124
 
 
125
 
])
126
 
 
127
 
fi
128
 
 
129
131
if test "x$SETCAP" = "xno"; then
130
132
   AC_MSG_NOTICE([
131
133