configure.ac revision 1d64e14c30e993c2d3dc948fe53118d8700c3ade
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering# This file is part of systemd.
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers# Copyright 2010-2012 Lennart Poettering
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers# Copyright 2010-2012 Kay Sievers
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering# systemd is free software; you can redistribute it and/or modify it
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering# under the terms of the GNU Lesser General Public License as published by
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering# the Free Software Foundation; either version 2.1 of the License, or
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering# (at your option) any later version.
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering# systemd is distributed in the hope that it will be useful, but
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering# WITHOUT ANY WARRANTY; without even the implied warranty of
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering# Lesser General Public License for more details.
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering# You should have received a copy of the GNU Lesser General Public License
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering# along with systemd; If not, see <http://www.gnu.org/licenses/>.
4e949c11a1df4547d5f102e4131e07b026369cd7Javier JardónAC_PREREQ([2.64])
4e949c11a1df4547d5f102e4131e07b026369cd7Javier JardónAC_INIT([systemd],
4e949c11a1df4547d5f102e4131e07b026369cd7Javier Jardón [http://bugs.freedesktop.org/enter_bug.cgi?product=systemd],
4e949c11a1df4547d5f102e4131e07b026369cd7Javier Jardón [http://www.freedesktop.org/wiki/Software/systemd])
78a825f216d39ee0295b00647b059d45467e1d02Kay SieversAC_CONFIG_SRCDIR([src/core/main.c])
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart PoetteringAC_CONFIG_MACRO_DIR([m4])
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart PoetteringAC_CONFIG_HEADERS([config.h])
a80db8bd5f7f15859e8891aab9fc3694ce4cd0bdJavier JardónAC_CONFIG_AUX_DIR([build-aux])
4db6d587c37c0357d20c79bf1a7c9afd4c7ced61Kay SieversAC_USE_SYSTEM_EXTENSIONS
907dd1953b7517534d646f5b2777780020c896e2Kay SieversAC_SYS_LARGEFILE
eb7bbee6cd182d5c4eb1e1180631c35158f59379Kay SieversAC_PREFIX_DEFAULT([/usr])
6aad7f2cd75c88f990c7857bb173b3e8d0faee0fUmut Tezduyar LindskogAM_MAINTAINER_MODE([enable])
4196a3ead3cfb823670d225eefcb3e60e34c7d95Kay SieversAM_INIT_AUTOMAKE([foreign 1.11 -Wall -Wno-portability silent-rules tar-pax no-dist-gzip dist-xz subdir-objects parallel-tests])
3e2147858f21943d5f4a781c60f33ac22c6096edKay SieversAM_SILENT_RULES([yes])
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart PoetteringAC_CANONICAL_HOST
22be093ffb403a1c474037939ca9b88b1ee39f77Lennart PoetteringAC_DEFINE_UNQUOTED([CANONICAL_HOST], "$host", [Canonical host string.])
d59d0a2b4b41a75eaf618b26b8f8bd1e17de7e2bceeLT_PREREQ(2.2)
d59d0a2b4b41a75eaf618b26b8f8bd1e17de7e2bceeLT_INIT([disable-static])
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart PoetteringAS_IF([test "x$enable_static" = "xyes"], [AC_MSG_ERROR([--enable-static is not supported by systemd])])
3e2147858f21943d5f4a781c60f33ac22c6096edKay SieversAS_IF([test "x$enable_largefile" = "xno"], [AC_MSG_ERROR([--disable-largefile is not supported by systemd])])
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart PoetteringSET_ARCH(X86_64, x86_64*)
5e63ce78b5018ba612e794a610a6f13c5eefade7Cristian RodríguezSET_ARCH(IA32, i*86*)
3d585edbb14b9705c80183aeb16dfd0a28df0ac9Lennart PoetteringSET_ARCH(MIPS, mips*)
1c7dde3e475978c569a982d65fd86d4b4e3caad8Bastien Nocera# i18n stuff for the PolicyKit policy files, heck whether intltool can be found, disable NLS otherwise
f15515b5e6a9ebe95c938cc670df6e576fcf9176Filipe BrandenburgerAC_CHECK_PROG(intltool_found, [intltool-merge], [yes], [no])
f15515b5e6a9ebe95c938cc670df6e576fcf9176Filipe BrandenburgerAS_IF([test x"$intltool_found" != xyes],
f15515b5e6a9ebe95c938cc670df6e576fcf9176Filipe Brandenburger [AS_IF([test x"$enable_nls" = xyes],
f15515b5e6a9ebe95c938cc670df6e576fcf9176Filipe Brandenburger [AC_MSG_ERROR([--enable-nls requested but intltool not found])],
f15515b5e6a9ebe95c938cc670df6e576fcf9176Filipe Brandenburger [AS_IF([test x"$enable_nls" != xno],
f15515b5e6a9ebe95c938cc670df6e576fcf9176Filipe Brandenburger [AC_MSG_WARN([*** Disabling NLS support because intltool was not found])
f15515b5e6a9ebe95c938cc670df6e576fcf9176Filipe Brandenburger enable_nls=no])
f15515b5e6a9ebe95c938cc670df6e576fcf9176Filipe BrandenburgerAS_IF([test x"$enable_nls" != xno -o "x$enable_polkit" != xno], [
2f96919bcdd0978164c801b21e053fb3b31e8bacFilipe Brandenburger # intltoolize greps for '^(AC|IT)_PROG_INTLTOOL', so it needs to be on its own line
a59f16ce4a11c440cb2136ad3d5e3184714c545eRobert SchieleIT_PROG_INTLTOOL([0.40.0])
2f96919bcdd0978164c801b21e053fb3b31e8bacFilipe BrandenburgerAS_IF([test -z "$INTLTOOL_POLICY_RULE"], [
2f96919bcdd0978164c801b21e053fb3b31e8bacFilipe Brandenburger # If intltool is not available, provide a dummy rule to fail generation of %.policy files with a meaningful error message
2f96919bcdd0978164c801b21e053fb3b31e8bacFilipe Brandenburger INTLTOOL_POLICY_RULE='%.policy: %.policy.in ; @echo " ITMRG " $@ && echo "*** intltool support required to build target $@" && false'
2f96919bcdd0978164c801b21e053fb3b31e8bacFilipe Brandenburger AC_SUBST(INTLTOOL_POLICY_RULE)
2f96919bcdd0978164c801b21e053fb3b31e8bacFilipe BrandenburgerGETTEXT_PACKAGE=systemd
1c7dde3e475978c569a982d65fd86d4b4e3caad8Bastien NoceraAC_SUBST(GETTEXT_PACKAGE)
1c7dde3e475978c569a982d65fd86d4b4e3caad8Bastien NoceraAC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [systemd])
1c7dde3e475978c569a982d65fd86d4b4e3caad8Bastien NoceraAC_PROG_MKDIR_P
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart PoetteringAC_PATH_PROG([M4], [m4])
3e2147858f21943d5f4a781c60f33ac22c6096edKay SieversAC_PATH_PROG([XSLTPROC], [xsltproc])
92ec4495f76a7a2a6c31f5bb2a5240f78dcfe1d2Javier JardónAC_PATH_PROG([QUOTAON], [quotaon], [/usr/sbin/quotaon], [$PATH:/usr/sbin:/sbin])
2d0efdf1af5ff77441228854343c61d42a89840cSamuli SuominenAC_PATH_PROG([QUOTACHECK], [quotacheck], [/usr/sbin/quotacheck], [$PATH:/usr/sbin:/sbin])
b51fc639f01ee6194af3e7e944a79accce474fe1Dave ReisnerAC_PATH_PROG([SETCAP], [setcap], [/usr/sbin/setcap], [$PATH:/usr/sbin:/sbin])
dd5ae4c36c89da5dbe8d1628939b26c00db98753Przemyslaw KedzierskiAC_PATH_PROG([KILL], [kill], [/usr/bin/kill], [$PATH:/usr/sbin:/sbin])
96ede2601f27cd5fe52eed96b873bef55cd0ce23Lennart PoetteringAC_PATH_PROG([KMOD], [kmod], [/usr/bin/kmod], [$PATH:/usr/sbin:/sbin])
edeb68c53f1cdc452016b4c8512586a70b1262e3Tom GundersenAC_PATH_PROG([KEXEC], [kexec], [/usr/sbin/kexec], [$PATH:/usr/sbin:/sbin])
7801356442578ff6e1c65844eb9e65c819af4660Zbigniew Jędrzejewski-SzmekAC_PATH_PROG([SULOGIN], [sulogin], [/usr/sbin/sulogin], [$PATH:/usr/sbin:/sbin])
446883528524429283626208928b51f49f28f810Lennart PoetteringAS_IF([! ln --relative --help > /dev/null 2>&1], [AC_MSG_ERROR([*** ln doesn't support --relative ***])])
b37250d661ed67d07c734630617d73e64f6d7e49Zbigniew Jędrzejewski-Szmek# gtkdocize greps for '^GTK_DOC_CHECK', so it needs to be on its own line
b37250d661ed67d07c734630617d73e64f6d7e49Zbigniew Jędrzejewski-Szmekm4_ifdef([GTK_DOC_CHECK], [
6581f00f7eabdaccf587a4b6af60ed4696dd2791Zbigniew Jędrzejewski-SzmekGTK_DOC_CHECK([1.18],[--flavour no-tmpl])],
6581f00f7eabdaccf587a4b6af60ed4696dd2791Zbigniew Jędrzejewski-Szmek [AM_CONDITIONAL([ENABLE_GTK_DOC], [false])
92ec4495f76a7a2a6c31f5bb2a5240f78dcfe1d2Javier Jardón enable_gtk_doc=no])
fe1fed02c7637a2c18cd575f78be7fda27972148Zbigniew Jędrzejewski-SzmekAS_IF([test "x$enable_gtk_doc" = "xyes" -a "x$XSLTPROC" = x], [
fe1fed02c7637a2c18cd575f78be7fda27972148Zbigniew Jędrzejewski-Szmek AC_MSG_ERROR([*** GTK doc requested but xsltproc not found])
0eaeca1f2373a323b98c86b47561d98e59c67b25Kay Sieversm4_ifdef([GOBJECT_INTROSPECTION_CHECK], [
d66ee73a3dd7b5433fc0da3125bbdff740de7745Zbigniew Jędrzejewski-SzmekGOBJECT_INTROSPECTION_CHECK([1.31.1])
d66ee73a3dd7b5433fc0da3125bbdff740de7745Zbigniew Jędrzejewski-Szmek AM_CONDITIONAL([HAVE_INTROSPECTION], [false])
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers enable_introspection=no])
ac714a78fdca481488d88f84b6332d28083a4511Martin JansaAC_CHECK_TOOL(STRINGS, strings)
b62cfcea00862ccbf0e5e297f8a339f70987edefMichael BieblAC_CHECK_TOOL(GPERF, gperf)
b62cfcea00862ccbf0e5e297f8a339f70987edefMichael Bieblif test -z "$GPERF" ; then
b62cfcea00862ccbf0e5e297f8a339f70987edefMichael Biebl AC_MSG_ERROR([*** gperf not found])
732bfe09aeffc3cd78b80ee9e20c9c3babd944d6Zbigniew Jędrzejewski-Szmek# ------------------------------------------------------------------------------
732bfe09aeffc3cd78b80ee9e20c9c3babd944d6Zbigniew Jędrzejewski-Szmekaddress_sanitizer_cflags=
732bfe09aeffc3cd78b80ee9e20c9c3babd944d6Zbigniew Jędrzejewski-Szmekaddress_sanitizer_cppflags=
732bfe09aeffc3cd78b80ee9e20c9c3babd944d6Zbigniew Jędrzejewski-Szmekaddress_sanitizer_ldflags=
732bfe09aeffc3cd78b80ee9e20c9c3babd944d6Zbigniew Jędrzejewski-SzmekAC_ARG_ENABLE(address-sanitizer, AS_HELP_STRING([--enable-address-sanitizer], [enable -fsanitize=address]))
732bfe09aeffc3cd78b80ee9e20c9c3babd944d6Zbigniew Jędrzejewski-SzmekAS_IF([test "x$enable_address_sanitizer" = "xyes"], [
732bfe09aeffc3cd78b80ee9e20c9c3babd944d6Zbigniew Jędrzejewski-Szmek CC_CHECK_FLAG_APPEND([with_as_cflags], [CFLAGS], [-fsanitize=address])
732bfe09aeffc3cd78b80ee9e20c9c3babd944d6Zbigniew Jędrzejewski-Szmek AS_IF([test -z "$with_as_cflags"],
732bfe09aeffc3cd78b80ee9e20c9c3babd944d6Zbigniew Jędrzejewski-Szmek [AC_MSG_ERROR([*** -fsanitize=address is not supported])])
732bfe09aeffc3cd78b80ee9e20c9c3babd944d6Zbigniew Jędrzejewski-Szmek address_sanitizer_cflags="$with_as_cflags -fno-omit-frame-pointer -DVALGRIND=1"
732bfe09aeffc3cd78b80ee9e20c9c3babd944d6Zbigniew Jędrzejewski-Szmek address_sanitizer_cppflags="-DVALGRIND=1"
732bfe09aeffc3cd78b80ee9e20c9c3babd944d6Zbigniew Jędrzejewski-Szmek address_sanitizer_ldflags="-Wc,-fsanitize=address"
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmekundefined_sanitizer_cflags=
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmekundefined_sanitizer_cppflags=
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmekundefined_sanitizer_ldflags=
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-SzmekAC_ARG_ENABLE(undefined-sanitizer, AS_HELP_STRING([--enable-undefined-sanitizer], [enable -fsanitize=undefined]))
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-SzmekAS_IF([test "x$enable_undefined_sanitizer" = "xyes"], [
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmek CC_CHECK_FLAG_APPEND([with_us_cflags], [CFLAGS], [-fsanitize=undefined])
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmek AS_IF([test -z "$with_us_cflags"],
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmek [AC_MSG_ERROR([*** -fsanitize=undefined is not supported])])
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmek undefined_sanitizer_cflags="$with_us_cflags -fno-omit-frame-pointer -DVALGRIND=1"
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmek undefined_sanitizer_cppflags="-DVALGRIND=1"
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmek undefined_sanitizer_ldflags="-Wc,-fsanitize=undefined"
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmeksanitizer_cflags="$address_sanitizer_cflags $undefined_sanitizer_cflags"
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmeksanitizer_cppflags="$address_sanitizer_cppflags $undefined_sanitizer_cppflags"
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmeksanitizer_ldflags="$address_sanitizer_ldflags $undefined_sanitizer_ldflags"
be1a67d9d63bfdd4a5f8ba9cfc804030f10f5833Lennart PoetteringCC_CHECK_FLAGS_APPEND([with_cflags], [CFLAGS], [\
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering "-Wformat=2 -Wformat-security -Wformat-nonliteral" \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wlogical-op \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wsign-compare \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wmissing-include-dirs \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wold-style-definition \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wpointer-arith \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wdeclaration-after-statement \
693eb9a2d42d71445dad273a76e2470199d1dc5aLennart Poettering -Wfloat-equal \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wsuggest-attribute=noreturn \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wmissing-prototypes \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wstrict-prototypes \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wredundant-decls \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wmissing-declarations \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wmissing-noreturn \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wendif-labels \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wstrict-aliasing=2 \
be1a67d9d63bfdd4a5f8ba9cfc804030f10f5833Lennart Poettering -Wwrite-strings \
be1a67d9d63bfdd4a5f8ba9cfc804030f10f5833Lennart Poettering -Wno-long-long \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wno-overlength-strings \
be1a67d9d63bfdd4a5f8ba9cfc804030f10f5833Lennart Poettering -Wno-unused-parameter \
8745297f9853c4a17bac69e1b7e652fe81bc1940Lennart Poettering -Wno-missing-field-initializers \
d200735e13c52dcfe36c0e066f9f6c2fbfb85a9cMichal Schmidt -Wno-unused-result \
213298fb822258bb69c6b85b7c8d7f019fd2306aLennart Poettering -Wno-format-signedness \
693eb9a2d42d71445dad273a76e2470199d1dc5aLennart Poettering -Werror=overflow \
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering -Wnested-externs \
9b85fc6a89386582bfe792dba881800b0a093839Gustavo Sverzut Barbieri -fdiagnostics-show-option \
9b85fc6a89386582bfe792dba881800b0a093839Gustavo Sverzut Barbieri -fno-strict-aliasing \
5a45a93627609451784a04366cfa1150d32611d1Lennart Poettering -fvisibility=hidden \
c1663b9daf5a43425e54bbe3daf6b10e64578f80Lennart Poettering -ffunction-sections \
aca33b078cd32c5416a7fa3d5020a5d461c130eeCristian Rodríguez -fdata-sections \
2a4d1ec1520c926b0160efe14142634e164ddc30Cristian Rodríguez -fstack-protector \
c1663b9daf5a43425e54bbe3daf6b10e64578f80Lennart Poettering -fstack-protector-strong \
4f47bb8c5e5f234c614dc14532a9483328e61002Zbigniew Jędrzejewski-Szmek --param=ssp-buffer-size=4])
65e3a2cf7c3b399853dd309f702ca5078b7d16eaZbigniew Jędrzejewski-SzmekAS_CASE([$CC], [*clang*],
65e3a2cf7c3b399853dd309f702ca5078b7d16eaZbigniew Jędrzejewski-Szmek [CC_CHECK_FLAGS_APPEND([with_cppflags], [CPPFLAGS], [\
65e3a2cf7c3b399853dd309f702ca5078b7d16eaZbigniew Jędrzejewski-Szmek -Wno-typedef-redefinition \
4f47bb8c5e5f234c614dc14532a9483328e61002Zbigniew Jędrzejewski-Szmek -Wno-gnu-variable-sized-type-not-at-end \
235c6e628199221b7885f159367614b7105547cfJohnAS_CASE([$CFLAGS], [*-O[[12345\ ]]*],
b850b06e1efcc7e27cfd785759a3a913ac9ed196Kay Sievers [CC_CHECK_FLAGS_APPEND([with_cflags], [CFLAGS], [\
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmek -flto -ffat-lto-objects])],
5a45a93627609451784a04366cfa1150d32611d1Lennart Poettering [AC_MSG_RESULT([skipping -flto, optimization not enabled])])
03a170c03cd4a09721369ece48affb70d66c6b90Kay SieversAC_SUBST([OUR_CFLAGS], "$with_cflags $sanitizer_cflags")
a6c0b31d509f76023d8efbcd5e912863c8fb254cZbigniew Jędrzejewski-SzmekAS_CASE([$CFLAGS], [*-O[[12345\ ]]*],
a6c0b31d509f76023d8efbcd5e912863c8fb254cZbigniew Jędrzejewski-Szmek [CC_CHECK_FLAGS_APPEND([with_cppflags], [CPPFLAGS], [\
ae0ceefc2f432bc1068889fcff53d929eca8a3c4Zbigniew Jędrzejewski-Szmek -Wp,-D_FORTIFY_SOURCE=2])],
9e7adc3ae1133fa08a468768a490812299fad030Lucas De Marchi [AC_MSG_RESULT([skipping -D_FORTIFY_SOURCE, optimization not enabled])])
9e7adc3ae1133fa08a468768a490812299fad030Lucas De MarchiAC_SUBST([OUR_CPPFLAGS], "$with_cppflags $sanitizer_cppflags")
9d2d0fe1e3f28a639c26b62391f79cfd1450d91bEvangelos FoutrasCC_CHECK_FLAGS_APPEND([with_ldflags], [LDFLAGS], [\
5a45a93627609451784a04366cfa1150d32611d1Lennart Poettering -Wl,--as-needed \
5a45a93627609451784a04366cfa1150d32611d1Lennart Poettering -Wl,--no-undefined \
39c4ead2323b45bbe9866e0f97fd8dcfb8a0bedeZbigniew Jędrzejewski-Szmek -Wl,--gc-sections \
2a4d1ec1520c926b0160efe14142634e164ddc30Cristian Rodríguez -Wl,-z,relro \
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering -Wl,-fuse-ld=gold])
ccd06097c79218f7d5ea4c21721bbcbc7c467dcaZbigniew Jędrzejewski-SzmekAC_SUBST([OUR_LDFLAGS], "$with_ldflags $sanitizer_ldflags")
1c231f56482546725c4dbd3303f70300bd3c63e9Lennart PoetteringAC_CHECK_SIZEOF(pid_t)
de0671ee7fe465e108f62dcbbbe9366f81dd9e9aZbigniew Jędrzejewski-SzmekAC_CHECK_SIZEOF(uid_t)
de99c9dcbaf6e474551266d8f0b519bf2d8d0522Lennart PoetteringAC_CHECK_SIZEOF(gid_t)
de0671ee7fe465e108f62dcbbbe9366f81dd9e9aZbigniew Jędrzejewski-SzmekAC_CHECK_SIZEOF(time_t)
de0671ee7fe465e108f62dcbbbe9366f81dd9e9aZbigniew Jędrzejewski-SzmekAC_CHECK_SIZEOF(dev_t)
de0671ee7fe465e108f62dcbbbe9366f81dd9e9aZbigniew Jędrzejewski-SzmekAC_CHECK_SIZEOF(rlim_t,,[
c937e0d5c579863677e0fcb5508517f7714c332dZbigniew Jędrzejewski-Szmek# ------------------------------------------------------------------------------
c937e0d5c579863677e0fcb5508517f7714c332dZbigniew Jędrzejewski-Szmek# we use python to build the man page index, and for systemd-python
c937e0d5c579863677e0fcb5508517f7714c332dZbigniew Jędrzejewski-SzmekAC_ARG_WITH([python],
32dcef3ab1eb91ee469c3246ef859578dccd8a45Zbigniew Jędrzejewski-Szmek [AS_HELP_STRING([--without-python], [Disable building the man page index and systemd-python (default: test)])])
be8737ae386166d2f279767ac87b226204c0de7eFilipe BrandenburgerAS_IF([test "x$with_python" != "xno"], [
be8737ae386166d2f279767ac87b226204c0de7eFilipe Brandenburger AM_PATH_PYTHON(,, [:])
be8737ae386166d2f279767ac87b226204c0de7eFilipe Brandenburger AS_IF([test "x$PYTHON" != "x:"], [
be8737ae386166d2f279767ac87b226204c0de7eFilipe Brandenburger AC_MSG_CHECKING([for python lxml module])
be8737ae386166d2f279767ac87b226204c0de7eFilipe Brandenburger AS_IF(["$PYTHON" -c 'import lxml' 2>/dev/null], [have_lxml=yes])
be8737ae386166d2f279767ac87b226204c0de7eFilipe Brandenburger AC_MSG_RESULT([$have_lxml])
be8737ae386166d2f279767ac87b226204c0de7eFilipe Brandenburger AS_IF([test "x$have_lxml" = "xyes"], [have_python=yes],
c937e0d5c579863677e0fcb5508517f7714c332dZbigniew Jędrzejewski-Szmek [AC_MSG_WARN([*** python support requires python-lxml module installed])])
747cf8cdf61cdad068c727e42eac699f2505ae77Zbigniew Jędrzejewski-SzmekAS_IF([test "$have_python" != "yes"], [
747cf8cdf61cdad068c727e42eac699f2505ae77Zbigniew Jędrzejewski-Szmek AS_IF([test "$with_python" = "yes"],
747cf8cdf61cdad068c727e42eac699f2505ae77Zbigniew Jędrzejewski-Szmek [AC_MSG_ERROR([*** python support requested but python support not found])])
747cf8cdf61cdad068c727e42eac699f2505ae77Zbigniew Jędrzejewski-Szmek AS_IF([test "$with_python" != "no"],
747cf8cdf61cdad068c727e42eac699f2505ae77Zbigniew Jędrzejewski-Szmek [AC_MSG_WARN([*** python support not found, some documentation cannot be built])])
c937e0d5c579863677e0fcb5508517f7714c332dZbigniew Jędrzejewski-SzmekAM_CONDITIONAL([HAVE_PYTHON], [test "x$have_python" = "xyes"])
25ee45f9953c121fc26a54a85ad7bb3a3180152bMichael BieblAS_IF([test "x$PYTHON_BINARY" = "x"],
c937e0d5c579863677e0fcb5508517f7714c332dZbigniew Jędrzejewski-Szmek [AS_IF([test "x$have_python" = "xyes"],
c937e0d5c579863677e0fcb5508517f7714c332dZbigniew Jędrzejewski-Szmek [PYTHON_BINARY="$(which "$PYTHON")"],
c937e0d5c579863677e0fcb5508517f7714c332dZbigniew Jędrzejewski-Szmek [PYTHON_BINARY=/usr/bin/python])])
1864b0e39505cd44a98eee61c97916b86491c0b4Zbigniew Jędrzejewski-SzmekAC_ARG_VAR(PYTHON_BINARY, [Python binary used to launch installed scripts])
1864b0e39505cd44a98eee61c97916b86491c0b4Zbigniew Jędrzejewski-SzmekAS_IF([test "x$have_python" != "xyes" -a "x$enable_python_devel" = "xyes"],
a6c0b31d509f76023d8efbcd5e912863c8fb254cZbigniew Jędrzejewski-Szmek [AC_MSG_ERROR([*** python-devel support requires --with-python])])
1864b0e39505cd44a98eee61c97916b86491c0b4Zbigniew Jędrzejewski-Szmekhave_python_devel=no
a6c0b31d509f76023d8efbcd5e912863c8fb254cZbigniew Jędrzejewski-SzmekAC_ARG_ENABLE(python_devel, AS_HELP_STRING([--disable-python-devel], [Do not build python modules]))
a6c0b31d509f76023d8efbcd5e912863c8fb254cZbigniew Jędrzejewski-SzmekAS_IF([test "x$have_python" = "xyes" -a "x$enable_python_devel" != "xno"], [
a6c0b31d509f76023d8efbcd5e912863c8fb254cZbigniew Jędrzejewski-Szmek PKG_CHECK_MODULES([PYTHON_DEVEL], [python-${PYTHON_VERSION}],
a6c0b31d509f76023d8efbcd5e912863c8fb254cZbigniew Jędrzejewski-Szmek [have_python_devel=yes],
a6c0b31d509f76023d8efbcd5e912863c8fb254cZbigniew Jędrzejewski-Szmek [PKG_CHECK_MODULES([PYTHON_DEVEL], [python],
a6c0b31d509f76023d8efbcd5e912863c8fb254cZbigniew Jędrzejewski-Szmek [have_python_devel=yes],
a6c0b31d509f76023d8efbcd5e912863c8fb254cZbigniew Jędrzejewski-Szmek [have_python_devel=no])])
f2ec0646aba7c6703a6c79603957e805b74c3befZbigniew Jędrzejewski-Szmek AS_IF([test "x$have_python_devel" = xno -a "x$enable_python_devel" = xyes],
c937e0d5c579863677e0fcb5508517f7714c332dZbigniew Jędrzejewski-Szmek [AC_MSG_ERROR([*** python-devel support requested but libraries not found])])
c937e0d5c579863677e0fcb5508517f7714c332dZbigniew Jędrzejewski-Szmek AC_PATH_PROGS(SPHINX_BUILD, sphinx-build-${PYTHON_VERSION} sphinx-build)
c937e0d5c579863677e0fcb5508517f7714c332dZbigniew Jędrzejewski-SzmekAM_CONDITIONAL([HAVE_PYTHON_DEVEL], [test "$have_python_devel" = "yes"])
afea26ad7d406d8b6c95d2642cb5a1d807b87546Lennart Poettering# ------------------------------------------------------------------------------
4b357e15876b730343db08719c877fdb45b6ad42Michael MarineauAC_SEARCH_LIBS([dlsym], [dl], [], [AC_MSG_ERROR([*** Dynamic linking loader library not found])])
27c64db6dff88ebe9761dfe3b0c073d2a9bf2e41Zbigniew Jędrzejewski-SzmekAC_CHECK_HEADERS([sys/capability.h], [], [AC_MSG_ERROR([*** POSIX caps headers not found])])
7959ff9914a6f3a59dbff95c199bcc540b70ac94Kay SieversAC_CHECK_HEADERS([linux/btrfs.h], [], [])
7959ff9914a6f3a59dbff95c199bcc540b70ac94Kay SieversAC_CHECK_HEADERS([linux/memfd.h], [], [])
85f19d825e7504676f3a80c78c1d9a7ec35a3b3fMichael Biebl# unconditionally pull-in librt with old glibc versions
85f19d825e7504676f3a80c78c1d9a7ec35a3b3fMichael BieblAC_SEARCH_LIBS([clock_gettime], [rt], [], [])
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poetteringsave_LIBS="$LIBS"
7959ff9914a6f3a59dbff95c199bcc540b70ac94Kay SieversAC_SEARCH_LIBS([cap_init], [cap], [], [AC_MSG_ERROR([*** POSIX caps library not found])])
7959ff9914a6f3a59dbff95c199bcc540b70ac94Kay SieversCAP_LIBS="$LIBS"
7959ff9914a6f3a59dbff95c199bcc540b70ac94Kay SieversAC_SUBST(CAP_LIBS)
fba1ea06bb5b653e9eb0cc1b6004af8da273a4abShawn LanddenAC_SEARCH_LIBS([mq_open], [rt], [], [AC_MSG_ERROR([*** POSIX RT library not found])])
85f19d825e7504676f3a80c78c1d9a7ec35a3b3fMichael BieblRT_LIBS="$LIBS"
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart PoetteringAC_SUBST(RT_LIBS)
27c64db6dff88ebe9761dfe3b0c073d2a9bf2e41Zbigniew Jędrzejewski-SzmekLIBS="$save_LIBS"
539618a0ddc2dc7f0fbe28de2ae0e07b34c81e60Lennart PoetteringAC_CHECK_FUNCS([memfd_create])
81577dc22887debaf9b19bf1034a2887fb9069c7Zbigniew Jędrzejewski-SzmekAC_CHECK_FUNCS([__secure_getenv secure_getenv])
81577dc22887debaf9b19bf1034a2887fb9069c7Zbigniew Jędrzejewski-SzmekAC_CHECK_DECLS([gettid, pivot_root, name_to_handle_at, setns, getrandom, renameat2, kcmp, LO_FLAGS_PARTSCAN],
75616a1332aff00d27db713cda3bd93c508a5b59Zbigniew Jędrzejewski-SzmekAC_CHECK_DECLS([IFLA_INET6_ADDR_GEN_MODE,
81577dc22887debaf9b19bf1034a2887fb9069c7Zbigniew Jędrzejewski-Szmek IFLA_MACVLAN_FLAGS,
81577dc22887debaf9b19bf1034a2887fb9069c7Zbigniew Jędrzejewski-Szmek IFLA_IPVLAN_MODE,
81577dc22887debaf9b19bf1034a2887fb9069c7Zbigniew Jędrzejewski-Szmek IFLA_VTI_REMOTE,
81577dc22887debaf9b19bf1034a2887fb9069c7Zbigniew Jędrzejewski-Szmek IFLA_PHYS_PORT_ID,
8ecec322fe6b34b64868d8cc3808b5613f09e8d3Zbigniew Jędrzejewski-Szmek IFLA_BOND_AD_INFO,
8ecec322fe6b34b64868d8cc3808b5613f09e8d3Zbigniew Jędrzejewski-Szmek IFLA_VLAN_PROTOCOL,
81577dc22887debaf9b19bf1034a2887fb9069c7Zbigniew Jędrzejewski-Szmek IFLA_VXLAN_LOCAL6,
81577dc22887debaf9b19bf1034a2887fb9069c7Zbigniew Jędrzejewski-Szmek IFLA_IPTUN_6RD_RELAY_PREFIXLEN,
81577dc22887debaf9b19bf1034a2887fb9069c7Zbigniew Jędrzejewski-Szmek IFLA_BRIDGE_VLAN_INFO,
81577dc22887debaf9b19bf1034a2887fb9069c7Zbigniew Jędrzejewski-Szmek IFLA_BRPORT_UNICAST_FLOOD],
ac6b760ceedd4b21921b6a682cf1479af3d3024fZbigniew Jędrzejewski-Szmek# This makes sure pkg.m4 is available.
ac6b760ceedd4b21921b6a682cf1479af3d3024fZbigniew Jędrzejewski-Szmekm4_pattern_forbid([^_?PKG_[A-Z_]+$],[*** pkg.m4 missing, please install pkg-config])
ac6b760ceedd4b21921b6a682cf1479af3d3024fZbigniew Jędrzejewski-Szmek# ------------------------------------------------------------------------------
ac6b760ceedd4b21921b6a682cf1479af3d3024fZbigniew Jędrzejewski-SzmekAC_ARG_ENABLE(dbus, AS_HELP_STRING([--disable-dbus], [disable usage of dbus-1 in tests]))
ac6b760ceedd4b21921b6a682cf1479af3d3024fZbigniew Jędrzejewski-SzmekAS_IF([test "x$enable_dbus" != "xno"], [
ac6b760ceedd4b21921b6a682cf1479af3d3024fZbigniew Jędrzejewski-Szmek PKG_CHECK_MODULES(DBUS, [dbus-1 >= 1.3.2],
2270309471213a3c960543e523130627e9cb10e2Kay Sievers [AC_DEFINE(HAVE_DBUS, 1, [Define if dbus-1 library is available]) have_dbus=yes],
4b357e15876b730343db08719c877fdb45b6ad42Michael Marineau [have_dbus=no])
37161c5148396448921841ae1026b281c7949652Emil Renner Berthing AS_IF([test "x$have_dbus" = "xno" -a "x$enable_dbus" = "xyes"],
37161c5148396448921841ae1026b281c7949652Emil Renner Berthing [AC_MSG_ERROR([*** dbus-1 support requested but libraries not found])])])
37161c5148396448921841ae1026b281c7949652Emil Renner BerthingAM_CONDITIONAL(HAVE_DBUS, [test "$have_dbus" = "yes"])
37161c5148396448921841ae1026b281c7949652Emil Renner Berthing# ------------------------------------------------------------------------------
37161c5148396448921841ae1026b281c7949652Emil Renner BerthingAC_ARG_ENABLE([utmp], AS_HELP_STRING([--disable-utmp], [disable utmp/wtmp log handling]),
37161c5148396448921841ae1026b281c7949652Emil Renner Berthing AS_CASE("x${enableval}",
37161c5148396448921841ae1026b281c7949652Emil Renner Berthing [xyes], [have_utmp=yes],
37161c5148396448921841ae1026b281c7949652Emil Renner Berthing [xno], [have_utmp=no],
53e856e16ac37fe30b8bb59153ff69aad0fa9c27Zbigniew Jędrzejewski-Szmek AC_MSG_ERROR(bad value ${enableval} for --enable-utmp)))
53e856e16ac37fe30b8bb59153ff69aad0fa9c27Zbigniew Jędrzejewski-SzmekAS_IF([test "x$have_utmp" = "xyes"], [AC_DEFINE(HAVE_UTMP, 1, [Define if utmp/wtmp support is enabled])])
53e856e16ac37fe30b8bb59153ff69aad0fa9c27Zbigniew Jędrzejewski-SzmekAM_CONDITIONAL([HAVE_UTMP], [test "x$have_utmp" = "xyes"])
53e856e16ac37fe30b8bb59153ff69aad0fa9c27Zbigniew Jędrzejewski-Szmek# ------------------------------------------------------------------------------
53e856e16ac37fe30b8bb59153ff69aad0fa9c27Zbigniew Jędrzejewski-Szmekhave_compat_libs=no
53e856e16ac37fe30b8bb59153ff69aad0fa9c27Zbigniew Jędrzejewski-SzmekAC_ARG_ENABLE([compat_libs], AS_HELP_STRING([--enable-compat-libs],[Enable creation of compatibility libraries]),
53e856e16ac37fe30b8bb59153ff69aad0fa9c27Zbigniew Jędrzejewski-Szmek [case "${enableval}" in
53e856e16ac37fe30b8bb59153ff69aad0fa9c27Zbigniew Jędrzejewski-Szmek yes) have_compat_libs=yes ;;
53e856e16ac37fe30b8bb59153ff69aad0fa9c27Zbigniew Jędrzejewski-Szmek no) have_compat_libs=no ;;
53e856e16ac37fe30b8bb59153ff69aad0fa9c27Zbigniew Jędrzejewski-Szmek *) AC_MSG_ERROR(bad value ${enableval} for --enable-compat-libs) ;;
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen [have_compat_libs=no])
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. AndersenAM_CONDITIONAL([ENABLE_COMPAT_LIBS], [test "$have_compat_libs" = "yes"])
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen# ------------------------------------------------------------------------------
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersenhave_coverage=no
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. AndersenAC_ARG_ENABLE(coverage, AS_HELP_STRING([--enable-coverage], [enable test coverage]))
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersenif test "x$enable_coverage" = "xyes" ; then
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen AC_CHECK_PROG(lcov_found, [lcov], [yes], [no])
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen if test "x$lcov_found" = xno ; then
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen AC_MSG_ERROR([*** lcov support requested but the program was not found])
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen lcov_version_major="`lcov --version | cut -d ' ' -f 4 | cut -d '.' -f 1`"
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen lcov_version_minor="`lcov --version | cut -d ' ' -f 4 | cut -d '.' -f 2`"
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen if test "$lcov_version_major" -eq 1 -a "$lcov_version_minor" -lt 10; then
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen AC_MSG_ERROR([*** lcov version is too old. 1.10 required])
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen have_coverage=yes
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen CC_CHECK_FLAGS_APPEND([with_coverage_cflags], [CFLAGS], [\
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen -fprofile-arcs \
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen -ftest-coverage])
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen AC_SUBST([OUR_CFLAGS], "$with_cflags $with_coverage_cflags")
e30431623a7d871da123cc37055ac49abf2c20eaTom GundersenAM_CONDITIONAL(ENABLE_COVERAGE, [test "$have_coverage" = "yes"])
e2ca86cf78f911a8be51f0224796e24883019139Dave Reisner# ------------------------------------------------------------------------------
a18535d9e138c525d0443ec9f30a90b3e2184686Tom GundersenAC_ARG_ENABLE(kmod, AS_HELP_STRING([--disable-kmod], [disable loadable modules support]))
e2ca86cf78f911a8be51f0224796e24883019139Dave Reisnerif test "x$enable_kmod" != "xno"; then
70d8320978dcbce022d9acbb953a10a7aca049abDavid Strauss PKG_CHECK_EXISTS([ libkmod ], have_kmod=yes, have_kmod=no)
e2ca86cf78f911a8be51f0224796e24883019139Dave Reisner if test "x$have_kmod" = "xyes"; then
e30431623a7d871da123cc37055ac49abf2c20eaTom Gundersen PKG_CHECK_MODULES(KMOD, [ libkmod >= 15 ],
c4955740969d7ba8ba43b024bca1a0a5b56eb8e8Tom Gundersen [AC_DEFINE(HAVE_KMOD, 1, [Define if kmod is available])],
e30431623a7d871da123cc37055ac49abf2c20eaTom Gundersen AC_MSG_ERROR([*** kmod version >= 15 not found]))
e30431623a7d871da123cc37055ac49abf2c20eaTom Gundersen if test "x$have_kmod" = xno -a "x$enable_kmod" = xyes; then
f553b3b1074151200187df916427a1468186435eAnders Olofsson AC_MSG_ERROR([*** kmod support requested, but libraries not found])
d4f5a1f47dbd04f26f2ddf951c97c4cb0ebbbe62David HerrmannAM_CONDITIONAL(HAVE_KMOD, [test "$have_kmod" = "yes"])
d4f5a1f47dbd04f26f2ddf951c97c4cb0ebbbe62David Herrmann# ------------------------------------------------------------------------------
d4f5a1f47dbd04f26f2ddf951c97c4cb0ebbbe62David Herrmannhave_xkbcommon=no
d4f5a1f47dbd04f26f2ddf951c97c4cb0ebbbe62David HerrmannAC_ARG_ENABLE(xkbcommon, AS_HELP_STRING([--disable-xkbcommon], [disable xkbcommon keymap support]))
d4f5a1f47dbd04f26f2ddf951c97c4cb0ebbbe62David Herrmannif test "x$enable_xkbcommon" != "xno"; then
d4f5a1f47dbd04f26f2ddf951c97c4cb0ebbbe62David Herrmann PKG_CHECK_MODULES(XKBCOMMON, [ xkbcommon >= 0.3.0 ],
d4f5a1f47dbd04f26f2ddf951c97c4cb0ebbbe62David Herrmann [AC_DEFINE(HAVE_XKBCOMMON, 1, [Define if libxkbcommon is available]) have_xkbcommon=yes], have_xkbcommon=no)
d4f5a1f47dbd04f26f2ddf951c97c4cb0ebbbe62David Herrmann if test "x$have_xkbcommon" = xno -a "x$enable_xkbcommon" = xyes; then
d4f5a1f47dbd04f26f2ddf951c97c4cb0ebbbe62David Herrmann AC_MSG_ERROR([*** xkbcommon support requested but libraries not found])
f553b3b1074151200187df916427a1468186435eAnders OlofssonAM_CONDITIONAL(HAVE_XKBCOMMON, [test "$have_xkbcommon" = "yes"])
d47f6ca5f9b7a0b400d8bdb050151a0284fb4bdbGabriel de Perthuis# ------------------------------------------------------------------------------
f553b3b1074151200187df916427a1468186435eAnders OlofssonAC_ARG_ENABLE(blkid, AS_HELP_STRING([--disable-blkid], [disable blkid support]))
f553b3b1074151200187df916427a1468186435eAnders Olofssonif test "x$enable_blkid" != "xno"; then
f553b3b1074151200187df916427a1468186435eAnders Olofsson PKG_CHECK_MODULES(BLKID, [ blkid >= 2.24 ],
f553b3b1074151200187df916427a1468186435eAnders Olofsson [AC_DEFINE(HAVE_BLKID, 1, [Define if blkid is available]) have_blkid=yes], have_blkid=no)
f553b3b1074151200187df916427a1468186435eAnders Olofsson if test "x$have_blkid" = xno -a "x$enable_blkid" = xyes; then
728beb28a713709f521d374c9f8f3da781969d26Tom Gundersen AC_MSG_ERROR([*** blkid support requested but libraries not found])
8d3ae2bd4c9bf9fc2e57f7b3776325a1c750ca30Chris LeechAM_CONDITIONAL(HAVE_BLKID, [test "$have_blkid" = "yes"])
8d3ae2bd4c9bf9fc2e57f7b3776325a1c750ca30Chris Leech# ------------------------------------------------------------------------------
8d3ae2bd4c9bf9fc2e57f7b3776325a1c750ca30Chris Leechhave_libmount=no
8d3ae2bd4c9bf9fc2e57f7b3776325a1c750ca30Chris LeechPKG_CHECK_MODULES(MOUNT, [ mount >= 2.20 ],
8d3ae2bd4c9bf9fc2e57f7b3776325a1c750ca30Chris Leech [AC_DEFINE(HAVE_LIBMOUNT, 1, [Define if libmount is available]) have_libmount=yes], have_libmount=no)
8d3ae2bd4c9bf9fc2e57f7b3776325a1c750ca30Chris Leechif test "x$have_libmount" = xno; then
c0467cf387548dc98c0254f63553d862b35a84e5Ronny Chevalier AC_MSG_ERROR([*** libmount support required but libraries not found])
c0467cf387548dc98c0254f63553d862b35a84e5Ronny ChevalierAM_CONDITIONAL(HAVE_LIBMOUNT, [test "$have_libmount" = "yes"])
c0467cf387548dc98c0254f63553d862b35a84e5Ronny Chevalier# ------------------------------------------------------------------------------
17df7223be064b1542dbe868e3b35cca977ee639Lennart Poetteringhave_seccomp=no
17df7223be064b1542dbe868e3b35cca977ee639Lennart PoetteringAC_ARG_ENABLE(seccomp, AS_HELP_STRING([--disable-seccomp], [Disable optional SECCOMP support]))
17df7223be064b1542dbe868e3b35cca977ee639Lennart Poetteringif test "x$enable_seccomp" != "xno"; then
c0467cf387548dc98c0254f63553d862b35a84e5Ronny Chevalier PKG_CHECK_MODULES(SECCOMP, [libseccomp >= 1.0.0],
c0467cf387548dc98c0254f63553d862b35a84e5Ronny Chevalier [AC_DEFINE(HAVE_SECCOMP, 1, [Define if seccomp is available])
c0467cf387548dc98c0254f63553d862b35a84e5Ronny Chevalier have_seccomp=yes
c0467cf387548dc98c0254f63553d862b35a84e5Ronny Chevalier M4_DEFINES="$M4_DEFINES -DHAVE_SECCOMP"],
c0467cf387548dc98c0254f63553d862b35a84e5Ronny Chevalier [have_seccomp=no])
c0467cf387548dc98c0254f63553d862b35a84e5Ronny Chevalier if test "x$have_seccomp" = "xno" -a "x$enable_seccomp" = "xyes"; then
c0467cf387548dc98c0254f63553d862b35a84e5Ronny Chevalier AC_MSG_ERROR([*** seccomp support requested but libraries not found])
816115863962548a9a0d9fbfe429c7f8e685beacRoberto SassuAM_CONDITIONAL(HAVE_SECCOMP, [test "$have_seccomp" = "yes"])
816115863962548a9a0d9fbfe429c7f8e685beacRoberto Sassu# ------------------------------------------------------------------------------
816115863962548a9a0d9fbfe429c7f8e685beacRoberto SassuAC_ARG_ENABLE([ima], AS_HELP_STRING([--disable-ima],[Disable optional IMA support]),
816115863962548a9a0d9fbfe429c7f8e685beacRoberto Sassu [case "${enableval}" in
816115863962548a9a0d9fbfe429c7f8e685beacRoberto Sassu yes) have_ima=yes ;;
816115863962548a9a0d9fbfe429c7f8e685beacRoberto Sassu no) have_ima=no ;;
816115863962548a9a0d9fbfe429c7f8e685beacRoberto Sassu *) AC_MSG_ERROR(bad value ${enableval} for --disable-ima) ;;
816115863962548a9a0d9fbfe429c7f8e685beacRoberto Sassu [have_ima=yes])
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poetteringif test "x${have_ima}" != xno ; then
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poettering AC_DEFINE(HAVE_IMA, 1, [Define if IMA is available])
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poettering# ------------------------------------------------------------------------------
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poetteringhave_chkconfig=yes
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart PoetteringAC_ARG_ENABLE([chkconfig], AS_HELP_STRING([--disable-chkconfig],[Disable optional chkconfig support]),
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poettering [case "${enableval}" in
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poettering yes) have_chkconfig=yes ;;
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poettering no) have_chkconfig=no ;;
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poettering *) AC_MSG_ERROR(bad value ${enableval} for --disable-chkconfig) ;;
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poettering [AC_PATH_PROG(CHKCONFIG, chkconfig)
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poettering if test -z "$CHKCONFIG"; then
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poettering have_chkconfig=no
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poettering have_chkconfig=yes
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sieversif test "x${have_chkconfig}" != xno ; then
591622d7efbc828f00f190d91b6608148b967ff5Lennart Poettering AC_DEFINE(HAVE_CHKCONFIG, 1, [Define if CHKCONFIG is available])
3f8cc098d218525710e5cbad9adf37001d3b6060Jan Engelhardt# ------------------------------------------------------------------------------
6a6751fe24bf456cf5c1efad785a4d11e78b42d0Lennart Poetteringhave_selinux=no
6a6751fe24bf456cf5c1efad785a4d11e78b42d0Lennart PoetteringAC_ARG_ENABLE(selinux, AS_HELP_STRING([--disable-selinux], [Disable optional SELINUX support]))
6a6751fe24bf456cf5c1efad785a4d11e78b42d0Lennart Poetteringif test "x$enable_selinux" != "xno"; then
6a6751fe24bf456cf5c1efad785a4d11e78b42d0Lennart Poettering PKG_CHECK_MODULES([SELINUX], [libselinux >= 2.1.9],
591622d7efbc828f00f190d91b6608148b967ff5Lennart Poettering [AC_DEFINE(HAVE_SELINUX, 1, [Define if SELinux is available])
591622d7efbc828f00f190d91b6608148b967ff5Lennart Poettering have_selinux=yes
591622d7efbc828f00f190d91b6608148b967ff5Lennart Poettering M4_DEFINES="$M4_DEFINES -DHAVE_SELINUX"],
56cf987fe74270bde4e16c7ec9e0414a9030723bDaniel J Walsh [have_selinux=no])
591622d7efbc828f00f190d91b6608148b967ff5Lennart Poettering if test "x$have_selinux" = xno -a "x$enable_selinux" = xyes; then
45df1f2c9a7fee67b37f64ddd00adad5982844faCristian Rodríguez AC_MSG_ERROR([*** SELinux support requested but libraries not found])
eef65bf3ee6f73afa4a5de23ae3a794a279f30c0Michael SchererAM_CONDITIONAL(HAVE_SELINUX, [test "$have_selinux" = "yes"])
eef65bf3ee6f73afa4a5de23ae3a794a279f30c0Michael Schererhave_apparmor=no
eef65bf3ee6f73afa4a5de23ae3a794a279f30c0Michael SchererAC_ARG_ENABLE(apparmor, AS_HELP_STRING([--disable-apparmor], [Disable optional AppArmor support]))
eef65bf3ee6f73afa4a5de23ae3a794a279f30c0Michael Schererif test "x$enable_apparmor" != "xno"; then
eef65bf3ee6f73afa4a5de23ae3a794a279f30c0Michael Scherer PKG_CHECK_MODULES([APPARMOR], [libapparmor],
eef65bf3ee6f73afa4a5de23ae3a794a279f30c0Michael Scherer [AC_DEFINE(HAVE_APPARMOR, 1, [Define if AppArmor is available])
eef65bf3ee6f73afa4a5de23ae3a794a279f30c0Michael Scherer have_apparmor=yes
eef65bf3ee6f73afa4a5de23ae3a794a279f30c0Michael Scherer M4_DEFINES="$M4_DEFINES -DHAVE_APPARMOR"],
eef65bf3ee6f73afa4a5de23ae3a794a279f30c0Michael Scherer [have_apparmor=no])
eef65bf3ee6f73afa4a5de23ae3a794a279f30c0Michael Scherer if test "x$have_apparmor" = xno -a "x$enable_apparmor" = xyes; then
eef65bf3ee6f73afa4a5de23ae3a794a279f30c0Michael Scherer AC_MSG_ERROR([*** AppArmor support requested but libraries not found])
45df1f2c9a7fee67b37f64ddd00adad5982844faCristian RodríguezAM_CONDITIONAL(HAVE_APPARMOR, [test "$have_apparmor" = "yes"])
45df1f2c9a7fee67b37f64ddd00adad5982844faCristian RodríguezAC_ARG_WITH(debug-shell,
45df1f2c9a7fee67b37f64ddd00adad5982844faCristian Rodríguez AS_HELP_STRING([--with-debug-shell=PATH],
5ec6b15b65304d94dc1c8cbad05c8b996b470d3aKay Sievers [Path to debug shell binary]),
56cf987fe74270bde4e16c7ec9e0414a9030723bDaniel J Walsh [SUSHELL="$withval"],[
45df1f2c9a7fee67b37f64ddd00adad5982844faCristian Rodríguez AS_IF([test "x${have_selinux}" != "xno"], [SUSHELL="/sbin/sushell"] , [SUSHELL="/bin/sh"])])
45df1f2c9a7fee67b37f64ddd00adad5982844faCristian RodríguezAC_SUBST(SUSHELL)
45df1f2c9a7fee67b37f64ddd00adad5982844faCristian RodríguezAC_ARG_WITH([debug-tty],
45df1f2c9a7fee67b37f64ddd00adad5982844faCristian Rodríguez AS_HELP_STRING([--with-debug-tty=PATH],
45df1f2c9a7fee67b37f64ddd00adad5982844faCristian Rodríguez [Specify the tty device for debug shell]),
45df1f2c9a7fee67b37f64ddd00adad5982844faCristian Rodríguez [DEBUGTTY="$withval"],
ad95fd1d2b9c6344864857c2ba7634fd87753f8eZbigniew Jędrzejewski-SzmekAC_SUBST(DEBUGTTY)
ad95fd1d2b9c6344864857c2ba7634fd87753f8eZbigniew Jędrzejewski-SzmekAC_ARG_WITH([certificate-root],
ad95fd1d2b9c6344864857c2ba7634fd87753f8eZbigniew Jędrzejewski-Szmek AS_HELP_STRING([--with-certificate-root=PATH],
ad95fd1d2b9c6344864857c2ba7634fd87753f8eZbigniew Jędrzejewski-Szmek [Specify the prefix for TLS certificates [/etc/ssl]]),
ad95fd1d2b9c6344864857c2ba7634fd87753f8eZbigniew Jędrzejewski-Szmek [CERTIFICATEROOT="$withval"],
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers [CERTIFICATEROOT="/etc/ssl"])
807e17f05e217b474af39503efb9503d81b12596Lennart PoetteringAC_SUBST(CERTIFICATEROOT)
807e17f05e217b474af39503efb9503d81b12596Lennart Poettering# ------------------------------------------------------------------------------
807e17f05e217b474af39503efb9503d81b12596Lennart PoetteringAC_ARG_ENABLE(xz, AS_HELP_STRING([--disable-xz], [Disable optional XZ support]))
d89c8fdf48c7bad5816b9f2e77e8361721f22517Zbigniew Jędrzejewski-Szmekif test "x$enable_xz" != "xno"; then
807e17f05e217b474af39503efb9503d81b12596Lennart Poettering PKG_CHECK_MODULES(XZ, [ liblzma ],
807e17f05e217b474af39503efb9503d81b12596Lennart Poettering [AC_DEFINE(HAVE_XZ, 1, [Define if XZ is available]) have_xz=yes], have_xz=no)
807e17f05e217b474af39503efb9503d81b12596Lennart Poettering if test "x$have_xz" = xno -a "x$enable_xz" = xyes; then
807e17f05e217b474af39503efb9503d81b12596Lennart Poettering AC_MSG_ERROR([*** XZ support requested but libraries not found])
d89c8fdf48c7bad5816b9f2e77e8361721f22517Zbigniew Jędrzejewski-SzmekAM_CONDITIONAL(HAVE_XZ, [test "$have_xz" = "yes"])
d89c8fdf48c7bad5816b9f2e77e8361721f22517Zbigniew Jędrzejewski-Szmek# ------------------------------------------------------------------------------
d89c8fdf48c7bad5816b9f2e77e8361721f22517Zbigniew Jędrzejewski-SzmekAC_ARG_ENABLE(zlib, AS_HELP_STRING([--disable-zlib], [Disable optional ZLIB support]))
d89c8fdf48c7bad5816b9f2e77e8361721f22517Zbigniew Jędrzejewski-Szmekif test "x$enable_zlib" != "xno"; then
d89c8fdf48c7bad5816b9f2e77e8361721f22517Zbigniew Jędrzejewski-Szmek PKG_CHECK_MODULES(ZLIB, [ zlib ],
d89c8fdf48c7bad5816b9f2e77e8361721f22517Zbigniew Jędrzejewski-Szmek [AC_DEFINE(HAVE_ZLIB, 1, [Define if ZLIB is available]) have_zlib=yes], have_zlib=no)
3b1a55e110ab387a8d213581983e20c0a63d7894Zbigniew Jędrzejewski-Szmek if test "x$have_zlib" = xno -a "x$enable_zlib" = xyes; then
3b1a55e110ab387a8d213581983e20c0a63d7894Zbigniew Jędrzejewski-Szmek AC_MSG_ERROR([*** ZLIB support requested but libraries not found])
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart PoetteringAM_CONDITIONAL(HAVE_ZLIB, [test "$have_zlib" = "yes"])
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering# ------------------------------------------------------------------------------
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart PoetteringAC_ARG_ENABLE(bzip2, AS_HELP_STRING([--enable-bzip2], [Disable optional BZIP2 support]))
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart PoetteringAS_IF([test "x$enable_bzip2" != "xno"], [
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering AC_CHECK_HEADERS(bzlib.h,
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering [AC_DEFINE(HAVE_BZIP2, 1, [Define in BZIP2 is available])
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering have_bzip2=yes],
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering [AS_IF([test "x$have_bzip2" = xyes], [AC_MSG_ERROR([*** BZIP2 support requested but headers not found])])
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart PoetteringAM_CONDITIONAL(HAVE_BZIP2, [test "$have_bzip2" = "yes"])
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering# ------------------------------------------------------------------------------
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart PoetteringAC_ARG_ENABLE(lz4, AS_HELP_STRING([--enable-lz4], [Enable optional LZ4 support]))
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart PoetteringAS_IF([test "x$enable_lz4" = "xyes"], [
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering AC_CHECK_HEADERS(lz4.h,
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering [AC_DEFINE(HAVE_LZ4, 1, [Define in LZ4 is available]) have_lz4=yes],
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering [AC_MSG_ERROR([*** LZ4 support requested but headers not found])])
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart PoetteringAM_CONDITIONAL(HAVE_LZ4, [test "$have_lz4" = "yes"])
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart PoetteringAM_CONDITIONAL(HAVE_COMPRESSION, [test "$have_xz" = "yes" -o "$have_lz4" = "yes"])
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering# ------------------------------------------------------------------------------
6a6751fe24bf456cf5c1efad785a4d11e78b42d0Lennart PoetteringAC_ARG_ENABLE([pam],
812cce323db081634f37e4ec6d29f2b9328a3f52Lennart Poettering AS_HELP_STRING([--disable-pam],[Disable optional PAM support]),
812cce323db081634f37e4ec6d29f2b9328a3f52Lennart Poettering [case "${enableval}" in
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering yes) have_pam=yes ;;
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering no) have_pam=no ;;
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering *) AC_MSG_ERROR(bad value ${enableval} for --disable-pam) ;;
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering [have_pam=auto])
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poetteringif test "x${have_pam}" != xno ; then
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers AC_CHECK_HEADERS(
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering [security/pam_modules.h security/pam_modutil.h security/pam_ext.h],
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering [have_pam=yes],
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering [if test "x$have_pam" = xyes ; then
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering AC_MSG_ERROR([*** PAM headers not found.])
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering [have_pam=yes],
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering [if test "x$have_pam" = xyes ; then
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering AC_MSG_ERROR([*** libpam not found.])
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering if test "x$have_pam" = xyes ; then
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering PAM_LIBS="-lpam -lpam_misc"
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering AC_DEFINE(HAVE_PAM, 1, [PAM available])
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering M4_DEFINES="$M4_DEFINES -DHAVE_PAM"
5eda94dda25bccda928c4b33c790dbe748573a22Lennart PoetteringAC_SUBST(PAM_LIBS)
5eda94dda25bccda928c4b33c790dbe748573a22Lennart PoetteringAM_CONDITIONAL([HAVE_PAM], [test "x$have_pam" != xno])
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering# ------------------------------------------------------------------------------
5eda94dda25bccda928c4b33c790dbe748573a22Lennart PoetteringAC_ARG_ENABLE([acl],
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering AS_HELP_STRING([--disable-acl],[Disable optional ACL support]),
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering [case "${enableval}" in
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering yes) have_acl=yes ;;
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering no) have_acl=no ;;
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering *) AC_MSG_ERROR(bad value ${enableval} for --disable-acl) ;;
5eda94dda25bccda928c4b33c790dbe748573a22Lennart Poettering [have_acl=auto])
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowskiif test "x${have_acl}" != xno ; then
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski AC_CHECK_HEADERS(
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski [have_acl=yes],
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski [if test "x$have_acl" = xyes ; then
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski AC_MSG_ERROR([*** ACL headers not found.])
d2edfae0f9bdbecf6a8518e2a5bcf06f470e0d9eKay Sievers [acl_get_file],
d2edfae0f9bdbecf6a8518e2a5bcf06f470e0d9eKay Sievers [have_acl=yes],
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski [if test "x$have_acl" = xyes ; then
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski AC_MSG_ERROR([*** libacl not found.])
8b197c3a8a57c3f7c231b39e5660856fd9580c80Auke Kok if test "x$have_acl" = xyes ; then
8b197c3a8a57c3f7c231b39e5660856fd9580c80Auke Kok ACL_LIBS="-lacl"
8b197c3a8a57c3f7c231b39e5660856fd9580c80Auke Kok AC_DEFINE(HAVE_ACL, 1, [ACL available])
8b197c3a8a57c3f7c231b39e5660856fd9580c80Auke Kok M4_DEFINES="$M4_DEFINES -DHAVE_ACL"
7560fffcd2531786b9c1ca657667a43e90331326Lennart PoetteringAC_SUBST(ACL_LIBS)
feb12d3ed2c7f9132c64773c7c41b9e3a608a814Lennart PoetteringAM_CONDITIONAL([HAVE_ACL], [test "x$have_acl" != xno])
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering# ------------------------------------------------------------------------------
7560fffcd2531786b9c1ca657667a43e90331326Lennart PoetteringAC_ARG_ENABLE([smack], AS_HELP_STRING([--disable-smack],[Disable optional SMACK support]),
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering [case "${enableval}" in
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering yes) have_smack=yes ;;
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering no) have_smack=no ;;
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering *) AC_MSG_ERROR(bad value ${enableval} for --disable-smack) ;;
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering [have_smack=auto])
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poetteringif test "x${have_smack}" = xauto; then
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering M4_DEFINES="$M4_DEFINES -DHAVE_SMACK"
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering have_smack=yes
7560fffcd2531786b9c1ca657667a43e90331326Lennart PoetteringAC_ARG_WITH(smack-run-label,
7560fffcd2531786b9c1ca657667a43e90331326Lennart PoetteringAS_HELP_STRING([--with-smack-run-label=STRING],
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering [run systemd --system with a specific SMACK label]),
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering [AC_DEFINE_UNQUOTED(SMACK_RUN_LABEL, ["$withval"], [Run with a smack label])],
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poetteringif test "x${have_smack}" = xyes ; then
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering AC_DEFINE(HAVE_SMACK, 1, [Define if SMACK is available])
7560fffcd2531786b9c1ca657667a43e90331326Lennart PoetteringAM_CONDITIONAL([HAVE_SMACK], [test "x$have_smack" = "xyes"])
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering# ------------------------------------------------------------------------------
7560fffcd2531786b9c1ca657667a43e90331326Lennart PoetteringAC_ARG_ENABLE([gcrypt],
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering AS_HELP_STRING([--disable-gcrypt],[Disable optional GCRYPT support]),
7560fffcd2531786b9c1ca657667a43e90331326Lennart Poettering [case "${enableval}" in
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers yes) have_gcrypt=yes ;;
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering no) have_gcrypt=no ;;
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering *) AC_MSG_ERROR(bad value ${enableval} for --disable-gcrypt) ;;
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering [have_gcrypt=auto])
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poetteringif test "x${have_gcrypt}" != xno ; then
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering AM_PATH_LIBGCRYPT(
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering [have_gcrypt=yes],
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering [if test "x$have_gcrypt" = xyes ; then
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering AC_MSG_ERROR([*** GCRYPT headers not found.])
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering if test "x$have_gcrypt" = xyes ; then
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering GCRYPT_LIBS="$LIBGCRYPT_LIBS"
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering GCRYPT_CFLAGS="$LIBGCRYPT_CFLAGS"
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering AC_DEFINE(HAVE_GCRYPT, 1, [GCRYPT available])
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering have_gcrypt=no
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering GCRYPT_CFLAGS=
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart PoetteringAC_SUBST(GCRYPT_LIBS)
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart PoetteringAC_SUBST(GCRYPT_CFLAGS)
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart PoetteringAM_CONDITIONAL([HAVE_GCRYPT], [test "x$have_gcrypt" != xno])
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering# ------------------------------------------------------------------------------
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart PoetteringAC_ARG_ENABLE([audit],
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering AS_HELP_STRING([--disable-audit],[Disable optional AUDIT support]),
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering [case "${enableval}" in
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering yes) have_audit=yes ;;
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering no) have_audit=no ;;
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering *) AC_MSG_ERROR(bad value ${enableval} for --disable-audit) ;;
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering [have_audit=auto])
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poetteringif test "x${have_audit}" != xno ; then
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering AC_CHECK_HEADERS(
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering [have_audit=yes],
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering [if test "x$have_audit" = xyes ; then
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering AC_MSG_ERROR([*** AUDIT headers not found.])
972bded03215d4602fdd2ed2d680350c8eacb056Michael Marineau [have_audit=yes],
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering [if test "x$have_audit" = xyes ; then
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering AC_MSG_ERROR([*** libaudit not found.])
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering if test "x$have_audit" = xyes ; then
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering AUDIT_LIBS="-laudit"
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering AC_DEFINE(HAVE_AUDIT, 1, [AUDIT available])
972bded03215d4602fdd2ed2d680350c8eacb056Michael MarineauAC_SUBST(AUDIT_LIBS)
972bded03215d4602fdd2ed2d680350c8eacb056Michael Marineau# ------------------------------------------------------------------------------
972bded03215d4602fdd2ed2d680350c8eacb056Michael MarineauAC_ARG_ENABLE([elfutils],
972bded03215d4602fdd2ed2d680350c8eacb056Michael Marineau AS_HELP_STRING([--disable-elfutils],[Disable optional ELFUTILS support]),
972bded03215d4602fdd2ed2d680350c8eacb056Michael Marineau [case "${enableval}" in
972bded03215d4602fdd2ed2d680350c8eacb056Michael Marineau yes) have_elfutils=yes ;;
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering no) have_elfutils=no ;;
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering *) AC_MSG_ERROR(bad value ${enableval} for --disable-elfutils) ;;
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering [have_elfutils=auto])
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poetteringif test "x${have_elfutils}" != xno ; then
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering AC_CHECK_HEADERS(
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering [if test "x$have_elfutils" = xyes ; then
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering AC_MSG_ERROR([*** ELFUTILS headers not found.])
7f4e08056de0184b205a20632e62db73d299937eLennart Poettering [if test "x$have_elfutils" = xyes ; then
7f4e08056de0184b205a20632e62db73d299937eLennart Poettering AC_MSG_ERROR([*** ELFUTILS libs not found.])
7f4e08056de0184b205a20632e62db73d299937eLennart Poettering [dwfl_core_file_attach],
f6a971bc0bf1252e9614919ccca0d53db5fc53d9Lennart Poettering [have_elfutils=yes],
f6a971bc0bf1252e9614919ccca0d53db5fc53d9Lennart Poettering [if test "x$have_elfutils" = xyes ; then
f6a971bc0bf1252e9614919ccca0d53db5fc53d9Lennart Poettering AC_MSG_ERROR([*** ELFUTILS >= 158 is required.])
f6a971bc0bf1252e9614919ccca0d53db5fc53d9Lennart Poettering if test "x$have_elfutils" = xyes ; then
f6a971bc0bf1252e9614919ccca0d53db5fc53d9Lennart Poettering ELFUTILS_LIBS="-lelf -ldw"
f6a971bc0bf1252e9614919ccca0d53db5fc53d9Lennart Poettering AC_DEFINE(HAVE_ELFUTILS, 1, [ELFUTILS available])
f6a971bc0bf1252e9614919ccca0d53db5fc53d9Lennart Poettering have_elfutils=no
7b17a7d72f5ba5ad838b19803534c56a46f3bce9Lennart Poettering ELFUTILS_LIBS=
7b17a7d72f5ba5ad838b19803534c56a46f3bce9Lennart PoetteringAC_SUBST(ELFUTILS_LIBS)
7b17a7d72f5ba5ad838b19803534c56a46f3bce9Lennart PoetteringAM_CONDITIONAL(HAVE_ELFUTILS, [test "$have_elfutils" = "yes"])
7b17a7d72f5ba5ad838b19803534c56a46f3bce9Lennart Poettering# ------------------------------------------------------------------------------
7b17a7d72f5ba5ad838b19803534c56a46f3bce9Lennart Poetteringhave_libcryptsetup=no
7b17a7d72f5ba5ad838b19803534c56a46f3bce9Lennart PoetteringAC_ARG_ENABLE(libcryptsetup, AS_HELP_STRING([--disable-libcryptsetup], [disable libcryptsetup tools]))
7b17a7d72f5ba5ad838b19803534c56a46f3bce9Lennart Poetteringif test "x$enable_libcryptsetup" != "xno"; then
7b17a7d72f5ba5ad838b19803534c56a46f3bce9Lennart Poettering PKG_CHECK_MODULES(LIBCRYPTSETUP, [ libcryptsetup >= 1.6.0 ],
7b17a7d72f5ba5ad838b19803534c56a46f3bce9Lennart Poettering [AC_DEFINE(HAVE_LIBCRYPTSETUP, 1, [Define if libcryptsetup is available]) have_libcryptsetup=yes], have_libcryptsetup=no)
7b17a7d72f5ba5ad838b19803534c56a46f3bce9Lennart Poettering if test "x$have_libcryptsetup" = xno -a "x$enable_libcryptsetup" = xyes; then
6031319956b4b1d13799373bfda3e8690f6fa874Zbigniew Jędrzejewski-Szmek AC_MSG_ERROR([*** libcryptsetup support requested but libraries not found])
6031319956b4b1d13799373bfda3e8690f6fa874Zbigniew Jędrzejewski-SzmekAM_CONDITIONAL(HAVE_LIBCRYPTSETUP, [test "$have_libcryptsetup" = "yes"])
6031319956b4b1d13799373bfda3e8690f6fa874Zbigniew Jędrzejewski-Szmek# ------------------------------------------------------------------------------
6031319956b4b1d13799373bfda3e8690f6fa874Zbigniew Jędrzejewski-SzmekAC_ARG_ENABLE(qrencode, AS_HELP_STRING([--disable-qrencode], [disable qrencode support]))
6031319956b4b1d13799373bfda3e8690f6fa874Zbigniew Jędrzejewski-Szmekif test "x$enable_qrencode" != "xno"; then
6031319956b4b1d13799373bfda3e8690f6fa874Zbigniew Jędrzejewski-Szmek PKG_CHECK_MODULES(QRENCODE, [ libqrencode ],
6031319956b4b1d13799373bfda3e8690f6fa874Zbigniew Jędrzejewski-Szmek [AC_DEFINE(HAVE_QRENCODE, 1, [Define if qrencode is available]) have_qrencode=yes], have_qrencode=no)
6031319956b4b1d13799373bfda3e8690f6fa874Zbigniew Jędrzejewski-Szmek if test "x$have_qrencode" = xno -a "x$enable_qrencode" = xyes; then
36ef43edcf1c9640b3fda017b381c4b1854641f4Zbigniew Jędrzejewski-Szmek AC_MSG_ERROR([*** qrencode support requested but libraries not found])
36ef43edcf1c9640b3fda017b381c4b1854641f4Zbigniew Jędrzejewski-SzmekAM_CONDITIONAL(HAVE_QRENCODE, [test "$have_qrencode" = "yes"])
36ef43edcf1c9640b3fda017b381c4b1854641f4Zbigniew Jędrzejewski-Szmek# ------------------------------------------------------------------------------
36ef43edcf1c9640b3fda017b381c4b1854641f4Zbigniew Jędrzejewski-Szmekhave_microhttpd=no
36ef43edcf1c9640b3fda017b381c4b1854641f4Zbigniew Jędrzejewski-SzmekAC_ARG_ENABLE(microhttpd, AS_HELP_STRING([--disable-microhttpd], [disable microhttpd support]))
36ef43edcf1c9640b3fda017b381c4b1854641f4Zbigniew Jędrzejewski-Szmekif test "x$enable_microhttpd" != "xno"; then
36ef43edcf1c9640b3fda017b381c4b1854641f4Zbigniew Jędrzejewski-Szmek PKG_CHECK_MODULES(MICROHTTPD, [libmicrohttpd >= 0.9.33],
36ef43edcf1c9640b3fda017b381c4b1854641f4Zbigniew Jędrzejewski-Szmek [AC_DEFINE(HAVE_MICROHTTPD, 1, [Define if microhttpd is available]) have_microhttpd=yes], have_microhttpd=no)
36ef43edcf1c9640b3fda017b381c4b1854641f4Zbigniew Jędrzejewski-Szmek if test "x$have_microhttpd" = xno -a "x$enable_microhttpd" = xyes; then
bdf10b5b4d9e7abdc08bdca4b073d021b0043d1fLennart Poettering AC_MSG_ERROR([*** microhttpd support requested but libraries not found])
bdf10b5b4d9e7abdc08bdca4b073d021b0043d1fLennart PoetteringAM_CONDITIONAL(HAVE_MICROHTTPD, [test "$have_microhttpd" = "yes"])
bdf10b5b4d9e7abdc08bdca4b073d021b0043d1fLennart Poettering# ------------------------------------------------------------------------------
bdf10b5b4d9e7abdc08bdca4b073d021b0043d1fLennart PoetteringAC_ARG_ENABLE(gnutls, AS_HELP_STRING([--disable-gnutls], [disable gnutls support]))
bdf10b5b4d9e7abdc08bdca4b073d021b0043d1fLennart Poetteringif test "x$enable_gnutls" != "xno"; then
bdf10b5b4d9e7abdc08bdca4b073d021b0043d1fLennart Poettering PKG_CHECK_MODULES(GNUTLS, [gnutls >= 3.1.4],
bdf10b5b4d9e7abdc08bdca4b073d021b0043d1fLennart Poettering [AC_DEFINE(HAVE_GNUTLS, 1, [Define if gnutls is available]) have_gnutls=yes], have_gnutls=no)
bdf10b5b4d9e7abdc08bdca4b073d021b0043d1fLennart Poettering if test "x$have_gnutls" = xno -a "x$enable_gnutls" = xyes; then
bdf10b5b4d9e7abdc08bdca4b073d021b0043d1fLennart Poettering AC_MSG_ERROR([*** gnutls support requested but libraries not found])
3e2147858f21943d5f4a781c60f33ac22c6096edKay SieversAM_CONDITIONAL(HAVE_GNUTLS, [test "$have_gnutls" = "yes"])
27669061f40766457db93d5cc3dfe00dce240806Miklos Vajna# ------------------------------------------------------------------------------
27669061f40766457db93d5cc3dfe00dce240806Miklos Vajnahave_libcurl=no
be31376e6c9add0786f31a38eec2ecfdb73eb115Kay SieversAC_ARG_ENABLE(libcurl, AS_HELP_STRING([--disable-libcurl], [disable libcurl support]))
27669061f40766457db93d5cc3dfe00dce240806Miklos Vajnaif test "x$enable_libcurl" != "xno"; then
27669061f40766457db93d5cc3dfe00dce240806Miklos Vajna PKG_CHECK_MODULES(LIBCURL, [libcurl],
27669061f40766457db93d5cc3dfe00dce240806Miklos Vajna [AC_DEFINE(HAVE_LIBCURL, 1, [Define if libcurl is available]) have_libcurl=yes], have_libcurl=no)
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers if test "x$have_libcurl" = xno -a "x$enable_libcurl" = xyes; then
e5e83e8362e946890ac991fc86a2c5869f9befdfLennart Poettering AC_MSG_ERROR([*** libcurl support requested but libraries not found])
be31376e6c9add0786f31a38eec2ecfdb73eb115Kay SieversAM_CONDITIONAL(HAVE_LIBCURL, [test "$have_libcurl" = "yes"])
e5e83e8362e946890ac991fc86a2c5869f9befdfLennart Poettering# ------------------------------------------------------------------------------
83fdc450aa8f79941bec84488ffd5bf8eadab18eAuke KokAC_ARG_ENABLE(libidn, AS_HELP_STRING([--disable-libidn], [Disable optional LIBIDN support]))
83fdc450aa8f79941bec84488ffd5bf8eadab18eAuke Kokif test "x$enable_libidn" != "xno"; then
83fdc450aa8f79941bec84488ffd5bf8eadab18eAuke Kok PKG_CHECK_MODULES(LIBIDN, [libidn],
83fdc450aa8f79941bec84488ffd5bf8eadab18eAuke Kok [AC_DEFINE(HAVE_LIBIDN, 1, [Define if libidn is available])
83fdc450aa8f79941bec84488ffd5bf8eadab18eAuke Kok have_libidn=yes
83fdc450aa8f79941bec84488ffd5bf8eadab18eAuke Kok M4_DEFINES="$M4_DEFINES -DHAVE_LIBIDN"],
83fdc450aa8f79941bec84488ffd5bf8eadab18eAuke Kok [have_libidn=no])
83fdc450aa8f79941bec84488ffd5bf8eadab18eAuke Kok if test "x$have_libidn" = "xno" -a "x$enable_libidn" = "xyes"; then
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers AC_MSG_ERROR([*** libidn support requested but libraries not found])
4de856120f252e7aa19c923c10fbf23310d623aaLennart PoetteringAM_CONDITIONAL(HAVE_LIBIDN, [test "$have_libidn" = "yes"])
4de856120f252e7aa19c923c10fbf23310d623aaLennart Poettering# ------------------------------------------------------------------------------
4de856120f252e7aa19c923c10fbf23310d623aaLennart Poetteringhave_libiptc=no
4de856120f252e7aa19c923c10fbf23310d623aaLennart PoetteringAC_ARG_ENABLE(libiptc, AS_HELP_STRING([--disable-libiptc], [Disable optional LIBIPTC support]))
6351163bf3e519cc07adb2732d12450741f5a0d3Umut Tezduyarif test "x$enable_libiptc" != "xno"; then
6351163bf3e519cc07adb2732d12450741f5a0d3Umut Tezduyar PKG_CHECK_MODULES(LIBIPTC, [libiptc],
6351163bf3e519cc07adb2732d12450741f5a0d3Umut Tezduyar [AC_DEFINE(HAVE_LIBIPTC, 1, [Define if libiptc is available])
6351163bf3e519cc07adb2732d12450741f5a0d3Umut Tezduyar have_libiptc=yes
6351163bf3e519cc07adb2732d12450741f5a0d3Umut Tezduyar M4_DEFINES="$M4_DEFINES -DHAVE_LIBIPTC"],
6351163bf3e519cc07adb2732d12450741f5a0d3Umut Tezduyar [have_libiptc=no])
6351163bf3e519cc07adb2732d12450741f5a0d3Umut Tezduyar if test "x$have_libiptc" = "xno" -a "x$enable_libiptc" = "xyes"; then
6351163bf3e519cc07adb2732d12450741f5a0d3Umut Tezduyar AC_MSG_ERROR([*** libiptc support requested but libraries not found])
1b99214789101976d6bbf75c351279584b071998Lennart PoetteringAM_CONDITIONAL(HAVE_LIBIPTC, [test "$have_libiptc" = "yes"])
1b99214789101976d6bbf75c351279584b071998Lennart Poettering# ------------------------------------------------------------------------------
1b99214789101976d6bbf75c351279584b071998Lennart PoetteringAC_ARG_ENABLE(binfmt, AS_HELP_STRING([--disable-binfmt], [disable binfmt tool]))
1b99214789101976d6bbf75c351279584b071998Lennart Poetteringif test "x$enable_binfmt" != "xno"; then
418b9be50018303cde79b423d4701b7fd86ddbdcLennart Poettering have_binfmt=yes
418b9be50018303cde79b423d4701b7fd86ddbdcLennart PoetteringAM_CONDITIONAL(ENABLE_BINFMT, [test "$have_binfmt" = "yes"])
418b9be50018303cde79b423d4701b7fd86ddbdcLennart Poettering# ------------------------------------------------------------------------------
418b9be50018303cde79b423d4701b7fd86ddbdcLennart Poetteringhave_vconsole=no
418b9be50018303cde79b423d4701b7fd86ddbdcLennart PoetteringAC_ARG_ENABLE(vconsole, AS_HELP_STRING([--disable-vconsole], [disable vconsole tool]))
418b9be50018303cde79b423d4701b7fd86ddbdcLennart Poetteringif test "x$enable_vconsole" != "xno"; then
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers have_vconsole=yes
4de856120f252e7aa19c923c10fbf23310d623aaLennart PoetteringAM_CONDITIONAL(ENABLE_VCONSOLE, [test "$have_vconsole" = "yes"])
be31376e6c9add0786f31a38eec2ecfdb73eb115Kay Sievers# ------------------------------------------------------------------------------
4de856120f252e7aa19c923c10fbf23310d623aaLennart Poetteringhave_bootchart=no
4de856120f252e7aa19c923c10fbf23310d623aaLennart PoetteringAC_ARG_ENABLE(bootchart, AS_HELP_STRING([--disable-bootchart], [disable bootchart tool]))
4de856120f252e7aa19c923c10fbf23310d623aaLennart Poetteringif test "x$enable_bootchart" != "xno"; then
3731acf1acfb4a6eb68374a5b137f3b368f63381Lennart Poettering have_bootchart=yes
3731acf1acfb4a6eb68374a5b137f3b368f63381Lennart PoetteringAM_CONDITIONAL(ENABLE_BOOTCHART, [test "$have_bootchart" = "yes"])
3731acf1acfb4a6eb68374a5b137f3b368f63381Lennart Poettering# ------------------------------------------------------------------------------
3731acf1acfb4a6eb68374a5b137f3b368f63381Lennart Poetteringhave_quotacheck=no
3731acf1acfb4a6eb68374a5b137f3b368f63381Lennart PoetteringAC_ARG_ENABLE(quotacheck, AS_HELP_STRING([--disable-quotacheck], [disable quotacheck tools]))
3731acf1acfb4a6eb68374a5b137f3b368f63381Lennart Poetteringif test "x$enable_quotacheck" != "xno"; then
3990f247652c3bd41e4ea074e6302277eb9c7aa3Lennart Poettering have_quotacheck=yes
3990f247652c3bd41e4ea074e6302277eb9c7aa3Lennart PoetteringAM_CONDITIONAL(ENABLE_QUOTACHECK, [test "$have_quotacheck" = "yes"])
3990f247652c3bd41e4ea074e6302277eb9c7aa3Lennart Poettering# ------------------------------------------------------------------------------
3990f247652c3bd41e4ea074e6302277eb9c7aa3Lennart Poetteringhave_tmpfiles=no
3990f247652c3bd41e4ea074e6302277eb9c7aa3Lennart PoetteringAC_ARG_ENABLE(tmpfiles, AS_HELP_STRING([--disable-tmpfiles], [disable tmpfiles support]))
3990f247652c3bd41e4ea074e6302277eb9c7aa3Lennart Poetteringif test "x$enable_tmpfiles" != "xno"; then
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers have_tmpfiles=yes
2a018e83ded29c9719b2478a65ee6245c829c0f5Kay SieversAM_CONDITIONAL(ENABLE_TMPFILES, [test "$have_tmpfiles" = "yes"])
be31376e6c9add0786f31a38eec2ecfdb73eb115Kay Sievers# ------------------------------------------------------------------------------
2a018e83ded29c9719b2478a65ee6245c829c0f5Kay Sievershave_sysusers=no
2a018e83ded29c9719b2478a65ee6245c829c0f5Kay SieversAC_ARG_ENABLE(sysusers, AS_HELP_STRING([--disable-sysusers], [disable sysusers support]))
4c80c73c2b804576b1de27e644c1da4dab2f9026Kay Sieversif test "x$enable_sysusers" != "xno"; then
2a018e83ded29c9719b2478a65ee6245c829c0f5Kay Sievers have_sysusers=yes
1ee306e1248866617c96ed9f4263f375588ad838Lennart PoetteringAM_CONDITIONAL(ENABLE_SYSUSERS, [test "$have_sysusers" = "yes"])
1ee306e1248866617c96ed9f4263f375588ad838Lennart Poettering# ------------------------------------------------------------------------------
1ee306e1248866617c96ed9f4263f375588ad838Lennart Poetteringhave_firstboot=no
1ee306e1248866617c96ed9f4263f375588ad838Lennart PoetteringAC_ARG_ENABLE(firstboot, AS_HELP_STRING([--disable-firstboot], [disable firstboot support]))
1ee306e1248866617c96ed9f4263f375588ad838Lennart Poetteringif test "x$enable_firstboot" != "xno"; then
1ee306e1248866617c96ed9f4263f375588ad838Lennart Poettering have_firstboot=yes
3e2147858f21943d5f4a781c60f33ac22c6096edKay SieversAM_CONDITIONAL(ENABLE_FIRSTBOOT, [test "$have_firstboot" = "yes"])
b2e9fb99ab288e8817302851743ed1a3cddd384bMiklos Vajna# ------------------------------------------------------------------------------
b2e9fb99ab288e8817302851743ed1a3cddd384bMiklos Vajnahave_randomseed=no
be31376e6c9add0786f31a38eec2ecfdb73eb115Kay SieversAC_ARG_ENABLE(randomseed, AS_HELP_STRING([--disable-randomseed], [disable randomseed tools]))
b2e9fb99ab288e8817302851743ed1a3cddd384bMiklos Vajnaif test "x$enable_randomseed" != "xno"; then
b2e9fb99ab288e8817302851743ed1a3cddd384bMiklos Vajna have_randomseed=yes
3e2147858f21943d5f4a781c60f33ac22c6096edKay SieversAM_CONDITIONAL(ENABLE_RANDOMSEED, [test "$have_randomseed" = "yes"])
f47cd184c0ff80e025428e9e385e61bda1ef3d69Miklos Vajna# ------------------------------------------------------------------------------
f47cd184c0ff80e025428e9e385e61bda1ef3d69Miklos Vajnahave_backlight=no
be31376e6c9add0786f31a38eec2ecfdb73eb115Kay SieversAC_ARG_ENABLE(backlight, AS_HELP_STRING([--disable-backlight], [disable backlight tools]))
f47cd184c0ff80e025428e9e385e61bda1ef3d69Miklos Vajnaif test "x$enable_backlight" != "xno"; then
f47cd184c0ff80e025428e9e385e61bda1ef3d69Miklos Vajna have_backlight=yes
3e2147858f21943d5f4a781c60f33ac22c6096edKay SieversAM_CONDITIONAL(ENABLE_BACKLIGHT, [test "$have_backlight" = "yes"])
687ed1237b20a6db174fd0b372df20fa9a3a23c2Kay Sievers# ------------------------------------------------------------------------------
687ed1237b20a6db174fd0b372df20fa9a3a23c2Kay SieversAC_ARG_ENABLE(rfkill, AS_HELP_STRING([--disable-rfkill], [disable rfkill tools]))
5a16bc264c32237e38a844d55e7a1820a31b8440Łukasz Stelmachif test "x$enable_rfkill" != "xno"; then
687ed1237b20a6db174fd0b372df20fa9a3a23c2Kay Sievers have_rfkill=yes
687ed1237b20a6db174fd0b372df20fa9a3a23c2Kay SieversAM_CONDITIONAL(ENABLE_RFKILL, [test "$have_rfkill" = "yes"])
e8af69739a629708d2c155ebcd4fa57b8fd5006aLennart Poettering# ------------------------------------------------------------------------------
e8af69739a629708d2c155ebcd4fa57b8fd5006aLennart PoetteringAC_ARG_ENABLE(logind, AS_HELP_STRING([--disable-logind], [disable login daemon]))
e8af69739a629708d2c155ebcd4fa57b8fd5006aLennart Poetteringif test "x$enable_logind" != "xno"; then
e8af69739a629708d2c155ebcd4fa57b8fd5006aLennart Poettering have_logind=yes
e8af69739a629708d2c155ebcd4fa57b8fd5006aLennart PoetteringAM_CONDITIONAL(ENABLE_LOGIND, [test "$have_logind" = "yes"])
e8af69739a629708d2c155ebcd4fa57b8fd5006aLennart PoetteringAS_IF([test "$have_logind" = "yes"], [ AC_DEFINE(HAVE_LOGIND, [1], [Logind support available]) ])
661278ee297247c0c7e0708924f8ce52284529fcLennart Poettering# ------------------------------------------------------------------------------
661278ee297247c0c7e0708924f8ce52284529fcLennart PoetteringAC_ARG_ENABLE(machined, AS_HELP_STRING([--disable-machined], [disable machine daemon]))
661278ee297247c0c7e0708924f8ce52284529fcLennart Poetteringif test "x$enable_machined" != "xno"; then
661278ee297247c0c7e0708924f8ce52284529fcLennart Poettering have_machined=yes
661278ee297247c0c7e0708924f8ce52284529fcLennart PoetteringAM_CONDITIONAL(ENABLE_MACHINED, [test "$have_machined" = "yes"])
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart PoetteringAS_IF([test "$have_machined" = "yes"], [ AC_DEFINE(HAVE_MACHINED, [1], [Machined support available]) ])
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart Poettering# ------------------------------------------------------------------------------
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart Poetteringhave_importd=no
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart PoetteringAC_ARG_ENABLE(importd, AS_HELP_STRING([--disable-importd], [disable import daemon]))
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart Poetteringif test "x$enable_importd" != "xno"; then
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart Poettering have_importd=yes
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart PoetteringAM_CONDITIONAL(ENABLE_IMPORTD, [test "$have_importd" = "yes"])
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart PoetteringAS_IF([test "$have_importd" = "yes"], [ AC_DEFINE(HAVE_IMPORTD, [1], [Importd support available]) ])
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart Poettering# ------------------------------------------------------------------------------
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart Poetteringhave_hostnamed=no
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart PoetteringAC_ARG_ENABLE(hostnamed, AS_HELP_STRING([--disable-hostnamed], [disable hostname daemon]))
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart Poetteringif test "x$enable_hostnamed" != "xno"; then
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart Poettering have_hostnamed=yes
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart PoetteringAM_CONDITIONAL(ENABLE_HOSTNAMED, [test "$have_hostnamed" = "yes"])
f7dc3ab9f43b67abcbd34062b9352ab42debec49Lennart Poettering# ------------------------------------------------------------------------------
687ed1237b20a6db174fd0b372df20fa9a3a23c2Kay Sievershave_timedated=no
4cd1eaa54507a65286413363216ad407fa7c6e50Miklos VajnaAC_ARG_ENABLE(timedated, AS_HELP_STRING([--disable-timedated], [disable timedate daemon]))
4cd1eaa54507a65286413363216ad407fa7c6e50Miklos Vajnaif test "x$enable_timedated" != "xno"; then
4cd1eaa54507a65286413363216ad407fa7c6e50Miklos Vajna have_timedated=yes
4cd1eaa54507a65286413363216ad407fa7c6e50Miklos VajnaAM_CONDITIONAL(ENABLE_TIMEDATED, [test "$have_timedated" = "yes"])
4cd1eaa54507a65286413363216ad407fa7c6e50Miklos Vajna# ------------------------------------------------------------------------------
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievershave_timesyncd=no
f5e04665ebf7124f3ea17dcf258793ed73a95fe1Lennart PoetteringAC_ARG_ENABLE(timesyncd, AS_HELP_STRING([--disable-timesyncd], [disable timesync daemon]))
f5e04665ebf7124f3ea17dcf258793ed73a95fe1Lennart Poetteringif test "x$enable_timesyncd" != "xno"; then
f5e04665ebf7124f3ea17dcf258793ed73a95fe1Lennart Poettering have_timesyncd=yes
be31376e6c9add0786f31a38eec2ecfdb73eb115Kay Sievers M4_DEFINES="$M4_DEFINES -DENABLE_TIMESYNCD"
f5e04665ebf7124f3ea17dcf258793ed73a95fe1Lennart PoetteringAM_CONDITIONAL(ENABLE_TIMESYNCD, [test "$have_timesyncd" = "yes"])
46ba8aae2b82bc5c87ba347e6bf914ecd5e9d51eLennart PoetteringAC_ARG_WITH(ntp-servers,
46ba8aae2b82bc5c87ba347e6bf914ecd5e9d51eLennart Poettering AS_HELP_STRING([--with-ntp-servers=NTPSERVERS],
46ba8aae2b82bc5c87ba347e6bf914ecd5e9d51eLennart Poettering [Space-separated list of default NTP servers]),
46ba8aae2b82bc5c87ba347e6bf914ecd5e9d51eLennart Poettering [NTP_SERVERS="$withval"],
46ba8aae2b82bc5c87ba347e6bf914ecd5e9d51eLennart Poettering [NTP_SERVERS="time1.google.com time2.google.com time3.google.com time4.google.com"])
46ba8aae2b82bc5c87ba347e6bf914ecd5e9d51eLennart PoetteringAC_DEFINE_UNQUOTED(NTP_SERVERS, ["$NTP_SERVERS"], [Default NTP Servers])
46ba8aae2b82bc5c87ba347e6bf914ecd5e9d51eLennart PoetteringAC_SUBST(NTP_SERVERS)
3c9317d2d93248f3f0b0feaaa113485aee415d8aColin WaltersAC_ARG_WITH(time-epoch,
091a364c802e34a58f3260c9cb5db9b75c62215cTom Gundersen AS_HELP_STRING([--with-time-epoch=SECONDS],
091a364c802e34a58f3260c9cb5db9b75c62215cTom Gundersen [Time epoch for time clients]),
091a364c802e34a58f3260c9cb5db9b75c62215cTom Gundersen [TIME_EPOCH="$withval"],
091a364c802e34a58f3260c9cb5db9b75c62215cTom Gundersen [TIME_EPOCH="`stat -c %Y ${srcdir}/NEWS 2>/dev/null || echo 0`"])
3c9317d2d93248f3f0b0feaaa113485aee415d8aColin WaltersAC_DEFINE_UNQUOTED(TIME_EPOCH, [$TIME_EPOCH], [Time Epoch])
3c9317d2d93248f3f0b0feaaa113485aee415d8aColin Walters# ------------------------------------------------------------------------------
e16cb2e4efaba83f47da8355adc65fd83bbe8327Tom GundersenAC_ARG_WITH(system-uid-max,
e16cb2e4efaba83f47da8355adc65fd83bbe8327Tom Gundersen AS_HELP_STRING([--with-system-uid-max=UID]
e16cb2e4efaba83f47da8355adc65fd83bbe8327Tom Gundersen [Maximum UID for system users]),
49e5c2b26aa72a7aa117c1e04763852a4b69136bZbigniew Jędrzejewski-Szmek [SYSTEM_UID_MAX="$withval"],
7b4d79683998a78d6e123dd034b1e06b74d8030bTom Gundersen [SYSTEM_UID_MAX="`awk 'BEGIN { uid=999 } /^\s*SYS_UID_MAX\s+/ { uid=$2 } END { print uid }' /etc/login.defs 2>/dev/null || echo 999`"])
e16cb2e4efaba83f47da8355adc65fd83bbe8327Tom GundersenAC_DEFINE_UNQUOTED(SYSTEM_UID_MAX, [$SYSTEM_UID_MAX], [Maximum System UID])
e16cb2e4efaba83f47da8355adc65fd83bbe8327Tom GundersenAC_SUBST(SYSTEM_UID_MAX)
091a364c802e34a58f3260c9cb5db9b75c62215cTom Gundersen# ------------------------------------------------------------------------------
091a364c802e34a58f3260c9cb5db9b75c62215cTom GundersenAC_ARG_WITH(system-gid-max,
091a364c802e34a58f3260c9cb5db9b75c62215cTom Gundersen AS_HELP_STRING([--with-system-gid-max=GID]
81577dc22887debaf9b19bf1034a2887fb9069c7Zbigniew Jędrzejewski-Szmek [Maximum GID for system groups]),
091a364c802e34a58f3260c9cb5db9b75c62215cTom Gundersen [SYSTEM_GID_MAX="$withval"],
091a364c802e34a58f3260c9cb5db9b75c62215cTom Gundersen [SYSTEM_GID_MAX="`awk 'BEGIN { gid=999 } /^\s*SYS_GID_MAX\s+/ { gid=$2 } END { print gid }' /etc/login.defs 2>/dev/null || echo 999`"])
81577dc22887debaf9b19bf1034a2887fb9069c7Zbigniew Jędrzejewski-SzmekAC_DEFINE_UNQUOTED(SYSTEM_GID_MAX, [$SYSTEM_GID_MAX], [Maximum System GID])
091a364c802e34a58f3260c9cb5db9b75c62215cTom GundersenAC_SUBST(SYSTEM_GID_MAX)
b872e9a05939bc3e0ac95a042592506a7488dd6fLennart Poettering# ------------------------------------------------------------------------------
b872e9a05939bc3e0ac95a042592506a7488dd6fLennart Poetteringhave_localed=no
b872e9a05939bc3e0ac95a042592506a7488dd6fLennart PoetteringAC_ARG_ENABLE(localed, AS_HELP_STRING([--disable-localed], [disable locale daemon]))
b872e9a05939bc3e0ac95a042592506a7488dd6fLennart Poetteringif test "x$enable_localed" != "xno"; then
b872e9a05939bc3e0ac95a042592506a7488dd6fLennart Poettering have_localed=yes
b872e9a05939bc3e0ac95a042592506a7488dd6fLennart PoetteringAM_CONDITIONAL(ENABLE_LOCALED, [test "$have_localed" = "yes"])
b872e9a05939bc3e0ac95a042592506a7488dd6fLennart Poettering# ------------------------------------------------------------------------------
84da4a3022bc599b26d9601cf1b7bf51d1d9f915David Herrmannhave_coredump=no
84da4a3022bc599b26d9601cf1b7bf51d1d9f915David HerrmannAC_ARG_ENABLE(coredump, AS_HELP_STRING([--disable-coredump], [disable coredump hook]))
84da4a3022bc599b26d9601cf1b7bf51d1d9f915David Herrmannif test "x$enable_coredump" != "xno"; then
84da4a3022bc599b26d9601cf1b7bf51d1d9f915David Herrmann have_coredump=yes
c93e5a62ff599528c3bf2a8656825403aaebe093David HerrmannAM_CONDITIONAL(ENABLE_COREDUMP, [test "$have_coredump" = "yes"])
c93e5a62ff599528c3bf2a8656825403aaebe093David Herrmann# ------------------------------------------------------------------------------
c93e5a62ff599528c3bf2a8656825403aaebe093David Herrmannhave_polkit=no
84da4a3022bc599b26d9601cf1b7bf51d1d9f915David HerrmannAC_ARG_ENABLE(polkit, AS_HELP_STRING([--disable-polkit], [disable PolicyKit support]))
84da4a3022bc599b26d9601cf1b7bf51d1d9f915David Herrmannif test "x$enable_polkit" != "xno"; then
84da4a3022bc599b26d9601cf1b7bf51d1d9f915David Herrmann AC_DEFINE(ENABLE_POLKIT, 1, [Define if PolicyKit support is to be enabled])
626851be97b4332fc0401d754c81ae7bbc0f5dc4Lennart Poettering have_polkit=yes
c97a6dbcf10990bcc2455e842a41bf14b01f358dLukasz SkalskiAM_CONDITIONAL(ENABLE_POLKIT, [test "x$have_polkit" = "xyes"])
626851be97b4332fc0401d754c81ae7bbc0f5dc4Lennart Poettering# ------------------------------------------------------------------------------
626851be97b4332fc0401d754c81ae7bbc0f5dc4Lennart Poetteringhave_resolved=no
4acbce79798347cddf1e1d42e9be571e0a041873Zbigniew Jędrzejewski-SzmekAC_ARG_ENABLE(resolved, AS_HELP_STRING([--disable-resolved], [disable resolve daemon]))
626851be97b4332fc0401d754c81ae7bbc0f5dc4Lennart Poetteringif test "x$enable_resolved" != "xno"; then
626851be97b4332fc0401d754c81ae7bbc0f5dc4Lennart Poettering have_resolved=yes
626851be97b4332fc0401d754c81ae7bbc0f5dc4Lennart Poettering M4_DEFINES="$M4_DEFINES -DENABLE_RESOLVED"
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart PoetteringAM_CONDITIONAL(ENABLE_RESOLVED, [test "$have_resolved" = "yes"])
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart PoetteringAC_ARG_WITH(dns-servers,
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart Poettering AS_HELP_STRING([--with-dns-servers=DNSSERVERS],
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart Poettering [Space-separated list of default DNS servers]),
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart Poettering [DNS_SERVERS="$withval"],
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart Poettering [DNS_SERVERS="8.8.8.8 8.8.4.4 2001:4860:4860::8888 2001:4860:4860::8844"])
bc2708414babc5c99bb8000e63c84e87606cc15dLennart PoetteringAC_DEFINE_UNQUOTED(DNS_SERVERS, ["$DNS_SERVERS"], [Default DNS Servers])
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart PoetteringAC_SUBST(DNS_SERVERS)
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart Poettering# ------------------------------------------------------------------------------
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart Poetteringhave_networkd=no
bc2708414babc5c99bb8000e63c84e87606cc15dLennart PoetteringAC_ARG_ENABLE(networkd, AS_HELP_STRING([--disable-networkd], [disable networkd]))
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart PoetteringAS_IF([test "x$enable_networkd" != "xno"], [
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart Poettering AC_DEFINE(ENABLE_NETWORKD, 1, [Define if networkd support is to be enabled])
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart Poettering have_networkd=yes
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart Poettering M4_DEFINES="$M4_DEFINES -DENABLE_NETWORKD"
a382332eed10d3348231803c47a4c599d24c5e3aLennart PoetteringAM_CONDITIONAL(ENABLE_NETWORKD, [test "x$have_networkd" = "xyes"])
a382332eed10d3348231803c47a4c599d24c5e3aLennart Poettering# ------------------------------------------------------------------------------
a382332eed10d3348231803c47a4c599d24c5e3aLennart PoetteringAC_ARG_ENABLE(efi, AS_HELP_STRING([--disable-efi], [disable EFI support]))
a382332eed10d3348231803c47a4c599d24c5e3aLennart Poetteringif test "x$enable_efi" != "xno"; then
a382332eed10d3348231803c47a4c599d24c5e3aLennart Poettering AC_DEFINE(ENABLE_EFI, 1, [Define if EFI support is to be enabled])
a382332eed10d3348231803c47a4c599d24c5e3aLennart PoetteringAM_CONDITIONAL(ENABLE_EFI, [test "x$have_efi" = "xyes"])
a382332eed10d3348231803c47a4c599d24c5e3aLennart Poettering# ------------------------------------------------------------------------------
a382332eed10d3348231803c47a4c599d24c5e3aLennart PoetteringAC_SUBST([EFI_CC])
a382332eed10d3348231803c47a4c599d24c5e3aLennart PoetteringEFI_ARCH=`echo $host | sed "s/\(-\).*$//"`
a382332eed10d3348231803c47a4c599d24c5e3aLennart PoetteringAM_COND_IF(ARCH_IA32, [
4ad61fd1806dde23d2c99043b4bed91a196d2c82Cristian Rodríguez EFI_MACHINE_TYPE_NAME=ia32])
4ad61fd1806dde23d2c99043b4bed91a196d2c82Cristian RodríguezAM_COND_IF(ARCH_X86_64, [
abaaabf40a9891014ed4c402d7beb5a67ac256b1Lennart Poettering EFI_MACHINE_TYPE_NAME=x64])
4ad61fd1806dde23d2c99043b4bed91a196d2c82Cristian RodríguezAC_SUBST([EFI_ARCH])
4ad61fd1806dde23d2c99043b4bed91a196d2c82Cristian RodríguezAC_SUBST([EFI_MACHINE_TYPE_NAME])
54b434b1b5055f934230fe04fad35b01642b8488Lennart PoetteringAC_ARG_ENABLE(gnuefi, AS_HELP_STRING([--enable-gnuefi], [Disable optional gnuefi support]))
7211f918ba2b86e0041413b47d51d7593e73cf5dLennart PoetteringAS_IF([test "x$enable_gnuefi" != "xno"], [
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen AC_CHECK_HEADERS(efi/${EFI_ARCH}/efibind.h,
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen [AC_DEFINE(HAVE_GNUEFI, 1, [Define if gnuefi is available])
f8c5a5815ff7c137d9a1e5d7b48a6532b9f31407Lennart Poettering have_gnuefi=yes],
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen [AS_IF([test "x$enable_gnuefi" = xyes],
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen [AC_MSG_ERROR([*** gnuefi support requested but headers not found])])
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen efiroot=$(echo $(cd /usr/lib/$(gcc -print-multi-os-directory); pwd))
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen EFI_LIB_DIR="$efiroot"
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen AC_ARG_WITH(efi-libdir,
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen AS_HELP_STRING([--with-efi-libdir=PATH], [Path to EFI lib directory]),
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen [EFI_LIB_DIR="$withval"], [EFI_LIB_DIR="$efiroot"]
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen AC_SUBST([EFI_LIB_DIR])
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen have_efi_lds=no
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen AC_ARG_WITH(efi-ldsdir,
d562955eac58d3a5089e0f344ea586412a134451Tom Gundersen AS_HELP_STRING([--with-efi-ldsdir=PATH], [Path to EFI lds directory]),
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers [EFI_LDS_DIR="$withval"],
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers [AS_FOR([DIR], [EFI_LDS_DIR], ["${efiroot}/gnuefi" "${efiroot}"],
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers [have_efi_lds=yes && break])])])
de1c301ed165eb4d04a0c9d4babe97912b5233bbLennart Poettering AS_IF([test "x$have_efi_lds" = xyes],
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers [AC_SUBST([EFI_LDS_DIR])],
de1c301ed165eb4d04a0c9d4babe97912b5233bbLennart Poettering [AS_IF([test "x$enable_gnuefi" = xyes],
de1c301ed165eb4d04a0c9d4babe97912b5233bbLennart Poettering [AC_MSG_ERROR([*** gnuefi support requested but files not found])],
fe659612e40e6a0cf91a73b10aa45eea958b747eUmut Tezduyar Lindskog [have_gnuefi=no])])
fe659612e40e6a0cf91a73b10aa45eea958b747eUmut Tezduyar Lindskog AC_ARG_WITH(efi-includedir,
fe659612e40e6a0cf91a73b10aa45eea958b747eUmut Tezduyar Lindskog AS_HELP_STRING([--with-efi-includedir=PATH], [Path to EFI include directory]),
fe659612e40e6a0cf91a73b10aa45eea958b747eUmut Tezduyar Lindskog [EFI_INC_DIR="$withval"], [EFI_INC_DIR="/usr/include"]
75db9a77605b33a1b9355eae957f26380441fce6Lennart Poettering AC_SUBST([EFI_INC_DIR])
4ca39b280fce3c60d2fdecbd478fd9bf7f9d3e64Mike GilbertAM_CONDITIONAL(HAVE_GNUEFI, [test "x$have_gnuefi" = xyes])
75db9a77605b33a1b9355eae957f26380441fce6Lennart Poettering# ------------------------------------------------------------------------------
4df5c00b6e5de8733f3bb33ee7980fad1a498789Umut Tezduyar LindskogAC_ARG_WITH(unifont,
4df5c00b6e5de8733f3bb33ee7980fad1a498789Umut Tezduyar Lindskog AS_HELP_STRING([--with-unifont=PATH],
4df5c00b6e5de8733f3bb33ee7980fad1a498789Umut Tezduyar Lindskog [UNIFONT="$withval"],
4df5c00b6e5de8733f3bb33ee7980fad1a498789Umut Tezduyar Lindskog [UNIFONT="/usr/share/unifont/unifont.hex"])
4df5c00b6e5de8733f3bb33ee7980fad1a498789Umut Tezduyar LindskogAC_SUBST(UNIFONT)
12e34d9d58ed4d97e7bdf8c23494c51ee5ec388eUmut Tezduyar Lindskoghave_terminal=no
12e34d9d58ed4d97e7bdf8c23494c51ee5ec388eUmut Tezduyar LindskogAC_ARG_ENABLE(terminal, AS_HELP_STRING([--enable-terminal], [enable terminal support]))
12e34d9d58ed4d97e7bdf8c23494c51ee5ec388eUmut Tezduyar Lindskogif test "x$enable_terminal" = "xyes"; then
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering PKG_CHECK_MODULES([TERMINAL], [ libevdev >= 1.2 xkbcommon >= 0.5 libdrm >= 2.4], [have_terminal=yes])
12e34d9d58ed4d97e7bdf8c23494c51ee5ec388eUmut Tezduyar Lindskog AC_CHECK_FILE($UNIFONT, [have_unifont=yes])
34eff652cedec3cac34b92629ead5f140334b689Lennart Poettering AS_IF([test "x$have_terminal" != xyes -o "x$have_unifont" != "xyes" -a "x$enable_terminal" = xyes],
34eff652cedec3cac34b92629ead5f140334b689Lennart Poettering [AC_MSG_ERROR([*** terminal support requested but required dependencies not available])],
f1dd0c3f9b4a257e81ff9c6a08070c702a0db45aLennart Poettering [test "x$have_terminal" = xyes -a "x$have_unifont" = "xyes"],
12e84679cc81cdf5f042540e54131a0ce37147adLennart Poettering [AC_DEFINE(ENABLE_TERMINAL, 1, [Define if terminal support is to be enabled])])
be31376e6c9add0786f31a38eec2ecfdb73eb115Kay SieversAM_CONDITIONAL(ENABLE_TERMINAL, [test "x$have_terminal" = "xyes" -a "x$have_unifont" = "xyes"])
be31376e6c9add0786f31a38eec2ecfdb73eb115Kay Sievers# ------------------------------------------------------------------------------
be31376e6c9add0786f31a38eec2ecfdb73eb115Kay Sievershave_kdbus=no
136337ff74f05be3d42a769d9f0cb99716c5c40fTollef Fog HeenAC_ARG_ENABLE(kdbus, AS_HELP_STRING([--enable-kdbus], [do connect to kdbus by default]))
dee4c244254bb49d1ffa8bd7171ae9cce596d2d0Lennart Poetteringif test "x$enable_kdbus" = "xyes"; then
dee4c244254bb49d1ffa8bd7171ae9cce596d2d0Lennart Poettering AC_DEFINE(ENABLE_KDBUS, 1, [Define if kdbus support is to be enabled])
bc2708414babc5c99bb8000e63c84e87606cc15dLennart Poettering have_kdbus=yes
136337ff74f05be3d42a769d9f0cb99716c5c40fTollef Fog Heen M4_DEFINES="$M4_DEFINES -DENABLE_KDBUS"
136337ff74f05be3d42a769d9f0cb99716c5c40fTollef Fog HeenAM_CONDITIONAL(ENABLE_KDBUS, [test "$have_kdbus" = "yes"])
07459bb6b92268beb2599f65cf195708d88c51ccFabiano Fidêncio# ------------------------------------------------------------------------------
07459bb6b92268beb2599f65cf195708d88c51ccFabiano FidêncioAC_ARG_WITH(rc-local-script-path-start,
f975e971accc4d50c73ae53167db3df7a7099cf2Lennart Poettering AS_HELP_STRING([--with-rc-local-script-path-start=PATH],
dee4c244254bb49d1ffa8bd7171ae9cce596d2d0Lennart Poettering [RC_LOCAL_SCRIPT_PATH_START="$withval"],
07459bb6b92268beb2599f65cf195708d88c51ccFabiano Fidêncio [RC_LOCAL_SCRIPT_PATH_START="/etc/rc.local"])
07459bb6b92268beb2599f65cf195708d88c51ccFabiano FidêncioAC_ARG_WITH(rc-local-script-path-stop,
07459bb6b92268beb2599f65cf195708d88c51ccFabiano Fidêncio AS_HELP_STRING([--with-rc-local-script-path-stop=PATH],
bc2708414babc5c99bb8000e63c84e87606cc15dLennart Poettering [RC_LOCAL_SCRIPT_PATH_STOP="$withval"],
bc2708414babc5c99bb8000e63c84e87606cc15dLennart Poettering [RC_LOCAL_SCRIPT_PATH_STOP="/usr/sbin/halt.local"])
bc2708414babc5c99bb8000e63c84e87606cc15dLennart PoetteringAC_DEFINE_UNQUOTED(RC_LOCAL_SCRIPT_PATH_START, ["$RC_LOCAL_SCRIPT_PATH_START"], [Path of /etc/rc.local script])
bc2708414babc5c99bb8000e63c84e87606cc15dLennart PoetteringAC_DEFINE_UNQUOTED(RC_LOCAL_SCRIPT_PATH_STOP, ["$RC_LOCAL_SCRIPT_PATH_STOP"], [Path of /usr/sbin/halt.local script])
a05ea46dc788929bc8b13afb4208ca29cad68572Michael BieblAC_SUBST(RC_LOCAL_SCRIPT_PATH_START)
bef2733fae665e880da6ea011b1f918e6900bb42Lennart PoetteringAC_SUBST(RC_LOCAL_SCRIPT_PATH_STOP)
f8b5d99408e016ecb3d9bcffcee8c65ef6bc26f6Lennart Poettering# ------------------------------------------------------------------------------
f8b5d99408e016ecb3d9bcffcee8c65ef6bc26f6Lennart PoetteringAC_ARG_WITH(kbd-loadkeys,
f8b5d99408e016ecb3d9bcffcee8c65ef6bc26f6Lennart Poettering AS_HELP_STRING([--with-kbd-loadkeys=PATH],
f8b5d99408e016ecb3d9bcffcee8c65ef6bc26f6Lennart Poettering [Path to loadkeys]),
bef2733fae665e880da6ea011b1f918e6900bb42Lennart Poettering [KBD_LOADKEYS="$withval"],
d2d12cd1bfd90f3a13273d82331a7cbd36a93231Lennart Poettering [KBD_LOADKEYS="/usr/bin/loadkeys"])
d2d12cd1bfd90f3a13273d82331a7cbd36a93231Lennart PoetteringAC_ARG_WITH(kbd-setfont,
25ee45f9953c121fc26a54a85ad7bb3a3180152bMichael Biebl AS_HELP_STRING([--with-kbd-setfont=PATH],
d122948d6fbaac4505cf14a08f1237daa89efdd0Lennart Poettering [Path to setfont]),
d2d12cd1bfd90f3a13273d82331a7cbd36a93231Lennart Poettering [KBD_SETFONT="$withval"],
25ee45f9953c121fc26a54a85ad7bb3a3180152bMichael BieblAC_DEFINE_UNQUOTED(KBD_LOADKEYS, ["$KBD_LOADKEYS"], [Path of loadkeys])
d122948d6fbaac4505cf14a08f1237daa89efdd0Lennart PoetteringAC_DEFINE_UNQUOTED(KBD_SETFONT, ["$KBD_SETFONT"], [Path of setfont])
d2d12cd1bfd90f3a13273d82331a7cbd36a93231Lennart PoetteringAC_SUBST(KBD_LOADKEYS)
d2d12cd1bfd90f3a13273d82331a7cbd36a93231Lennart PoetteringAC_SUBST(KBD_SETFONT)
d122948d6fbaac4505cf14a08f1237daa89efdd0Lennart PoetteringAC_ARG_WITH(telinit,
d2d12cd1bfd90f3a13273d82331a7cbd36a93231Lennart Poettering AS_HELP_STRING([--with-telinit=PATH],
d2d12cd1bfd90f3a13273d82331a7cbd36a93231Lennart Poettering [Path to telinit]),
d2d12cd1bfd90f3a13273d82331a7cbd36a93231Lennart Poettering [TELINIT="$withval"],
db059f1b031a92ed45b62d1036877abd9c128d1bMichael BieblAC_DEFINE_UNQUOTED(TELINIT, ["$TELINIT"], [Path to telinit])
db059f1b031a92ed45b62d1036877abd9c128d1bMichael BieblAC_SUBST(TELINIT)
25ee45f9953c121fc26a54a85ad7bb3a3180152bMichael BieblAC_CHECK_HEADERS_ONCE([valgrind/memcheck.h valgrind/valgrind.h])
db059f1b031a92ed45b62d1036877abd9c128d1bMichael Biebl# ------------------------------------------------------------------------------
db059f1b031a92ed45b62d1036877abd9c128d1bMichael Bieblhave_myhostname=no
db059f1b031a92ed45b62d1036877abd9c128d1bMichael BieblAC_ARG_ENABLE(myhostname, AS_HELP_STRING([--disable-myhostname], [disable nss-myhostname support]))
4f87c47b35cf9c1f58872559ae67a2656712fdd6William Giokasif test "x$enable_myhostname" != "xno"; then
4f87c47b35cf9c1f58872559ae67a2656712fdd6William Giokas AC_HEADER_STDC
4f87c47b35cf9c1f58872559ae67a2656712fdd6William Giokas 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 sys/auxv.h])
b8079ae19b41c9b61850c796dddc601b826850e0Kay Sievers AC_TYPE_SIZE_T
39ad55a9aa99451f982628af6e14581092b2d2f6Kay Sievers AC_HEADER_TIME
ae446765eb0605d2451bb4dd7c336672bcc7ab0cKay Sievers AC_FUNC_MALLOC
ae446765eb0605d2451bb4dd7c336672bcc7ab0cKay Sievers AC_FUNC_SELECT_ARGTYPES
ae446765eb0605d2451bb4dd7c336672bcc7ab0cKay Sievers AC_CHECK_FUNCS([gethostbyaddr gethostbyname gettimeofday inet_ntoa memset select socket strcspn strdup strerror strncasecmp strcasecmp strspn])
ae446765eb0605d2451bb4dd7c336672bcc7ab0cKay Sievers have_myhostname=yes
b0cca7d886583a10b9342796b4619eca4d582cb2Michael BieblAM_CONDITIONAL(HAVE_MYHOSTNAME, [test "$have_myhostname" = "yes"])
9d3203b4765e64300ab8e8d6d3d1b9ed0c514d5eKay Sievers# ------------------------------------------------------------------------------
9d3203b4765e64300ab8e8d6d3d1b9ed0c514d5eKay SieversAC_ARG_ENABLE([gudev],
5c390a4ae0d383b2003074ed011d47876c7e630cZbigniew Jędrzejewski-Szmek AS_HELP_STRING([--disable-gudev], [disable Gobject libudev support @<:@default=enabled@:>@]),
5c390a4ae0d383b2003074ed011d47876c7e630cZbigniew Jędrzejewski-Szmek [], [enable_gudev=yes])
5c390a4ae0d383b2003074ed011d47876c7e630cZbigniew Jędrzejewski-SzmekAS_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]) ])
5c390a4ae0d383b2003074ed011d47876c7e630cZbigniew Jędrzejewski-SzmekAM_CONDITIONAL([ENABLE_GUDEV], [test "x$enable_gudev" = "xyes"])
5c390a4ae0d383b2003074ed011d47876c7e630cZbigniew Jędrzejewski-SzmekAS_IF([test "x$enable_gudev" = "xyes"], [ AC_DEFINE(HAVE_GLIB, 1, [Define if glib is available]) ])
bc9bdbbab45ea2c10fdd8ad7c517b5e4a358bdfbMichał Górny# ------------------------------------------------------------------------------
bc9bdbbab45ea2c10fdd8ad7c517b5e4a358bdfbMichał GórnyAC_ARG_ENABLE(hwdb, [AC_HELP_STRING([--disable-hwdb], [disable hardware database support])],
bc9bdbbab45ea2c10fdd8ad7c517b5e4a358bdfbMichał Górny enable_hwdb=$enableval, enable_hwdb=yes)
bc9bdbbab45ea2c10fdd8ad7c517b5e4a358bdfbMichał GórnyAM_CONDITIONAL(ENABLE_HWDB, [test x$enable_hwdb = xyes])
bc9bdbbab45ea2c10fdd8ad7c517b5e4a358bdfbMichał Górny# ------------------------------------------------------------------------------
bc9bdbbab45ea2c10fdd8ad7c517b5e4a358bdfbMichał Górnyhave_manpages=no
bc9bdbbab45ea2c10fdd8ad7c517b5e4a358bdfbMichał GórnyAC_ARG_ENABLE(manpages, AS_HELP_STRING([--disable-manpages], [disable manpages]))
bc9bdbbab45ea2c10fdd8ad7c517b5e4a358bdfbMichał GórnyAS_IF([test "x$enable_manpages" != xno], [have_manpages=yes])
2c6db6fb9b1a10184b086df0d23228c4c0205a49Lennart PoetteringAM_CONDITIONAL(ENABLE_MANPAGES, [test "x$have_manpages" = "xyes"])
2c6db6fb9b1a10184b086df0d23228c4c0205a49Lennart Poettering# ------------------------------------------------------------------------------
6fc00209d5906bd14d54af4a6ac2961dd9731f72Zbigniew Jędrzejewski-SzmekAC_ARG_ENABLE(hibernate,
6fc00209d5906bd14d54af4a6ac2961dd9731f72Zbigniew Jędrzejewski-Szmek [AC_HELP_STRING([--disable-hibernate], [disable hibernation support])],
6fc00209d5906bd14d54af4a6ac2961dd9731f72Zbigniew Jędrzejewski-Szmek enable_hibernate=$enableval, enable_hibernate=yes)
6fc00209d5906bd14d54af4a6ac2961dd9731f72Zbigniew Jędrzejewski-SzmekAM_CONDITIONAL(ENABLE_HIBERNATE, [test x$enable_hibernate = xyes])
6fc00209d5906bd14d54af4a6ac2961dd9731f72Zbigniew Jędrzejewski-Szmek# ------------------------------------------------------------------------------
6fc00209d5906bd14d54af4a6ac2961dd9731f72Zbigniew Jędrzejewski-SzmekAC_ARG_ENABLE(ldconfig,
cee22bd3cb253734a8a0183751d786128e2ea5e4Henrik Grindal Bakken [AC_HELP_STRING([--disable-ldconfig], [disable ldconfig])],
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidt enable_ldconfig=$enableval, enable_ldconfig=yes)
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal SchmidtAM_CONDITIONAL(ENABLE_LDCONFIG, [test x$enable_ldconfig = xyes])
cee22bd3cb253734a8a0183751d786128e2ea5e4Henrik Grindal Bakken# ------------------------------------------------------------------------------
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidt# Location of the init scripts as mandated by LSB
fad5a6c66e73d3df20846906121d52159e1f6bf4Michal SchmidtSYSTEM_SYSVINIT_PATH=/etc/init.d
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal SchmidtSYSTEM_SYSVRCND_PATH=/etc/rc.d
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal SchmidtAC_ARG_WITH([sysvinit-path],
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidt [AS_HELP_STRING([--with-sysvinit-path=PATH],
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidt [Specify the path to where the SysV init scripts are located])],
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidt [SYSTEM_SYSVINIT_PATH="$withval"],
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal SchmidtAC_ARG_WITH([sysvrcnd-path],
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidt [AS_HELP_STRING([--with-sysvrcnd-path=PATH],
fad5a6c66e73d3df20846906121d52159e1f6bf4Michal Schmidt [Specify the path to the base directory for the SysV rcN.d directories])],
fad5a6c66e73d3df20846906121d52159e1f6bf4Michal Schmidt [SYSTEM_SYSVRCND_PATH="$withval"],
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidtif test "x${SYSTEM_SYSVINIT_PATH}" != "x" -a "x${SYSTEM_SYSVRCND_PATH}" != "x"; then
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidt AC_DEFINE(HAVE_SYSV_COMPAT, [], [SysV init scripts and rcN.d links are supported.])
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidt SYSTEM_SYSV_COMPAT="yes"
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidt M4_DEFINES="$M4_DEFINES -DHAVE_SYSV_COMPAT"
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidtelif test "x${SYSTEM_SYSVINIT_PATH}" != "x" -o "x${SYSTEM_SYSVRCND_PATH}" != "x"; then
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidt 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.])
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidt SYSTEM_SYSV_COMPAT="no"
fad5a6c66e73d3df20846906121d52159e1f6bf4Michal SchmidtAC_SUBST(SYSTEM_SYSVINIT_PATH)
994701548d3ea6aafe3d9c47d51f701878118d65Michal SchmidtAC_SUBST(SYSTEM_SYSVRCND_PATH)
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal SchmidtAC_SUBST(M4_DEFINES)
d2d12cd1bfd90f3a13273d82331a7cbd36a93231Lennart PoetteringAM_CONDITIONAL(HAVE_SYSV_COMPAT, test "$SYSTEM_SYSV_COMPAT" = "yes")
d2d12cd1bfd90f3a13273d82331a7cbd36a93231Lennart PoetteringAC_ARG_WITH([tty-gid],
d2d12cd1bfd90f3a13273d82331a7cbd36a93231Lennart Poettering [AS_HELP_STRING([--with-tty-gid=GID],
db059f1b031a92ed45b62d1036877abd9c128d1bMichael Biebl [Specify the numeric GID of the 'tty' group])],
4f87c47b35cf9c1f58872559ae67a2656712fdd6William Giokas [TTY_GID="$withval"],
8c6db8336536916d0476ff8233e0abf40a2f6aabLennart Poettering [TTY_GID="5"])
b8079ae19b41c9b61850c796dddc601b826850e0Kay SieversAC_DEFINE_UNQUOTED(TTY_GID, [$TTY_GID], [GID of the 'tty' group])
ae446765eb0605d2451bb4dd7c336672bcc7ab0cKay SieversAC_SUBST(TTY_GID)
3e2147858f21943d5f4a781c60f33ac22c6096edKay SieversAC_ARG_WITH([dbuspolicydir],
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers AS_HELP_STRING([--with-dbuspolicydir=DIR], [D-Bus policy directory]),
bb061708d5aa83579f213bdfb67253f7027217c3Kay Sievers [with_dbuspolicydir=${sysconfdir}/dbus-1/system.d])
bb061708d5aa83579f213bdfb67253f7027217c3Kay SieversAC_ARG_WITH([dbussessionservicedir],
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers AS_HELP_STRING([--with-dbussessionservicedir=DIR], [D-Bus session service directory]),
a45a909fbbe11ad8c75cda5639d875476ac65453Christian Ruppert [with_dbussessionservicedir=${datadir}/dbus-1/services])
0571e0111d76cf96aa4069d9c7a6e24d97aa7e48Lennart PoetteringAC_ARG_WITH([dbussystemservicedir],
0571e0111d76cf96aa4069d9c7a6e24d97aa7e48Lennart Poettering AS_HELP_STRING([--with-dbussystemservicedir=DIR], [D-Bus system service directory]),
5b6319dceedd81f3f1ce7eb70ea5defaef43bcecLennart Poettering [with_dbussystemservicedir=${datadir}/dbus-1/system-services])
816115863962548a9a0d9fbfe429c7f8e685beacRoberto SassuAC_ARG_WITH([bashcompletiondir],
eef65bf3ee6f73afa4a5de23ae3a794a279f30c0Michael Scherer AS_HELP_STRING([--with-bashcompletiondir=DIR], [Bash completions directory]),
c0467cf387548dc98c0254f63553d862b35a84e5Ronny Chevalier [AS_IF([$($PKG_CONFIG --exists bash-completion)], [
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski with_bashcompletiondir=$($PKG_CONFIG --variable=completionsdir bash-completion)
d89c8fdf48c7bad5816b9f2e77e8361721f22517Zbigniew Jędrzejewski-Szmek with_bashcompletiondir=${datadir}/bash-completion/completions
f6a971bc0bf1252e9614919ccca0d53db5fc53d9Lennart PoetteringAC_ARG_WITH([zshcompletiondir],
7b17a7d72f5ba5ad838b19803534c56a46f3bce9Lennart Poettering AS_HELP_STRING([--with-zshcompletiondir=DIR], [Zsh completions directory]),
77e68fa2f0bd018bab2621a31919bfaa6a6b0a35Lennart Poettering [], [with_zshcompletiondir=${datadir}/zsh/site-functions])
36ef43edcf1c9640b3fda017b381c4b1854641f4Zbigniew Jędrzejewski-SzmekAC_ARG_WITH([rootprefix],
bdf10b5b4d9e7abdc08bdca4b073d021b0043d1fLennart Poettering AS_HELP_STRING([--with-rootprefix=DIR], [rootfs directory prefix for config files and kernel modules]),
8d4e028f1868c47864ec873d9f30c3ee961a8849Lennart Poettering [], [with_rootprefix=${ac_default_prefix}])
e5e83e8362e946890ac991fc86a2c5869f9befdfLennart PoetteringAC_ARG_WITH([rootlibdir],
83fdc450aa8f79941bec84488ffd5bf8eadab18eAuke Kok AS_HELP_STRING([--with-rootlibdir=DIR], [Root directory for libraries necessary for boot]),
6351163bf3e519cc07adb2732d12450741f5a0d3Umut Tezduyar [with_rootlibdir=${libdir}])
418b9be50018303cde79b423d4701b7fd86ddbdcLennart PoetteringAC_ARG_WITH([pamlibdir],
4de856120f252e7aa19c923c10fbf23310d623aaLennart Poettering AS_HELP_STRING([--with-pamlibdir=DIR], [Directory for PAM modules]),
3990f247652c3bd41e4ea074e6302277eb9c7aa3Lennart Poettering [with_pamlibdir=${with_rootlibdir}/security])
1ee306e1248866617c96ed9f4263f375588ad838Lennart PoetteringAC_ARG_WITH([pamconfdir],
b2e9fb99ab288e8817302851743ed1a3cddd384bMiklos Vajna AS_HELP_STRING([--with-pamconfdir=DIR], [Directory for PAM configuration]),
a91df40e69fec72cc98c9829721fa5153da28bc2Kay Sievers [with_pamconfdir=${sysconfdir}/pam.d])
661278ee297247c0c7e0708924f8ce52284529fcLennart PoetteringAC_ARG_ENABLE([split-usr],
4cd1eaa54507a65286413363216ad407fa7c6e50Miklos Vajna AS_HELP_STRING([--enable-split-usr], [Assume that /bin, /sbin aren\'t symlinks into /usr]),
091a364c802e34a58f3260c9cb5db9b75c62215cTom Gundersen [AS_IF([test "x${ac_default_prefix}" != "x${with_rootprefix}"], [
e16cb2e4efaba83f47da8355adc65fd83bbe8327Tom Gundersen enable_split_usr=yes
46ba8aae2b82bc5c87ba347e6bf914ecd5e9d51eLennart Poettering enable_split_usr=no
d4f5a1f47dbd04f26f2ddf951c97c4cb0ebbbe62David HerrmannAC_ARG_WITH([dkr-index-url],
f553b3b1074151200187df916427a1468186435eAnders Olofsson [AS_HELP_STRING([--dkr-index-url=URL], [Specify the default index URL to use for image downloads])],
8d3ae2bd4c9bf9fc2e57f7b3776325a1c750ca30Chris Leech [DEFAULT_DKR_INDEX_URL="\"$withval\""],
ac6b760ceedd4b21921b6a682cf1479af3d3024fZbigniew Jędrzejewski-Szmek [DEFAULT_DKR_INDEX_URL="NULL"])
3e2147858f21943d5f4a781c60f33ac22c6096edKay SieversAC_DEFINE_UNQUOTED(DEFAULT_DKR_INDEX_URL, [$DEFAULT_DKR_INDEX_URL], [Default index URL to use for image downloads])
fe659612e40e6a0cf91a73b10aa45eea958b747eUmut Tezduyar LindskogAC_SUBST(DEFAULT_DKR_INDEX_URL)
84da4a3022bc599b26d9601cf1b7bf51d1d9f915David HerrmannAS_IF([test "x${enable_split_usr}" = "xyes"], [
626851be97b4332fc0401d754c81ae7bbc0f5dc4Lennart Poettering AC_DEFINE(HAVE_SPLIT_USR, 1, [Define if /bin, /sbin aren't symlinks into /usr])
2f4da3e6c298bc0ae6243cae47aedb01c50fa870Zbigniew Jędrzejewski-Szmek# Work around intltoolize and gtk-doc problems in VPATH builds
2f4da3e6c298bc0ae6243cae47aedb01c50fa870Zbigniew Jędrzejewski-SzmekAM_CONDITIONAL([ENABLE_GTK_DOC_TESTS], [test "x$0" = "x./configure"],
6aea6d10f460853111ca8744201ec8dade97de3cThomas H.P. Andersen [Define to do gtk-doc tests])
2f4da3e6c298bc0ae6243cae47aedb01c50fa870Zbigniew Jędrzejewski-SzmekAS_IF([test "x$0" != "x./configure"], [
2f4da3e6c298bc0ae6243cae47aedb01c50fa870Zbigniew Jędrzejewski-Szmek AC_SUBST([INTLTOOL_UPDATE], [/bin/true])
fc86aa0ed204922dcafa85353cb10e1aa7d91a76Michal Schmidt# QEMU and OVMF UEFI firmware
3e2147858f21943d5f4a781c60f33ac22c6096edKay SieversAS_IF([test x"$cross_compiling" = "xyes"], [], [
8c4a3079a7f358c179430d1aec59de8b670b5f6eLennart Poettering AC_PATH_PROG([QEMU], [qemu-system-x86_64])
b8079ae19b41c9b61850c796dddc601b826850e0Kay Sievers AC_CHECK_FILE([/usr/share/qemu/bios-ovmf.bin], [QEMU_BIOS=/usr/share/qemu/bios-ovmf.bin],
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers [AC_CHECK_FILE([/usr/share/qemu-ovmf/bios.bin], [QEMU_BIOS=/usr/share/qemu-ovmf/bios.bin])])
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers AC_SUBST([QEMU_BIOS])
ae446765eb0605d2451bb4dd7c336672bcc7ab0cKay SieversAC_ARG_ENABLE(tests,
ae446765eb0605d2451bb4dd7c336672bcc7ab0cKay Sievers [AC_HELP_STRING([--disable-tests], [disable tests])],
2f4da3e6c298bc0ae6243cae47aedb01c50fa870Zbigniew Jędrzejewski-Szmek enable_tests=$enableval, enable_tests=yes)
2f4da3e6c298bc0ae6243cae47aedb01c50fa870Zbigniew Jędrzejewski-SzmekAM_CONDITIONAL(ENABLE_TESTS, [test x$enable_tests = xyes])
2f4da3e6c298bc0ae6243cae47aedb01c50fa870Zbigniew Jędrzejewski-SzmekAC_ARG_ENABLE(debug,
f2ec0646aba7c6703a6c79603957e805b74c3befZbigniew Jędrzejewski-Szmek [AC_HELP_STRING([--enable-debug@<:@=LIST@:>@], [enable extra debugging (hashmap,mmap-cache)])],
2c6db6fb9b1a10184b086df0d23228c4c0205a49Lennart Poettering [if test "x$enableval" = "xyes"; then
5c390a4ae0d383b2003074ed011d47876c7e630cZbigniew Jędrzejewski-Szmek enableval="hashmap,mmap-cache"
2c6db6fb9b1a10184b086df0d23228c4c0205a49Lennart Poettering saved_ifs="$IFS"
2c6db6fb9b1a10184b086df0d23228c4c0205a49Lennart Poettering IFS="$IFS$PATH_SEPARATOR,"
2c6db6fb9b1a10184b086df0d23228c4c0205a49Lennart Poettering for name in $enableval; do
db059f1b031a92ed45b62d1036877abd9c128d1bMichael Biebl case $name in
b1c4ca25bf58e1925012d1dcdd83d61cecbf87fbLennart Poettering enable_debug_hashmap=yes
f8b5d99408e016ecb3d9bcffcee8c65ef6bc26f6Lennart Poettering enable_debug_mmap_cache=yes
66be6554807773028a0111addb8e75c3cab11117Kay Sievers IFS="$saved_ifs"],[])
1f048a6b6bcc30d2e157711b3d231d7a944e6ffbJan Engelhardtenable_debug=""
5a45a93627609451784a04366cfa1150d32611d1Lennart PoetteringAS_IF([test x$enable_debug_hashmap = xyes], [
a6c0b31d509f76023d8efbcd5e912863c8fb254cZbigniew Jędrzejewski-Szmek AC_DEFINE(ENABLE_DEBUG_HASHMAP, 1, [Define if hashmap debugging is to be enabled])
a6c0b31d509f76023d8efbcd5e912863c8fb254cZbigniew Jędrzejewski-Szmek enable_debug="hashmap $enable_debug"
Makefile po/Makefile.in
utmp/wtmp support: ${have_utmp}