]> git.ipfire.org Git - thirdparty/systemd.git/blame - configure.ac
man: mention that units are 1024-based
[thirdparty/systemd.git] / configure.ac
CommitLineData
fb0951b0 1#
47be870b
LP
2# This file is part of systemd.
3#
3e214785
KS
4# Copyright 2010-2012 Lennart Poettering
5# Copyright 2010-2012 Kay Sievers
47be870b
LP
6#
7# systemd is free software; you can redistribute it and/or modify it
5430f7f2
LP
8# under the terms of the GNU Lesser General Public License as published by
9# the Free Software Foundation; either version 2.1 of the License, or
47be870b
LP
10# (at your option) any later version.
11#
12# systemd is distributed in the hope that it will be useful, but
13# WITHOUT ANY WARRANTY; without even the implied warranty of
14# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5430f7f2 15# Lesser General Public License for more details.
47be870b 16#
5430f7f2 17# You should have received a copy of the GNU Lesser General Public License
47be870b
LP
18# along with systemd; If not, see <http://www.gnu.org/licenses/>.
19
4e949c11
JJ
20AC_PREREQ([2.64])
21
22AC_INIT([systemd],
606c24e3 23 [204],
4e949c11
JJ
24 [http://bugs.freedesktop.org/enter_bug.cgi?product=systemd],
25 [systemd],
26 [http://www.freedesktop.org/wiki/Software/systemd])
47be870b 27
78a825f2 28AC_CONFIG_SRCDIR([src/core/main.c])
47be870b
LP
29AC_CONFIG_MACRO_DIR([m4])
30AC_CONFIG_HEADERS([config.h])
a80db8bd
JJ
31AC_CONFIG_AUX_DIR([build-aux])
32
4db6d587 33AC_USE_SYSTEM_EXTENSIONS
907dd195 34AC_SYS_LARGEFILE
eb7bbee6 35AC_PREFIX_DEFAULT([/usr])
bbd9b8c2 36AM_INIT_AUTOMAKE([foreign 1.11 -Wall -Wno-portability silent-rules tar-pax no-dist-gzip dist-xz subdir-objects check-news])
3e214785 37AM_SILENT_RULES([yes])
47be870b 38AC_CANONICAL_HOST
22be093f 39AC_DEFINE_UNQUOTED([CANONICAL_HOST], "$host", [Canonical host string.])
d59d0a2b 40AS_IF([test "x$host_cpu" = "xmips" || test "x$host_cpu" = "xmipsel" ||
41 test "x$host_cpu" = "xmips64" || test "x$host_cpu" = "xmips64el"],
42 [AC_DEFINE(ARCH_MIPS, [], [Whether on mips arch])])
47be870b 43
3e214785 44LT_PREREQ(2.2)
8666abb4 45LT_INIT([disable-static])
47be870b 46
1c7dde3e
BN
47# i18n stuff for the PolicyKit policy files
48IT_PROG_INTLTOOL([0.40.0])
49
50GETTEXT_PACKAGE=systemd
51AC_SUBST(GETTEXT_PACKAGE)
52
e9da3678
LP
53AC_PROG_MKDIR_P
54AC_PROG_LN_S
55AC_PROG_SED
3ce4fad8 56AC_PROG_GREP
f975e971 57AC_PROG_AWK
e9da3678 58
47be870b
LP
59AC_PROG_CC
60AC_PROG_CC_C99
61AM_PROG_CC_C_O
62AC_PROG_GCC_TRADITIONAL
47be870b 63
3e214785 64AC_PATH_PROG([M4], [m4])
fe1fed02 65AC_PATH_PROG([XSLTPROC], [xsltproc])
92ec4495 66
86b2e20a
LP
67AC_PATH_PROG([QUOTAON], [quotaon], [/usr/sbin/quotaon])
68AC_PATH_PROG([QUOTACHECK], [quotacheck], [/usr/sbin/quotacheck])
b51fc639 69
86b2e20a
LP
70AC_PATH_PROG([SETCAP], [setcap], [/usr/sbin/setcap])
71
c1c02e07 72AC_PATH_PROG([KILL], [kill], [/usr/bin/kill])
96ede260 73
80a5cbac 74# gtkdocize greps for '^GTK_DOC_CHECK', so it needs to be on its own line
b37250d6
ZJS
75m4_ifdef([GTK_DOC_CHECK], [
76GTK_DOC_CHECK([1.18],[--flavour no-tmpl])],
6581f00f
ZJS
77 [AM_CONDITIONAL([ENABLE_GTK_DOC], [false])
78 enable_gtk_doc=no])
92ec4495 79
fe1fed02
ZJS
80AS_IF([test "x$enable_gtk_doc" = "xyes" -a "x$XSLTPROC" = x], [
81 AC_MSG_ERROR([*** GTK doc requested but xsltproc not found])
82])
83
6e92b23f 84m4_ifdef([GOBJECT_INTROSPECTION_CHECK], [
0eaeca1f 85GOBJECT_INTROSPECTION_CHECK([1.31.1])
d66ee73a
ZJS
86], [
87 AM_CONDITIONAL([HAVE_INTROSPECTION], [false])
88 enable_introspection=no])
3e214785 89
ac714a78
MJ
90AC_CHECK_TOOL(OBJCOPY, objcopy)
91AC_CHECK_TOOL(STRINGS, strings)
92AC_CHECK_TOOL(GPERF, gperf)
b62cfcea
MB
93if test -z "$GPERF" ; then
94 AC_MSG_ERROR([*** gperf not found])
95fi
9a60da28 96
eb2e280f 97CC_CHECK_FLAGS_APPEND([with_cflags], [CFLAGS], [\
be1a67d9 98 -pipe \
d1ab0ca0 99 -Wall \
d1ab0ca0 100 -Wextra \
27765dfc 101 -Wno-inline \
d1ab0ca0 102 -Wundef \
780040dc 103 "-Wformat=2 -Wformat-security -Wformat-nonliteral" \
d1ab0ca0
LP
104 -Wlogical-op \
105 -Wsign-compare \
d1ab0ca0 106 -Wmissing-include-dirs \
d1ab0ca0
LP
107 -Wold-style-definition \
108 -Wpointer-arith \
109 -Winit-self \
110 -Wdeclaration-after-statement \
111 -Wfloat-equal \
112 -Wmissing-prototypes \
113 -Wstrict-prototypes \
114 -Wredundant-decls \
115 -Wmissing-declarations \
116 -Wmissing-noreturn \
117 -Wshadow \
118 -Wendif-labels \
119 -Wcast-align \
120 -Wstrict-aliasing=2 \
121 -Wwrite-strings \
be1a67d9
LP
122 -Wno-long-long \
123 -Wno-overlength-strings \
d1ab0ca0 124 -Wno-unused-parameter \
be1a67d9 125 -Wno-missing-field-initializers \
8745297f 126 -Wno-unused-result \
d200735e 127 -Werror=overflow \
be1a67d9 128 -ffast-math \
d1ab0ca0
LP
129 -fno-common \
130 -fdiagnostics-show-option \
8de1fd28 131 -fdiagnostics-color \
9b85fc6a
GSB
132 -fno-strict-aliasing \
133 -fvisibility=hidden \
134 -ffunction-sections \
5a45a936 135 -fdata-sections \
c1663b9d
LP
136 -fstack-protector \
137 --param=ssp-buffer-size=4])
5a45a936
LP
138AC_SUBST([OUR_CFLAGS], $with_cflags)
139
7cb20866 140AS_CASE([$CFLAGS], [*-O[[12345g\ ]]*], [
6a179865
ZJS
141 CC_CHECK_FLAGS_APPEND([with_cppflags], [CPPFLAGS], [\
142 -Wp,-D_FORTIFY_SOURCE=2])], [
c937e0d5 143 python_extra_cflags=-Wp,-U_FORTIFY_SOURCE
6a179865 144 AC_MSG_RESULT([skipping -D_FORTIFY_SOURCE, optimization not enabled])])
5a45a936 145AC_SUBST([OUR_CPPFLAGS], $with_cppflags)
9e7adc3a
LDM
146
147CC_CHECK_FLAGS_APPEND([with_ldflags], [LDFLAGS], [\
9b85fc6a 148 -Wl,--as-needed \
9d2d0fe1 149 -Wl,--no-undefined \
5a45a936
LP
150 -Wl,--gc-sections \
151 -Wl,-z,relro \
152 -Wl,-z,now])
153AC_SUBST([OUR_LDFLAGS], $with_ldflags)
47be870b 154
c937e0d5
ZJS
155# ------------------------------------------------------------------------------
156# we use python to build the man page index, and for systemd-python
157have_python=no
158have_python_devel=no
159
160AC_ARG_WITH([python],
161 [AS_HELP_STRING([--without-python], [Disable building the man page index and systemd-python (default: test)])])
162
163AS_IF([test "x$with_python" != "xno"], [
164 AM_PATH_PYTHON(,, [:])
165 AS_IF([test "$PYTHON" != :], [have_python=yes])
166])
167AM_CONDITIONAL([HAVE_PYTHON], [test "x$have_python" = "xyes"])
168AS_IF([test "x$PYTHON_BINARY" = "x"],
169 [AS_IF([test "x$have_python" = "xyes"],
25ee45f9 170 [PYTHON_BINARY="$(which "$PYTHON")"],
c937e0d5
ZJS
171 [PYTHON_BINARY=/usr/bin/python])])
172AC_ARG_VAR(PYTHON_BINARY, [Python binary used to launch installed scripts])
173
174AS_IF([test "x$with_python" != "xno"], [
175 AC_PATH_PROG(PYTHON_CONFIG, python${PYTHON_VERSION}-config)
176 AS_IF([test -n "$PYTHON_CONFIG"], [
177 have_python_devel=yes
25ee45f9
MB
178 PYTHON_CFLAGS="$($PYTHON_CONFIG --cflags) $python_extra_cflags"
179 PYTHON_LIBS="$($PYTHON_CONFIG --ldflags)"
c937e0d5
ZJS
180 AC_SUBST(PYTHON_CFLAGS)
181 AC_SUBST(PYTHON_LIBS)
603c0b7b 182 AC_PATH_PROGS(SPHINX_BUILD, sphinx-build-${PYTHON_VERSION} sphinx-build)
c937e0d5
ZJS
183 ])
184])
185AM_CONDITIONAL([HAVE_PYTHON_DEVEL], [test "$have_python_devel" = "yes"])
186
187# ------------------------------------------------------------------------------
188
e1718709 189AC_SEARCH_LIBS([mq_open], [rt], [], [AC_MSG_ERROR([*** POSIX RT library not found])])
afea26ad 190AC_SEARCH_LIBS([dlsym], [dl], [], [AC_MSG_ERROR([*** Dynamic linking loader library not found])])
85f19d82
MB
191
192save_LIBS="$LIBS"
193LIBS=
47be870b
LP
194AC_SEARCH_LIBS([cap_init], [cap], [], [AC_MSG_ERROR([*** POSIX caps library not found])])
195AC_CHECK_HEADERS([sys/capability.h], [], [AC_MSG_ERROR([*** POSIX caps headers not found])])
85f19d82
MB
196CAP_LIBS="$LIBS"
197LIBS="$save_LIBS"
198AC_SUBST(CAP_LIBS)
47be870b 199
9388e99e 200AC_CHECK_FUNCS([fanotify_init fanotify_mark])
4db17f29 201AC_CHECK_FUNCS([__secure_getenv secure_getenv])
9388e99e 202AC_CHECK_DECLS([gettid, pivot_root, name_to_handle_at], [], [], [[#include <sys/types.h>
a8348796 203#include <unistd.h>
9388e99e
MO
204#include <sys/mount.h>
205#include <fcntl.h>]])
a8348796 206
b237ef2c 207# This makes sure pkg.m4 is available.
a9b5b032 208m4_pattern_forbid([^_?PKG_[A-Z_]+$],[*** pkg.m4 missing, please install pkg-config])
d1ab0ca0 209
3e214785 210PKG_CHECK_MODULES(DBUS, [dbus-1 >= 1.3.2])
e3043162
TG
211
212# ------------------------------------------------------------------------------
213have_kmod=no
214AC_ARG_ENABLE(kmod, AS_HELP_STRING([--disable-kmod], [disable loadable modules support]))
215if test "x$enable_kmod" != "xno"; then
216 PKG_CHECK_MODULES(KMOD, [ libkmod >= 5 ],
217 [AC_DEFINE(HAVE_KMOD, 1, [Define if kmod is available]) have_kmod=yes], have_kmod=no)
218 if test "x$have_kmod" = xno -a "x$enable_kmod" = xyes; then
219 AC_MSG_ERROR([*** kmod support requested but libraries not found])
220 fi
221fi
222AM_CONDITIONAL(HAVE_KMOD, [test "$have_kmod" = "yes"])
f553b3b1
AO
223
224# ------------------------------------------------------------------------------
225have_blkid=no
226AC_ARG_ENABLE(blkid, AS_HELP_STRING([--disable-blkid], [disable blkid support]))
227if test "x$enable_blkid" != "xno"; then
228 PKG_CHECK_MODULES(BLKID, [ blkid >= 2.20 ],
229 [AC_DEFINE(HAVE_BLKID, 1, [Define if blkid is available]) have_blkid=yes], have_blkid=no)
230 if test "x$have_blkid" = xno -a "x$enable_blkid" = xyes; then
231 AC_MSG_ERROR([*** blkid support requested but libraries not found])
232 fi
233fi
234AM_CONDITIONAL(HAVE_BLKID, [test "$have_blkid" = "yes"])
728beb28 235
3e214785 236# ------------------------------------------------------------------------------
81611586
RS
237have_ima=yes
238AC_ARG_ENABLE([ima], AS_HELP_STRING([--disable-ima],[Disable optional IMA support]),
239 [case "${enableval}" in
240 yes) have_ima=yes ;;
241 no) have_ima=no ;;
242 *) AC_MSG_ERROR(bad value ${enableval} for --disable-ima) ;;
243 esac],
244 [have_ima=yes])
245
246if test "x${have_ima}" != xno ; then
247 AC_DEFINE(HAVE_IMA, 1, [Define if IMA is available])
248fi
249
77e68fa2
LP
250# ------------------------------------------------------------------------------
251have_chkconfig=yes
252AC_ARG_ENABLE([chkconfig], AS_HELP_STRING([--disable-chkconfig],[Disable optional chkconfig support]),
253 [case "${enableval}" in
254 yes) have_chkconfig=yes ;;
255 no) have_chkconfig=no ;;
256 *) AC_MSG_ERROR(bad value ${enableval} for --disable-chkconfig) ;;
257 esac],
258 [AC_PATH_PROG(CHKCONFIG, chkconfig)
259 if test -z "$CHKCONFIG"; then
260 have_chkconfig=no
261 else
262 have_chkconfig=yes
263 fi])
264
265if test "x${have_chkconfig}" != xno ; then
266 AC_DEFINE(HAVE_CHKCONFIG, 1, [Define if CHKCONFIG is available])
267fi
268
3e214785 269# ------------------------------------------------------------------------------
591622d7
LP
270have_selinux=no
271AC_ARG_ENABLE(selinux, AS_HELP_STRING([--disable-selinux], [Disable optional SELINUX support]))
272if test "x$enable_selinux" != "xno"; then
3f8cc098 273 PKG_CHECK_MODULES([SELINUX], [libselinux >= 2.1.9],
591622d7 274 [AC_DEFINE(HAVE_SELINUX, 1, [Define if SELinux is available]) have_selinux=yes], have_selinux=no)
591622d7
LP
275 if test "x$have_selinux" = xno -a "x$enable_selinux" = xyes; then
276 AC_MSG_ERROR([*** SELinux support requested but libraries not found])
277 fi
56cf987f 278fi
591622d7 279AM_CONDITIONAL(HAVE_SELINUX, [test "$have_selinux" = "yes"])
45df1f2c
CR
280
281AC_ARG_WITH(debug-shell,
282 AS_HELP_STRING([--with-debug-shell=PATH],
283 [Path to debug shell binary]),
284 [SUSHELL="$withval"],[
285 AS_IF([test "x${have_selinux}" != "xno"], [SUSHELL="/sbin/sushell"] , [SUSHELL="/bin/sh"])])
286
5ec6b15b 287AC_SUBST(SUSHELL)
56cf987f 288
45df1f2c
CR
289AC_ARG_WITH([debug-tty],
290 AS_HELP_STRING([--with-debug-tty=PATH],
291 [Specify the tty device for debug shell]),
292 [DEBUGTTY="$withval"],
293 [DEBUGTTY=/dev/tty9])
294
295AC_SUBST(DEBUGTTY)
296
3e214785 297# ------------------------------------------------------------------------------
807e17f0
LP
298have_xz=no
299AC_ARG_ENABLE(xz, AS_HELP_STRING([--disable-xz], [Disable optional XZ support]))
300if test "x$enable_xz" != "xno"; then
301 PKG_CHECK_MODULES(XZ, [ liblzma ],
302 [AC_DEFINE(HAVE_XZ, 1, [Define if XZ is available]) have_xz=yes], have_xz=no)
807e17f0
LP
303 if test "x$have_xz" = xno -a "x$enable_xz" = xyes; then
304 AC_MSG_ERROR([*** Xz support requested but libraries not found])
305 fi
306fi
307AM_CONDITIONAL(HAVE_XZ, [test "$have_xz" = "yes"])
308
3e214785 309# ------------------------------------------------------------------------------
0213c3f8
LP
310AC_ARG_ENABLE([tcpwrap],
311 AS_HELP_STRING([--disable-tcpwrap],[Disable optional TCP wrappers support]),
312 [case "${enableval}" in
5b6319dc
LP
313 yes) have_tcpwrap=yes ;;
314 no) have_tcpwrap=no ;;
0213c3f8
LP
315 *) AC_MSG_ERROR(bad value ${enableval} for --disable-tcpwrap) ;;
316 esac],
5b6319dc 317 [have_tcpwrap=auto])
0213c3f8 318
5b6319dc 319if test "x${have_tcpwrap}" != xno ; then
0213c3f8
LP
320 ACX_LIBWRAP
321 if test "x${LIBWRAP_LIBS}" = x ; then
5b6319dc
LP
322 if test "x$have_tcpwrap" = xyes ; then
323 AC_MSG_ERROR([*** TCP wrappers support not found.])
0213c3f8 324 fi
812cce32 325 have_tcpwrap=no
0213c3f8 326 else
5b6319dc 327 have_tcpwrap=yes
0213c3f8
LP
328 fi
329else
5b6319dc 330 LIBWRAP_LIBS=
0213c3f8 331fi
0213c3f8
LP
332AC_SUBST(LIBWRAP_LIBS)
333
3e214785 334# ------------------------------------------------------------------------------
5b6319dc
LP
335AC_ARG_ENABLE([pam],
336 AS_HELP_STRING([--disable-pam],[Disable optional PAM support]),
337 [case "${enableval}" in
338 yes) have_pam=yes ;;
339 no) have_pam=no ;;
340 *) AC_MSG_ERROR(bad value ${enableval} for --disable-pam) ;;
341 esac],
342 [have_pam=auto])
343
344if test "x${have_pam}" != xno ; then
345 AC_CHECK_HEADERS(
346 [security/pam_modules.h security/pam_modutil.h security/pam_ext.h],
347 [have_pam=yes],
348 [if test "x$have_pam" = xyes ; then
349 AC_MSG_ERROR([*** PAM headers not found.])
350 fi])
351
352 AC_CHECK_LIB(
353 [pam],
354 [pam_syslog],
355 [have_pam=yes],
356 [if test "x$have_pam" = xyes ; then
357 AC_MSG_ERROR([*** libpam not found.])
358 fi])
359
360 if test "x$have_pam" = xyes ; then
361 PAM_LIBS="-lpam -lpam_misc"
362 AC_DEFINE(HAVE_PAM, 1, [PAM available])
812cce32
LP
363 else
364 have_pam=no
5b6319dc
LP
365 fi
366else
367 PAM_LIBS=
368fi
369AC_SUBST(PAM_LIBS)
370AM_CONDITIONAL([HAVE_PAM], [test "x$have_pam" != xno])
371
3e214785 372# ------------------------------------------------------------------------------
5eda94dd
LP
373AC_ARG_ENABLE([acl],
374 AS_HELP_STRING([--disable-acl],[Disable optional ACL support]),
375 [case "${enableval}" in
376 yes) have_acl=yes ;;
377 no) have_acl=no ;;
378 *) AC_MSG_ERROR(bad value ${enableval} for --disable-acl) ;;
379 esac],
380 [have_acl=auto])
381
382if test "x${have_acl}" != xno ; then
383 AC_CHECK_HEADERS(
384 [sys/acl.h acl/libacl.h],
385 [have_acl=yes],
386 [if test "x$have_acl" = xyes ; then
387 AC_MSG_ERROR([*** ACL headers not found.])
388 fi])
389
390 AC_CHECK_LIB(
391 [acl],
392 [acl_get_file],
393 [have_acl=yes],
394 [if test "x$have_acl" = xyes ; then
395 AC_MSG_ERROR([*** libacl not found.])
396 fi])
397
398 if test "x$have_acl" = xyes ; then
399 ACL_LIBS="-lacl"
400 AC_DEFINE(HAVE_ACL, 1, [ACL available])
401 else
402 have_acl=no
403 fi
404else
405 ACL_LIBS=
406fi
407AC_SUBST(ACL_LIBS)
408AM_CONDITIONAL([HAVE_ACL], [test "x$have_acl" != xno])
409
fb0951b0
LP
410# ------------------------------------------------------------------------------
411AC_ARG_ENABLE([xattr],
412 AS_HELP_STRING([--disable-xattr],[Disable optional XATTR support]),
413 [case "${enableval}" in
414 yes) have_xattr=yes ;;
415 no) have_xattr=no ;;
416 *) AC_MSG_ERROR(bad value ${enableval} for --disable-xattr) ;;
417 esac],
418 [have_xattr=auto])
419
420if test "x${have_xattr}" != xno ; then
421 AC_CHECK_HEADERS(
422 [attr/xattr.h],
423 [have_xattr=yes],
424 [if test "x$have_xattr" = xyes ; then
425 AC_MSG_ERROR([*** XATTR headers not found.])
426 fi])
427
428 AC_CHECK_LIB(
429 [attr],
430 [fsetxattr],
431 [have_xattr=yes],
432 [if test "x$have_xattr" = xyes ; then
433 AC_MSG_ERROR([*** libattr not found.])
434 fi])
435
436 if test "x$have_xattr" = xyes ; then
437 XATTR_LIBS="-lattr"
438 AC_DEFINE(HAVE_XATTR, 1, [XATTR available])
439 else
440 have_xattr=no
441 fi
442else
443 XATTR_LIBS=
444fi
445AC_SUBST(XATTR_LIBS)
446AM_CONDITIONAL([HAVE_XATTR], [test "x$have_xattr" != xno])
447
2b3e18de
KL
448# ------------------------------------------------------------------------------
449AC_ARG_ENABLE([smack], AS_HELP_STRING([--disable-smack],[Disable optional SMACK support]),
450 [case "${enableval}" in
451 yes) have_smack=yes ;;
452 no) have_smack=no ;;
453 *) AC_MSG_ERROR(bad value ${enableval} for --disable-smack) ;;
454 esac],
455 [have_smack=auto])
456
457if test "x${have_xattr}" = xno; then
458 if test "x${have_smack}" = xyes; then
459 AC_MSG_ERROR(SMACK requires xattr support)
460 else
461 have_smack=no
462 fi
463else
464 if test "x${have_smack}" = xauto; then
465 have_smack=yes
466 fi
467fi
468
469if test "x${have_smack}" = xyes ; then
470 AC_DEFINE(HAVE_SMACK, 1, [Define if SMACK is available])
471fi
472
7560fffc 473# ------------------------------------------------------------------------------
feb12d3e 474AC_ARG_ENABLE([gcrypt],
7560fffc
LP
475 AS_HELP_STRING([--disable-gcrypt],[Disable optional GCRYPT support]),
476 [case "${enableval}" in
477 yes) have_gcrypt=yes ;;
478 no) have_gcrypt=no ;;
479 *) AC_MSG_ERROR(bad value ${enableval} for --disable-gcrypt) ;;
480 esac],
481 [have_gcrypt=auto])
482
483if test "x${have_gcrypt}" != xno ; then
484 AM_PATH_LIBGCRYPT(
485 [1.4.5],
486 [have_gcrypt=yes],
487 [if test "x$have_gcrypt" = xyes ; then
488 AC_MSG_ERROR([*** GCRYPT headers not found.])
489 fi])
490
491 if test "x$have_gcrypt" = xyes ; then
492 GCRYPT_LIBS="$LIBGCRYPT_LIBS"
493 GCRYPT_CFLAGS="$LIBGCRYPT_CFLAGS"
494 AC_DEFINE(HAVE_GCRYPT, 1, [GCRYPT available])
495 else
496 have_gcrypt=no
497 fi
498else
499 GCRYPT_LIBS=
500 GCRYPT_CFLAGS=
501fi
502AC_SUBST(GCRYPT_LIBS)
503AC_SUBST(GCRYPT_CFLAGS)
504AM_CONDITIONAL([HAVE_GCRYPT], [test "x$have_gcrypt" != xno])
505
3e214785 506# ------------------------------------------------------------------------------
4927fcae
LP
507AC_ARG_ENABLE([audit],
508 AS_HELP_STRING([--disable-audit],[Disable optional AUDIT support]),
509 [case "${enableval}" in
510 yes) have_audit=yes ;;
511 no) have_audit=no ;;
512 *) AC_MSG_ERROR(bad value ${enableval} for --disable-audit) ;;
513 esac],
514 [have_audit=auto])
515
516if test "x${have_audit}" != xno ; then
517 AC_CHECK_HEADERS(
518 [libaudit.h],
519 [have_audit=yes],
520 [if test "x$have_audit" = xyes ; then
521 AC_MSG_ERROR([*** AUDIT headers not found.])
522 fi])
523
524 AC_CHECK_LIB(
525 [audit],
526 [audit_open],
527 [have_audit=yes],
528 [if test "x$have_audit" = xyes ; then
529 AC_MSG_ERROR([*** libaudit not found.])
530 fi])
531
532 if test "x$have_audit" = xyes ; then
533 AUDIT_LIBS="-laudit"
534 AC_DEFINE(HAVE_AUDIT, 1, [AUDIT available])
535 else
536 have_audit=no
537 fi
538else
539 AUDIT_LIBS=
540fi
541AC_SUBST(AUDIT_LIBS)
542
3e214785 543# ------------------------------------------------------------------------------
7f4e0805
LP
544have_libcryptsetup=no
545AC_ARG_ENABLE(libcryptsetup, AS_HELP_STRING([--disable-libcryptsetup], [disable libcryptsetup tools]))
546if test "x$enable_libcryptsetup" != "xno"; then
880a599e 547 PKG_CHECK_MODULES(LIBCRYPTSETUP, [ libcryptsetup >= 1.4.2 ],
7f4e0805 548 [AC_DEFINE(HAVE_LIBCRYPTSETUP, 1, [Define if libcryptsetup is available]) have_libcryptsetup=yes], have_libcryptsetup=no)
7f4e0805 549 if test "x$have_libcryptsetup" = xno -a "x$enable_libcryptsetup" = xyes; then
591622d7 550 AC_MSG_ERROR([*** libcryptsetup support requested but libraries not found])
7f4e0805
LP
551 fi
552fi
553AM_CONDITIONAL(HAVE_LIBCRYPTSETUP, [test "$have_libcryptsetup" = "yes"])
554
f6a971bc
LP
555# ------------------------------------------------------------------------------
556have_qrencode=no
557AC_ARG_ENABLE(qrencode, AS_HELP_STRING([--disable-qrencode], [disable qrencode support]))
558if test "x$enable_qrencode" != "xno"; then
559 PKG_CHECK_MODULES(QRENCODE, [ libqrencode ],
560 [AC_DEFINE(HAVE_QRENCODE, 1, [Define if qrencode is available]) have_qrencode=yes], have_qrencode=no)
561 if test "x$have_qrencode" = xno -a "x$enable_qrencode" = xyes; then
562 AC_MSG_ERROR([*** qrencode support requested but libraries not found])
563 fi
564fi
565AM_CONDITIONAL(HAVE_QRENCODE, [test "$have_qrencode" = "yes"])
566
7b17a7d7
LP
567# ------------------------------------------------------------------------------
568have_microhttpd=no
569AC_ARG_ENABLE(microhttpd, AS_HELP_STRING([--disable-microhttpd], [disable microhttpd support]))
570if test "x$enable_microhttpd" != "xno"; then
59bb9d9a 571 PKG_CHECK_MODULES(MICROHTTPD, [libmicrohttpd >= 0.9.5],
7b17a7d7
LP
572 [AC_DEFINE(HAVE_MICROHTTPD, 1, [Define if microhttpd is available]) have_microhttpd=yes], have_microhttpd=no)
573 if test "x$have_microhttpd" = xno -a "x$enable_microhttpd" = xyes; then
574 AC_MSG_ERROR([*** microhttpd support requested but libraries not found])
575 fi
576fi
577AM_CONDITIONAL(HAVE_MICROHTTPD, [test "$have_microhttpd" = "yes"])
578
3e214785 579# ------------------------------------------------------------------------------
27669061
MV
580have_binfmt=no
581AC_ARG_ENABLE(binfmt, AS_HELP_STRING([--disable-binfmt], [disable binfmt tool]))
582if test "x$enable_binfmt" != "xno"; then
be31376e 583 have_binfmt=yes
27669061
MV
584fi
585AM_CONDITIONAL(ENABLE_BINFMT, [test "$have_binfmt" = "yes"])
586
3e214785 587# ------------------------------------------------------------------------------
e5e83e83
LP
588have_vconsole=no
589AC_ARG_ENABLE(vconsole, AS_HELP_STRING([--disable-vconsole], [disable vconsole tool]))
590if test "x$enable_vconsole" != "xno"; then
be31376e 591 have_vconsole=yes
e5e83e83
LP
592fi
593AM_CONDITIONAL(ENABLE_VCONSOLE, [test "$have_vconsole" = "yes"])
594
3e214785 595# ------------------------------------------------------------------------------
e5e83e83
LP
596have_readahead=no
597AC_ARG_ENABLE(readahead, AS_HELP_STRING([--disable-readahead], [disable readahead tools]))
598if test "x$enable_readahead" != "xno"; then
be31376e 599 have_readahead=yes
e5e83e83
LP
600fi
601AM_CONDITIONAL(ENABLE_READAHEAD, [test "$have_readahead" = "yes"])
602
83fdc450
AK
603# ------------------------------------------------------------------------------
604have_bootchart=no
605AC_ARG_ENABLE(bootchart, AS_HELP_STRING([--disable-bootchart], [disable bootchart tool]))
606if test "x$enable_bootchart" != "xno"; then
607 have_bootchart=yes
608fi
609AM_CONDITIONAL(ENABLE_BOOTCHART, [test "$have_bootchart" = "yes"])
610
3e214785 611# ------------------------------------------------------------------------------
4de85612
LP
612have_quotacheck=no
613AC_ARG_ENABLE(quotacheck, AS_HELP_STRING([--disable-quotacheck], [disable quotacheck tools]))
614if test "x$enable_quotacheck" != "xno"; then
be31376e 615 have_quotacheck=yes
4de85612
LP
616fi
617AM_CONDITIONAL(ENABLE_QUOTACHECK, [test "$have_quotacheck" = "yes"])
618
6351163b
UTL
619# ------------------------------------------------------------------------------
620have_tmpfiles=no
621AC_ARG_ENABLE(tmpfiles, AS_HELP_STRING([--disable-tmpfiles], [disable tmpfiles support]))
622if test "x$enable_tmpfiles" != "xno"; then
623 have_tmpfiles=yes
624fi
625AM_CONDITIONAL(ENABLE_TMPFILES, [test "$have_tmpfiles" = "yes"])
626
3e214785 627# ------------------------------------------------------------------------------
4de85612
LP
628have_randomseed=no
629AC_ARG_ENABLE(randomseed, AS_HELP_STRING([--disable-randomseed], [disable randomseed tools]))
630if test "x$enable_randomseed" != "xno"; then
be31376e 631 have_randomseed=yes
4de85612
LP
632fi
633AM_CONDITIONAL(ENABLE_RANDOMSEED, [test "$have_randomseed" = "yes"])
634
3e214785 635# ------------------------------------------------------------------------------
2a018e83
KS
636have_logind=no
637AC_ARG_ENABLE(logind, AS_HELP_STRING([--disable-logind], [disable login daemon]))
638if test "x$enable_logind" != "xno"; then
be31376e 639 have_logind=yes
2a018e83
KS
640fi
641AM_CONDITIONAL(ENABLE_LOGIND, [test "$have_logind" = "yes"])
4c80c73c 642AS_IF([test "$have_logind" = "yes"], [ AC_DEFINE(HAVE_LOGIND, [1], [Logind support available]) ])
2a018e83 643
3e214785 644# ------------------------------------------------------------------------------
b2e9fb99
MV
645have_hostnamed=no
646AC_ARG_ENABLE(hostnamed, AS_HELP_STRING([--disable-hostnamed], [disable hostname daemon]))
647if test "x$enable_hostnamed" != "xno"; then
be31376e 648 have_hostnamed=yes
b2e9fb99
MV
649fi
650AM_CONDITIONAL(ENABLE_HOSTNAMED, [test "$have_hostnamed" = "yes"])
651
3e214785 652# ------------------------------------------------------------------------------
f47cd184
MV
653have_timedated=no
654AC_ARG_ENABLE(timedated, AS_HELP_STRING([--disable-timedated], [disable timedate daemon]))
655if test "x$enable_timedated" != "xno"; then
be31376e 656 have_timedated=yes
f47cd184
MV
657fi
658AM_CONDITIONAL(ENABLE_TIMEDATED, [test "$have_timedated" = "yes"])
659
3e214785 660# ------------------------------------------------------------------------------
4cd1eaa5
MV
661have_localed=no
662AC_ARG_ENABLE(localed, AS_HELP_STRING([--disable-localed], [disable locale daemon]))
663if test "x$enable_localed" != "xno"; then
be31376e 664 have_localed=yes
4cd1eaa5
MV
665fi
666AM_CONDITIONAL(ENABLE_LOCALED, [test "$have_localed" = "yes"])
667
3e214785 668# ------------------------------------------------------------------------------
f5e04665
LP
669have_coredump=no
670AC_ARG_ENABLE(coredump, AS_HELP_STRING([--disable-coredump], [disable coredump hook]))
671if test "x$enable_coredump" != "xno"; then
be31376e 672 have_coredump=yes
f5e04665
LP
673fi
674AM_CONDITIONAL(ENABLE_COREDUMP, [test "$have_coredump" = "yes"])
675
46ba8aae
LP
676# ------------------------------------------------------------------------------
677have_polkit=no
678AC_ARG_ENABLE(polkit, AS_HELP_STRING([--disable-polkit], [disable PolicyKit support]))
679if test "x$enable_polkit" != "xno"; then
680 AC_DEFINE(ENABLE_POLKIT, 1, [Define if PolicyKit support is to be enabled])
681 have_polkit=yes
682fi
683AM_CONDITIONAL(ENABLE_POLKIT, [test "x$have_polkit" = "xyes"])
684
b872e9a0
LP
685# ------------------------------------------------------------------------------
686have_efi=no
687AC_ARG_ENABLE(efi, AS_HELP_STRING([--disable-efi], [disable EFI support]))
688if test "x$enable_efi" != "xno"; then
689 AC_DEFINE(ENABLE_EFI, 1, [Define if EFI support is to be enabled])
690 have_efi=yes
691fi
692AM_CONDITIONAL(ENABLE_EFI, [test "x$have_efi" = "xyes"])
693
b1c4ca25
LP
694# ------------------------------------------------------------------------------
695AC_ARG_WITH(rc-local-script-path-start,
696 AS_HELP_STRING([--with-rc-local-script-path-start=PATH],
697 [Path to /etc/rc.local]),
698 [RC_LOCAL_SCRIPT_PATH_START="$withval"],
699 [RC_LOCAL_SCRIPT_PATH_START="/etc/rc.local"])
700
701AC_ARG_WITH(rc-local-script-path-stop,
702 AS_HELP_STRING([--with-rc-local-script-path-stop=PATH],
bc270841 703 [Path to /usr/sbin/halt.local]),
b1c4ca25 704 [RC_LOCAL_SCRIPT_PATH_STOP="$withval"],
bc270841 705 [RC_LOCAL_SCRIPT_PATH_STOP="/usr/sbin/halt.local"])
b1c4ca25
LP
706
707AC_DEFINE_UNQUOTED(RC_LOCAL_SCRIPT_PATH_START, ["$RC_LOCAL_SCRIPT_PATH_START"], [Path of /etc/rc.local script])
bc270841 708AC_DEFINE_UNQUOTED(RC_LOCAL_SCRIPT_PATH_STOP, ["$RC_LOCAL_SCRIPT_PATH_STOP"], [Path of /usr/sbin/halt.local script])
b1c4ca25
LP
709
710AC_SUBST(RC_LOCAL_SCRIPT_PATH_START)
711AC_SUBST(RC_LOCAL_SCRIPT_PATH_STOP)
712
a382332e
LP
713# ------------------------------------------------------------------------------
714AC_ARG_WITH(kbd-loadkeys,
715 AS_HELP_STRING([--with-kbd-loadkeys=PATH],
716 [Path to loadkeys]),
717 [KBD_LOADKEYS="$withval"],
718 [KBD_LOADKEYS="/usr/bin/loadkeys"])
719
720AC_ARG_WITH(kbd-setfont,
721 AS_HELP_STRING([--with-kbd-setfont=PATH],
722 [Path to setfont]),
723 [KBD_SETFONT="$withval"],
724 [KBD_SETFONT="/usr/bin/setfont"])
725
726AC_DEFINE_UNQUOTED(KBD_LOADKEYS, ["$KBD_LOADKEYS"], [Path of loadkeys])
727AC_DEFINE_UNQUOTED(KBD_SETFONT, ["$KBD_SETFONT"], [Path of setfont])
728
729AC_SUBST(KBD_LOADKEYS)
730AC_SUBST(KBD_SETFONT)
731
4ad61fd1
CR
732AC_ARG_WITH(telinit,
733 AS_HELP_STRING([--with-telinit=PATH],
734 [Path to telinit]),
735 [TELINIT="$withval"],
736 [TELINIT="/lib/upstart/telinit"])
737
738AC_DEFINE_UNQUOTED(TELINIT, ["$TELINIT"], [Path to telinit])
739
740AC_SUBST(TELINIT)
741
7211f918
LP
742AC_CHECK_HEADERS_ONCE([valgrind/memcheck.h])
743
d562955e
TG
744# ------------------------------------------------------------------------------
745have_myhostname=no
f8c5a581 746AC_ARG_ENABLE(myhostname, AS_HELP_STRING([--disable-myhostname], [disable nss-myhostname support]))
d562955e
TG
747if test "x$enable_myhostname" != "xno"; then
748 AC_HEADER_STDC
749 AC_CHECK_HEADERS([arpa/inet.h fcntl.h inttypes.h netdb.h netinet/in.h stdlib.h string.h sys/socket.h sys/time.h unistd.h nss.h sys/ioctl.h])
750
751 AC_C_CONST
752 AC_TYPE_SIZE_T
753 AC_HEADER_TIME
754
755 AC_FUNC_MALLOC
756 AC_FUNC_SELECT_ARGTYPES
757 AC_CHECK_FUNCS([gethostbyaddr gethostbyname gettimeofday inet_ntoa memset select socket strcspn strdup strerror strncasecmp strcasecmp strspn])
758
759 have_myhostname=yes
760fi
761AM_CONDITIONAL(HAVE_MYHOSTNAME, [test "$have_myhostname" = "yes"])
762
3e214785
KS
763# ------------------------------------------------------------------------------
764AC_ARG_WITH(firmware-path,
765 AS_HELP_STRING([--with-firmware-path=DIR[[[:DIR[...]]]]],
a3bd8447
TG
766 [Firmware search path (default="")]),
767 [], [with_firmware_path=""])
3e214785
KS
768OLD_IFS=$IFS
769IFS=:
770for i in $with_firmware_path; do
771 if test "x${FIRMWARE_PATH}" = "x"; then
772 FIRMWARE_PATH="\\\"${i}/\\\""
773 else
774 FIRMWARE_PATH="${FIRMWARE_PATH}, \\\"${i}/\\\""
775 fi
776done
777IFS=$OLD_IFS
a3bd8447 778AC_SUBST(FIRMWARE_PATH)
d8d4bee7 779AS_IF([test "x${FIRMWARE_PATH}" != "x"], [ AC_DEFINE(HAVE_FIRMWARE, 1, [Define if FIRMWARE is available]) ])
a3bd8447 780AM_CONDITIONAL(ENABLE_FIRMWARE, [test "x${FIRMWARE_PATH}" != "x"])
3e214785
KS
781
782# ------------------------------------------------------------------------------
783AC_ARG_ENABLE([gudev],
784 AS_HELP_STRING([--disable-gudev], [disable Gobject libudev support @<:@default=enabled@:>@]),
785 [], [enable_gudev=yes])
de1c301e 786AS_IF([test "x$enable_gudev" = "xyes"], [ PKG_CHECK_MODULES([GLIB], [glib-2.0 >= 2.22.0 gobject-2.0 >= 2.22.0 gio-2.0]) ])
3e214785 787AM_CONDITIONAL([ENABLE_GUDEV], [test "x$enable_gudev" = "xyes"])
de1c301e
LP
788AS_IF([test "x$enable_gudev" = "xyes"], [ AC_DEFINE(HAVE_GLIB, 1, [Define if glib is available]) ])
789
3e214785
KS
790# ------------------------------------------------------------------------------
791AC_ARG_ENABLE([keymap],
792 AS_HELP_STRING([--disable-keymap], [disable keymap fixup support @<:@default=enabled@:>@]),
793 [], [enable_keymap=yes])
794AS_IF([test "x$enable_keymap" = "xyes"], [
795 AC_PATH_PROG([GPERF], [gperf])
796 if test -z "$GPERF"; then
797 AC_MSG_ERROR([gperf is needed])
798 fi
799
800 AC_CHECK_HEADER([linux/input.h], [:], AC_MSG_ERROR([kernel headers not found]))
801 AC_SUBST([INCLUDE_PREFIX], [$(echo '#include <linux/input.h>' | eval $ac_cpp -E - | sed -n '/linux\/input.h/ {s:.*"\(.*\)/linux/input.h".*:\1:; p; q}')])
802])
803AM_CONDITIONAL([ENABLE_KEYMAP], [test "x$enable_keymap" = "xyes"])
804
805# ------------------------------------------------------------------------------
75db9a77 806have_manpages=no
4c2b0e4e 807AC_ARG_ENABLE(manpages, AS_HELP_STRING([--disable-manpages], [disable manpages]))
fe1fed02
ZJS
808AS_IF([test "x$enable_manpages" != xno], [
809 AS_IF([test "x$enable_manpages" = xyes -a "x$XSLTPROC" = x], [
810 AC_MSG_ERROR([*** Manpages requested but xsltproc not found])
811 ])
812 AS_IF([test "x$XSLTPROC" != x], [have_manpages=yes])
813])
814AM_CONDITIONAL(ENABLE_MANPAGES, [test "x$have_manpages" = "xyes"])
75db9a77 815
3e214785 816# ------------------------------------------------------------------------------
d1ab0ca0 817
34eff652
LP
818# Location of the init scripts as mandated by LSB
819SYSTEM_SYSVINIT_PATH=/etc/init.d
f1dd0c3f 820SYSTEM_SYSVRCND_PATH=/etc/rc.d
f975e971 821M4_DEFINES=
12e84679 822
136337ff 823AC_ARG_WITH([sysvinit-path],
be31376e 824 [AS_HELP_STRING([--with-sysvinit-path=PATH],
bc270841 825 [Specify the path to where the SysV init scripts are located])],
be31376e
KS
826 [SYSTEM_SYSVINIT_PATH="$withval"],
827 [])
136337ff 828
dee4c244
LP
829AC_ARG_WITH([sysvrcnd-path],
830 [AS_HELP_STRING([--with-sysvrcnd-path=PATH],
bc270841 831 [Specify the path to the base directory for the SysV rcN.d directories])],
136337ff
TFH
832 [SYSTEM_SYSVRCND_PATH="$withval"],
833 [])
834
07459bb6
FF
835if test "x${SYSTEM_SYSVINIT_PATH}" != "x" -a "x${SYSTEM_SYSVRCND_PATH}" != "x"; then
836 AC_DEFINE(HAVE_SYSV_COMPAT, [], [SysV init scripts and rcN.d links are supported.])
837 SYSTEM_SYSV_COMPAT="yes"
f975e971 838 M4_DEFINES="$M4_DEFINES -DHAVE_SYSV_COMPAT"
07459bb6 839elif test "x${SYSTEM_SYSVINIT_PATH}" != "x" -o "x${SYSTEM_SYSVRCND_PATH}" != "x"; then
dee4c244 840 AC_MSG_ERROR([*** You need both --with-sysvinit-path=PATH and --with-sysvrcnd-path=PATH to enable SysV compatibility support, or both empty to disable it.])
07459bb6
FF
841else
842 SYSTEM_SYSV_COMPAT="no"
843fi
844
bc270841
LP
845AC_SUBST(SYSTEM_SYSVINIT_PATH)
846AC_SUBST(SYSTEM_SYSVRCND_PATH)
847AC_SUBST(M4_DEFINES)
848
849AM_CONDITIONAL(HAVE_SYSV_COMPAT, test "$SYSTEM_SYSV_COMPAT" = "yes")
850
bef2733f 851AC_ARG_WITH([tty-gid],
a05ea46d 852 [AS_HELP_STRING([--with-tty-gid=GID],
bef2733f
LP
853 [Specify the numeric GID of the 'tty' group])],
854 [AC_DEFINE_UNQUOTED(TTY_GID, [$withval], [GID of the 'tty' group])],
855 [])
856
d2d12cd1
LP
857AC_ARG_WITH([dbuspolicydir],
858 AS_HELP_STRING([--with-dbuspolicydir=DIR], [D-Bus policy directory]),
859 [],
25ee45f9 860 [with_dbuspolicydir=$($PKG_CONFIG --variable=sysconfdir dbus-1)/dbus-1/system.d])
d122948d 861
d2d12cd1
LP
862AC_ARG_WITH([dbussessionservicedir],
863 AS_HELP_STRING([--with-dbussessionservicedir=DIR], [D-Bus session service directory]),
864 [],
25ee45f9 865 [with_dbussessionservicedir=$($PKG_CONFIG --variable=session_bus_services_dir dbus-1)])
d122948d 866
d2d12cd1
LP
867AC_ARG_WITH([dbussystemservicedir],
868 AS_HELP_STRING([--with-dbussystemservicedir=DIR], [D-Bus system service directory]),
869 [],
03c14914 870 [with_dbussystemservicedir=$(readlink -m $($PKG_CONFIG --variable=session_bus_services_dir dbus-1)/../system-services)])
d122948d 871
d2d12cd1
LP
872AC_ARG_WITH([dbusinterfacedir],
873 AS_HELP_STRING([--with-dbusinterfacedir=DIR], [D-Bus interface directory]),
874 [],
03c14914 875 [with_dbusinterfacedir=$(readlink -m $($PKG_CONFIG --variable=session_bus_services_dir dbus-1)/../interfaces)])
d122948d 876
db059f1b
MB
877AC_ARG_WITH([bashcompletiondir],
878 AS_HELP_STRING([--with-bashcompletiondir=DIR], [Bash completions directory]),
879 [],
25ee45f9
MB
880 [AS_IF([$($PKG_CONFIG --exists bash-completion)], [
881 with_bashcompletiondir=$($PKG_CONFIG --variable=completionsdir bash-completion)
db059f1b
MB
882 ] , [
883 with_bashcompletiondir=${datadir}/bash-completion/completions
884 ])])
885
b8079ae1
KS
886AC_ARG_WITH([rootprefix],
887 AS_HELP_STRING([--with-rootprefix=DIR], [rootfs directory prefix for config files and kernel modules]),
39ad55a9 888 [], [with_rootprefix=${ac_default_prefix}])
d2d12cd1 889
ae446765
KS
890AC_ARG_WITH([rootlibdir],
891 AS_HELP_STRING([--with-rootlibdir=DIR], [Root directory for libraries necessary for boot]),
892 [],
893 [with_rootlibdir=${libdir}])
894
9d3203b4 895AC_ARG_WITH([pamlibdir],
b0cca7d8 896 AS_HELP_STRING([--with-pamlibdir=DIR], [Directory for PAM modules]),
9d3203b4
KS
897 [],
898 [with_pamlibdir=${with_rootlibdir}/security])
899
bc9bdbba
MG
900AC_ARG_ENABLE([split-usr],
901 AS_HELP_STRING([--enable-split-usr], [Assume that /bin, /sbin aren\'t symlinks into /usr]),
902 [],
903 [AS_IF([test "x${ac_default_prefix}" != "x${with_rootprefix}"], [
904 enable_split_usr=yes
905 ], [
906 enable_split_usr=no
907 ])])
908
909AS_IF([test "x${enable_split_usr}" = "xyes"], [
2c6db6fb 910 AC_DEFINE(HAVE_SPLIT_USR, 1, [Define if /bin, /sbin aren't symlinks into /usr])
bc9bdbba 911])
2c6db6fb 912
6fc00209
ZJS
913# Work around intltoolize and gtk-doc problems in VPATH builds
914AM_CONDITIONAL([ENABLE_GTK_DOC_TESTS], [test "x$0" = "x./configure"],
915 [Define to do gtk-doc tests])
916AS_IF([test "x$0" != "x./configure"], [
917 AC_SUBST([INTLTOOL_UPDATE], [/bin/true])
918])
919
cee22bd3
HGB
920AC_ARG_ENABLE(tests,
921 [AC_HELP_STRING([--disable-tests], [disable tests])],
922 enable_tests=$enableval, enable_tests=yes)
923AM_CONDITIONAL(ENABLE_TESTS, [test x$enable_tests = xyes])
924
d2d12cd1
LP
925AC_SUBST([dbuspolicydir], [$with_dbuspolicydir])
926AC_SUBST([dbussessionservicedir], [$with_dbussessionservicedir])
927AC_SUBST([dbussystemservicedir], [$with_dbussystemservicedir])
928AC_SUBST([dbusinterfacedir], [$with_dbusinterfacedir])
db059f1b 929AC_SUBST([bashcompletiondir], [$with_bashcompletiondir])
8c6db833 930AC_SUBST([pamlibdir], [$with_pamlibdir])
b8079ae1 931AC_SUBST([rootprefix], [$with_rootprefix])
ae446765 932AC_SUBST([rootlibdir], [$with_rootlibdir])
8c4a3079 933
3e214785
KS
934AC_CONFIG_FILES([
935 Makefile po/Makefile.in
bb061708
KS
936 docs/libudev/Makefile
937 docs/libudev/version.xml
938 docs/gudev/Makefile
939 docs/gudev/version.xml
3e214785
KS
940])
941
a45a909f 942AC_OUTPUT
ae446765 943AC_MSG_RESULT([
0571e011
LP
944 $PACKAGE_NAME $VERSION
945
7f4e0805 946 libcryptsetup: ${have_libcryptsetup}
5b6319dc
LP
947 tcpwrap: ${have_tcpwrap}
948 PAM: ${have_pam}
12716238 949 AUDIT: ${have_audit}
81611586 950 IMA: ${have_ima}
12716238 951 SELinux: ${have_selinux}
2b3e18de 952 SMACK: ${have_smack}
807e17f0 953 XZ: ${have_xz}
5eda94dd 954 ACL: ${have_acl}
fb0951b0 955 XATTR: ${have_xattr}
7560fffc 956 GCRYPT: ${have_gcrypt}
f6a971bc 957 QRENCODE: ${have_qrencode}
7b17a7d7 958 MICROHTTPD: ${have_microhttpd}
77e68fa2 959 CHKCONFIG: ${have_chkconfig}
27669061 960 binfmt: ${have_binfmt}
e5e83e83
LP
961 vconsole: ${have_vconsole}
962 readahead: ${have_readahead}
83fdc450 963 bootchart: ${have_bootchart}
4de85612 964 quotacheck: ${have_quotacheck}
6351163b 965 tmpfiles: ${have_tmpfiles}
4de85612 966 randomseed: ${have_randomseed}
2a018e83 967 logind: ${have_logind}
b2e9fb99 968 hostnamed: ${have_hostnamed}
f47cd184 969 timedated: ${have_timedated}
4cd1eaa5 970 localed: ${have_localed}
f5e04665 971 coredump: ${have_coredump}
46ba8aae 972 polkit: ${have_polkit}
b872e9a0 973 efi: ${have_efi}
e3043162 974 kmod: ${have_kmod}
f553b3b1 975 blkid: ${have_blkid}
d562955e 976 nss-myhostname: ${have_myhostname}
3e214785
KS
977 gudev: ${enable_gudev}
978 gintrospection: ${enable_introspection}
979 keymap: ${enable_keymap}
8d7e170a
LP
980 Python: ${have_python}
981 Python Headers: ${have_python_devel}
2f4da3e6
ZJS
982 man pages: ${have_manpages}
983 gtk-doc: ${enable_gtk_doc}
984 Split /usr: ${enable_split_usr}
985 SysV compatibility: ${SYSTEM_SYSV_COMPAT}
3e214785 986
8c4a3079 987 prefix: ${prefix}
b8079ae1 988 rootprefix: ${with_rootprefix}
3e214785
KS
989 sysconf dir: ${sysconfdir}
990 datarootdir: ${datarootdir}
991 includedir: ${includedir}
992 include_prefix: ${INCLUDE_PREFIX}
ae446765
KS
993 lib dir: ${libdir}
994 rootlib dir: ${with_rootlibdir}
2f4da3e6
ZJS
995 SysV init scripts: ${SYSTEM_SYSVINIT_PATH}
996 SysV rc?.d directories: ${SYSTEM_SYSVRCND_PATH}
997 Build Python: ${PYTHON}
998 Installation Python: ${PYTHON_BINARY}
999 firmware path: ${FIRMWARE_PATH}
2c6db6fb 1000 PAM modules dir: ${with_pamlibdir}
2c6db6fb
LP
1001 D-Bus policy dir: ${with_dbuspolicydir}
1002 D-Bus session dir: ${with_dbussessionservicedir}
1003 D-Bus system dir: ${with_dbussystemservicedir}
1004 D-Bus interfaces dir: ${with_dbusinterfacedir}
db059f1b 1005 Bash completions dir: ${with_bashcompletiondir}
b1c4ca25
LP
1006 Extra start script: ${RC_LOCAL_SCRIPT_PATH_START}
1007 Extra stop script: ${RC_LOCAL_SCRIPT_PATH_STOP}
45df1f2c 1008 Debug shell: ${SUSHELL} @ ${DEBUGTTY}
66be6554 1009
5a45a936 1010 CFLAGS: ${OUR_CFLAGS} ${CFLAGS}
1f048a6b 1011 CPPFLAGS: ${OUR_CPPFLAGS} ${CPPFLAGS}
5a45a936 1012 LDFLAGS: ${OUR_LDFLAGS} ${LDFLAGS}
568c7e02
ZJS
1013 PYTHON_CFLAGS: ${PYTHON_CFLAGS}
1014 PYTHON_LIBS: ${PYTHON_LIBS}
ae446765 1015])