~ubuntu-branches/ubuntu/trusty/libpam-mount/trusty-proposed

« back to all changes in this revision

Viewing changes to .pc/allow-cryptsetup-disable/configure.ac

  • Committer: Bazaar Package Importer
  • Author(s): Bastian Kleineidam
  • Date: 2010-12-25 11:24:23 UTC
  • mfrom: (1.4.9 upstream)
  • Revision ID: james.westby@ubuntu.com-20101225112423-b3nsrl0dhrto15qf
Tags: 2.8-1
* New upstream release.
* Add libtool to build depends.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#
 
2
#       Copyright (C) 2002 W. Michael Petullo <mike@flyn.org>
 
3
#       Copyright © Jan Engelhardt, 2005 - 2010
 
4
#
 
5
#       This file is part of pam_mount; you can redistribute it and/or modify
 
6
#       it under the terms of the GNU General Public License as published by
 
7
#       the Free Software Foundation; either version 2 of the License, or
 
8
#       (at your option) any later version.
 
9
#
 
10
AC_INIT([pam_mount], [2.8])
 
11
PACKAGE_RELDATE="2010-12-22"
 
12
AC_PREREQ([2.59])
 
13
AC_CONFIG_HEADERS([config.h])
 
14
AC_CONFIG_MACRO_DIR([m4])
 
15
AC_PROG_INSTALL
 
16
AM_INIT_AUTOMAKE([-Wall no-dist foreign subdir-objects])
 
17
AC_PROG_CC
 
18
AM_PROG_CC_C_O
 
19
AC_DISABLE_STATIC
 
20
AM_PROG_LIBTOOL
 
21
AC_PROG_LN_S
 
22
 
 
23
AC_ARG_WITH([slibdir], AS_HELP_STRING([--with-slibdir=PATH],
 
24
        [Path to the super lib directory [[/lib]]]),
 
25
        [slibdir="$withval"], [slibdir="/lib"])
 
26
AC_SUBST(slibdir)
 
27
AC_ARG_WITH([ssbindir], AS_HELP_STRING([--with-ssbindir=PATH],
 
28
        [Path to the super sbin directory [[/sbin]]]),
 
29
        [ssbindir="$withval"], [ssbindir="/sbin"])
 
30
AC_SUBST(ssbindir)
 
31
AC_ARG_WITH([dtd], AS_HELP_STRING([--with-dtd],
 
32
        [Install XML DTD file]),
 
33
        [with_dtd=true], [with_dtd=false])
 
34
AC_ARG_WITH([selinux], AS_HELP_STRING([--with-selinux],
 
35
        [Install selinux files]),
 
36
        [with_selinux=true], [with_selinux=false])
 
37
AC_ARG_ENABLE([la], AS_HELP_STRING([--enable-la],
 
38
        [Install .la file (used for distcheck)]),
 
39
        [keep_la=true], [keep_la=false])
 
40
AM_CONDITIONAL([KEEP_LA], [test "x$keep_la" = "xtrue"])
 
41
AM_CONDITIONAL([SELINUX], [test "x$with_selinux" = "xtrue"])
 
42
AM_CONDITIONAL([WITH_DTD], [test "x$with_dtd" = "xtrue"])
 
43
 
 
44
CHECK_GCC_FVISIBILITY
 
45
 
 
46
regular_CFLAGS="-D_FILE_OFFSET_BITS=64 \
 
47
        -D_REENTRANT -Wall -Waggregate-return -Wmissing-declarations \
 
48
        -Wmissing-prototypes -Wredundant-decls -Wshadow -Wstrict-prototypes \
 
49
        -Wformat=2 -pipe"
 
50
AC_SUBST([regular_CFLAGS])
 
51
 
 
52
AC_CHECK_HEADERS([linux/fs.h linux/major.h dev/cgdvar.h dev/vndvar.h])
 
53
AC_CHECK_HEADERS([sys/mdioctl.h sys/mount.h sys/statvfs.h])
 
54
AC_CHECK_MEMBERS([struct loop_info64.lo_file_name], [], [],
 
55
        [#include <linux/loop.h>])
 
56
AC_CHECK_FUNCS([getmntent getmntinfo getgrouplist getgroups setgroups])
 
57
AM_CONDITIONAL([HAVE_CGD], [test "x$ac_cv_header_dev_cgdvar_h" = "xyes"])
 
58
AM_CONDITIONAL([HAVE_MDIO], [test "x$ac_cv_header_sys_mdioctl_h" = "xyes"])
 
59
AM_CONDITIONAL([HAVE_VND], [test "x$ac_cv_header_dev_vndvar_h" = "xyes"])
 
60
 
 
61
PKG_CHECK_MODULES([libHX], [libHX >= 3.6])
 
62
PKG_CHECK_MODULES([libxml], [libxml-2.0 >= 2.6])
 
63
 
 
64
with_crypto="yes";
 
65
AC_ARG_WITH(
 
66
        [crypto],
 
67
        AS_HELP_STRING([--without-crypto], [Disable use of OpenSSL cryptography]),
 
68
        [],
 
69
        [with_crypto="no"]
 
70
)
 
71
 
 
72
with_cryptsetup="yes";
 
73
AC_ARG_WITH([cryptsetup],
 
74
        AS_HELP_STRING([--without-cryptsetup], [Disable use of libcryptsetup]),
 
75
        [],
 
76
        [with_cryptsetup="no"]
 
77
)
 
78
 
 
79
if test "x$with_crypto" = "xyes"; then
 
80
        PKG_CHECK_MODULES([libcrypto], [libcrypto >= 0.9.8],
 
81
                [AC_DEFINE_UNQUOTED([HAVE_LIBCRYPTO], [1],
 
82
                        [OpenSSL libcrypto available])])
 
83
fi;
 
84
AM_CONDITIONAL([HAVE_LIBCRYPTO], [test "x$with_crypto" = xyes])
 
85
 
 
86
if test "x$with_cryptsetup" = "xyes"; then
 
87
        PKG_CHECK_MODULES([libcryptsetup], [libcryptsetup >= 1.1.2],
 
88
                [AC_DEFINE_UNQUOTED([HAVE_LIBCRYPTSETUP], [1],
 
89
                        [libcryptsetup available])])
 
90
fi;
 
91
AM_CONDITIONAL([HAVE_LIBCRYPTSETUP], [test "x$with_cryptsetup" = xyes])
 
92
 
 
93
AC_CHECK_HEADERS([security/pam_modules.h], [have_pamheader="yes"])
 
94
# Mac OS X 10.3 puts PAM headers in /usr/include/pam.
 
95
AC_CHECK_HEADERS([pam/pam_modules.h], [have_pamheader="yes"])
 
96
if test x"$have_pamheader" != x"yes"; then
 
97
        AC_MSG_ERROR([You are missing PAM headers])
 
98
fi
 
99
 
 
100
case "$host" in
 
101
    (*-*-linux*|*-*-openbsd*)
 
102
        PAM_MODDIR='${slibdir}/security'
 
103
        ;;
 
104
    (*-*-solaris*|*-*-netbsd*)
 
105
        PAM_MODDIR='${libdir}/security';
 
106
        ;;
 
107
    (*-*-darwin*)
 
108
        PAM_MODDIR='${libdir}/pam';
 
109
        ;;
 
110
    (*)
 
111
        PAM_MODDIR='${libdir}';
 
112
        ;;
 
113
esac
 
114
AC_SUBST([PAM_MODDIR])
 
115
 
 
116
AC_SUBST([PACKAGE_RELDATE])
 
117
AC_CONFIG_FILES([Makefile config/Makefile doc/Makefile src/Makefile])
 
118
AC_OUTPUT