~ubuntu-branches/debian/jessie/systemd/jessie

« back to all changes in this revision

Viewing changes to configure.ac

  • Committer: Package Import Robot
  • Author(s): Tollef Fog Heen, Tollef Fog Heen, Michael Biebl
  • Date: 2012-04-03 19:59:17 UTC
  • mfrom: (1.1.10) (6.1.3 experimental)
  • Revision ID: package-import@ubuntu.com-20120403195917-l532urrbg4pkreas
Tags: 44-1
[ Tollef Fog Heen ]
* New upstream version.
  - Backport 3492207: journal: PAGE_SIZE is not known on ppc and other
    archs
  - Backport 5a2a2a1: journal: react with immediate rotation to a couple
    of more errors
  - Backport 693ce21: util: never follow symlinks in rm_rf_children()
    Fixes CVE-2012-1174, closes: #664364
* Drop output message from init-functions hook, it's pointless.
* Only rmdir /lib/init/rw if it exists.
* Explicitly order debian-fixup before sysinit.target to prevent a
  possible race condition with the creation of sockets.  Thanks to
  Michael Biebl for debugging this.
* Always restart the initctl socket on upgrades, to mask sysvinit
  removing it.

[ Michael Biebl ]
* Remove workaround for non-interactive sessions from pam config again.
* Create compat /dev/initctl symlink in case we are upgrading from a system
  running a newer version of sysvinit (using /run/initctl) and sysvinit is
  replaced with systemd-sysv during the upgrade. Closes: #663219
* Install new man pages.
* Build-Depend on valac (>= 0.12) instead of valac-0.12. Closes: #663323

Show diffs side-by-side

added added

removed removed

Lines of Context:
17
17
 
18
18
AC_PREREQ(2.63)
19
19
 
20
 
AC_INIT([systemd],[37],[systemd-devel@lists.freedesktop.org])
 
20
AC_INIT([systemd],[44],[systemd-devel@lists.freedesktop.org])
21
21
AC_CONFIG_SRCDIR([src/main.c])
22
22
AC_CONFIG_MACRO_DIR([m4])
23
23
AC_CONFIG_HEADERS([config.h])
24
24
AC_USE_SYSTEM_EXTENSIONS
25
25
AC_SYS_LARGEFILE
26
 
 
27
 
AM_INIT_AUTOMAKE([foreign 1.11 -Wall -Wno-portability silent-rules tar-pax subdir-objects dist-bzip2])
 
26
AC_PREFIX_DEFAULT([/usr])
 
27
AM_INIT_AUTOMAKE([foreign 1.11 -Wall -Wno-portability silent-rules tar-pax no-dist-gzip dist-xz subdir-objects check-news])
28
28
 
29
29
AC_SUBST(PACKAGE_URL, [http://www.freedesktop.org/wiki/Software/systemd])
30
30
 
36
36
 
37
37
AM_SILENT_RULES([yes])
38
38
 
39
 
AC_CHECK_PROG([STOW], [stow], [yes], [no])
40
 
 
41
 
AS_IF([test "x$STOW" = "xyes" && test -d /usr/local/stow], [
42
 
        AC_MSG_NOTICE([*** Found /usr/local/stow: default install prefix set to /usr/local/stow/${PACKAGE_NAME}-${PACKAGE_VERSION} ***])
43
 
        ac_default_prefix="/usr/local/stow/${PACKAGE_NAME}-${PACKAGE_VERSION}"
44
 
])
45
 
 
46
39
# i18n stuff for the PolicyKit policy files
47
40
IT_PROG_INTLTOOL([0.40.0])
48
41
 
52
45
AC_PROG_MKDIR_P
53
46
AC_PROG_LN_S
54
47
AC_PROG_SED
 
48
AC_PROG_GREP
55
49
AC_PROG_AWK
56
50
 
57
51
AC_PROG_CC
100
94
        -Wno-unused-parameter \
101
95
        -Wno-missing-field-initializers \
102
96
        -Wno-unused-result \
 
97
        -Werror=overflow \
103
98
        -Wp,-D_FORTIFY_SOURCE=2 \
104
99
        -ffast-math \
105
100
        -fno-common \
129
124
m4_pattern_forbid([^_?PKG_[A-Z_]+$],[*** pkg.m4 missing, please install pkg-config])
130
125
 
131
126
PKG_CHECK_MODULES(UDEV, [ libudev >= 172 ])
132
 
AC_SUBST(UDEV_CFLAGS)
133
 
AC_SUBST(UDEV_LIBS)
134
 
 
135
127
PKG_CHECK_MODULES(DBUS, [ dbus-1 >= 1.3.2 ])
136
 
AC_SUBST(DBUS_CFLAGS)
137
 
AC_SUBST(DBUS_LIBS)
 
128
PKG_CHECK_MODULES(KMOD, [ libkmod >= 5 ])
138
129
 
139
130
have_selinux=no
140
131
AC_ARG_ENABLE(selinux, AS_HELP_STRING([--disable-selinux], [Disable optional SELINUX support]))
141
132
if test "x$enable_selinux" != "xno"; then
142
133
        PKG_CHECK_MODULES(SELINUX, [ libselinux ],
143
134
                [AC_DEFINE(HAVE_SELINUX, 1, [Define if SELinux is available]) have_selinux=yes], have_selinux=no)
144
 
        AC_SUBST(SELINUX_CFLAGS)
145
 
        AC_SUBST(SELINUX_LIBS)
146
135
        if test "x$have_selinux" = xno -a "x$enable_selinux" = xyes; then
147
136
                AC_MSG_ERROR([*** SELinux support requested but libraries not found])
148
137
        fi
149
138
fi
150
139
AM_CONDITIONAL(HAVE_SELINUX, [test "$have_selinux" = "yes"])
151
140
 
 
141
have_xz=no
 
142
AC_ARG_ENABLE(xz, AS_HELP_STRING([--disable-xz], [Disable optional XZ support]))
 
143
if test "x$enable_xz" != "xno"; then
 
144
        PKG_CHECK_MODULES(XZ, [ liblzma ],
 
145
                [AC_DEFINE(HAVE_XZ, 1, [Define if XZ is available]) have_xz=yes], have_xz=no)
 
146
        if test "x$have_xz" = xno -a "x$enable_xz" = xyes; then
 
147
                AC_MSG_ERROR([*** Xz support requested but libraries not found])
 
148
        fi
 
149
fi
 
150
AM_CONDITIONAL(HAVE_XZ, [test "$have_xz" = "yes"])
 
151
 
152
152
AC_ARG_ENABLE([tcpwrap],
153
153
        AS_HELP_STRING([--disable-tcpwrap],[Disable optional TCP wrappers support]),
154
154
                [case "${enableval}" in
288
288
if test "x$enable_libcryptsetup" != "xno"; then
289
289
        PKG_CHECK_MODULES(LIBCRYPTSETUP, [ libcryptsetup ],
290
290
                [AC_DEFINE(HAVE_LIBCRYPTSETUP, 1, [Define if libcryptsetup is available]) have_libcryptsetup=yes], have_libcryptsetup=no)
291
 
        AC_SUBST(LIBCRYPTSETUP_CFLAGS)
292
 
        AC_SUBST(LIBCRYPTSETUP_LIBS)
293
291
        if test "x$have_libcryptsetup" = xno -a "x$enable_libcryptsetup" = xyes; then
294
292
                AC_MSG_ERROR([*** libcryptsetup support requested but libraries not found])
295
293
        fi
299
297
have_binfmt=no
300
298
AC_ARG_ENABLE(binfmt, AS_HELP_STRING([--disable-binfmt], [disable binfmt tool]))
301
299
if test "x$enable_binfmt" != "xno"; then
302
 
        have_binfmt=yes
 
300
        have_binfmt=yes
303
301
fi
304
302
AM_CONDITIONAL(ENABLE_BINFMT, [test "$have_binfmt" = "yes"])
305
303
 
 
304
have_vconsole=no
 
305
AC_ARG_ENABLE(vconsole, AS_HELP_STRING([--disable-vconsole], [disable vconsole tool]))
 
306
if test "x$enable_vconsole" != "xno"; then
 
307
        have_vconsole=yes
 
308
fi
 
309
AM_CONDITIONAL(ENABLE_VCONSOLE, [test "$have_vconsole" = "yes"])
 
310
 
 
311
have_readahead=no
 
312
AC_ARG_ENABLE(readahead, AS_HELP_STRING([--disable-readahead], [disable readahead tools]))
 
313
if test "x$enable_readahead" != "xno"; then
 
314
        have_readahead=yes
 
315
fi
 
316
AM_CONDITIONAL(ENABLE_READAHEAD, [test "$have_readahead" = "yes"])
 
317
 
 
318
have_quotacheck=no
 
319
AC_ARG_ENABLE(quotacheck, AS_HELP_STRING([--disable-quotacheck], [disable quotacheck tools]))
 
320
if test "x$enable_quotacheck" != "xno"; then
 
321
        have_quotacheck=yes
 
322
fi
 
323
AM_CONDITIONAL(ENABLE_QUOTACHECK, [test "$have_quotacheck" = "yes"])
 
324
 
 
325
have_randomseed=no
 
326
AC_ARG_ENABLE(randomseed, AS_HELP_STRING([--disable-randomseed], [disable randomseed tools]))
 
327
if test "x$enable_randomseed" != "xno"; then
 
328
        have_randomseed=yes
 
329
fi
 
330
AM_CONDITIONAL(ENABLE_RANDOMSEED, [test "$have_randomseed" = "yes"])
 
331
 
 
332
have_logind=no
 
333
AC_ARG_ENABLE(logind, AS_HELP_STRING([--disable-logind], [disable login daemon]))
 
334
if test "x$enable_logind" != "xno"; then
 
335
        have_logind=yes
 
336
fi
 
337
AM_CONDITIONAL(ENABLE_LOGIND, [test "$have_logind" = "yes"])
 
338
AS_IF([test "$have_logind" = "yes"], [ AC_DEFINE(HAVE_LOGIND, [1], [Logind support available]) ])
 
339
 
306
340
have_hostnamed=no
307
341
AC_ARG_ENABLE(hostnamed, AS_HELP_STRING([--disable-hostnamed], [disable hostname daemon]))
308
342
if test "x$enable_hostnamed" != "xno"; then
309
 
        have_hostnamed=yes
 
343
        have_hostnamed=yes
310
344
fi
311
345
AM_CONDITIONAL(ENABLE_HOSTNAMED, [test "$have_hostnamed" = "yes"])
312
346
 
313
347
have_timedated=no
314
348
AC_ARG_ENABLE(timedated, AS_HELP_STRING([--disable-timedated], [disable timedate daemon]))
315
349
if test "x$enable_timedated" != "xno"; then
316
 
        have_timedated=yes
 
350
        have_timedated=yes
317
351
fi
318
352
AM_CONDITIONAL(ENABLE_TIMEDATED, [test "$have_timedated" = "yes"])
319
353
 
320
354
have_localed=no
321
355
AC_ARG_ENABLE(localed, AS_HELP_STRING([--disable-localed], [disable locale daemon]))
322
356
if test "x$enable_localed" != "xno"; then
323
 
        have_localed=yes
 
357
        have_localed=yes
324
358
fi
325
359
AM_CONDITIONAL(ENABLE_LOCALED, [test "$have_localed" = "yes"])
326
360
 
 
361
have_coredump=no
 
362
AC_ARG_ENABLE(coredump, AS_HELP_STRING([--disable-coredump], [disable coredump hook]))
 
363
if test "x$enable_coredump" != "xno"; then
 
364
        have_coredump=yes
 
365
fi
 
366
AM_CONDITIONAL(ENABLE_COREDUMP, [test "$have_coredump" = "yes"])
 
367
 
 
368
have_manpages=no
 
369
AC_ARG_ENABLE(manpages, AS_HELP_STRING([--disable-manpages], [disable manpages]))
 
370
if test "x$enable_manpages" != "xno"; then
 
371
        have_manpages=yes
 
372
fi
 
373
AM_CONDITIONAL(ENABLE_MANPAGES, [test "$have_manpages" = "yes"])
 
374
 
327
375
have_gtk=no
328
376
AC_ARG_ENABLE(gtk, AS_HELP_STRING([--disable-gtk], [disable GTK tools]))
329
377
if test "x$enable_gtk" != "xno"; then
330
 
        PKG_CHECK_MODULES(GTK, [ gtk+-2.0 glib-2.0 > 2.26 gio-unix-2.0 ],
 
378
        PKG_CHECK_MODULES(GTK, [ gtk+-2.0 glib-2.0 > 2.26 gio-unix-2.0 gee-1.0],
331
379
                [AC_DEFINE(HAVE_GTK, 1, [Define if GTK is available]) have_gtk=yes], have_gtk=no)
332
 
        AC_SUBST(GTK_CFLAGS)
333
 
        AC_SUBST(GTK_LIBS)
334
380
        if test "x$have_gtk" = xno -a "x$enable_gtk" = xyes; then
335
381
                AC_MSG_ERROR([*** gtk support requested but libraries not found])
336
382
        fi
339
385
 
340
386
if test "$have_gtk" = "yes"; then
341
387
        PKG_CHECK_MODULES(LIBNOTIFY, [ libnotify ])
342
 
        PKG_CHECK_EXISTS([ libnotify >= 0.7.0 ], [ libnotify07=yes ])
343
 
 
344
 
        AC_SUBST(LIBNOTIFY_CFLAGS)
345
 
        AC_SUBST(LIBNOTIFY_LIBS)
346
388
fi
347
 
AM_CONDITIONAL(LIBNOTIFY07, [ test "$libnotify07" = "yes" ])
348
389
 
349
390
AM_PROG_VALAC([0.10])
350
391
AC_SUBST(VAPIDIR)
355
396
 
356
397
AC_PATH_PROG([M4], [m4])
357
398
 
358
 
AC_ARG_WITH(distro, AS_HELP_STRING([--with-distro=DISTRO],[Specify the distribution to target: One of fedora, suse, debian, ubuntu, arch, gentoo, slackware, altlinux or other]))
 
399
AC_ARG_WITH(distro, AS_HELP_STRING([--with-distro=DISTRO],[Specify the distribution to target: One of fedora, suse, debian, ubuntu, arch, gentoo, slackware, altlinux, mandriva, meego, mageia, angstrom or other]))
359
400
if test "z$with_distro" = "z"; then
360
401
        if test "$cross_compiling" = yes; then
361
402
                AC_MSG_WARN([Target distribution cannot be reliably detected when cross-compiling. You should specify it with --with-distro (see $0 --help for recognized distros)])
362
403
        else
363
 
                test -f "/etc/redhat-release" && with_distro="fedora"
364
 
                test -f "/etc/SuSE-release" && with_distro="suse"
365
 
                test -f "/etc/debian_version" &&  with_distro="debian"
366
 
                test -f "/etc/arch-release" && with_distro="arch"
367
 
                test -f "/etc/gentoo-release" && with_distro="gentoo"
368
 
                test -f "/etc/slackware-version" && with_distro="slackware"
369
 
                test -f "/etc/frugalware-release" && with_distro="frugalware"
370
 
                test -f "/etc/altlinux-release" && with_distro="altlinux"
371
 
                test -f "/etc/mandriva-release" && with_distro="mandriva"
372
 
                test -f "/etc/meego-release" && with_distro="meego"
373
 
                test -f "/etc/angstrom-version" && with_distro="angstrom"
374
 
                if test "x`lsb_release -is 2>/dev/null`" = "xUbuntu"; then
375
 
                        with_distro="ubuntu"
376
 
                fi
 
404
                with_distro=$($GREP '^ID=' /etc/os-release | $SED 's/ID=//');
377
405
        fi
378
406
        if test "z$with_distro" = "z"; then
379
 
                with_distro=`uname -s`
 
407
                with_distro=other
380
408
        fi
381
409
fi
382
410
with_distro=`echo ${with_distro} | tr '[[:upper:]]' '[[:lower:]]' `
396
424
                M4_DEFINES=-DTARGET_FEDORA=1
397
425
                have_plymouth=yes
398
426
                ;;
399
 
        suse)
 
427
        opensuse|suse)
400
428
                SYSTEM_SYSVRCND_PATH=/etc/init.d
401
429
                AC_DEFINE(TARGET_SUSE, [], [Target is openSUSE/SLE])
402
430
                M4_DEFINES=-DTARGET_SUSE=1
452
480
                SYSTEM_SYSVRCND_PATH=
453
481
                AC_DEFINE(TARGET_MEEGO, [], [Target is MeeGo])
454
482
                M4_DEFINES=-DTARGET_MEEGO=1
455
 
                ;;
 
483
                ;;
456
484
        angstrom)
457
485
                SYSTEM_SYSVRCND_PATH=/etc
458
486
                AC_DEFINE(TARGET_ANGSTROM, [], [Target is Ångström])
459
487
                M4_DEFINES=-DTARGET_ANGSTROM=1
460
488
                ;;
 
489
        mageia)
 
490
                SYSTEM_SYSVINIT_PATH=/etc/rc.d/init.d
 
491
                AC_DEFINE(TARGET_MAGEIA, [], [Target is Mageia])
 
492
                M4_DISTRO_FLAG=-DTARGET_MAGEIA=1
 
493
                have_plymouth=yes
 
494
                ;;
461
495
        other)
462
496
                ;;
463
497
        *)
466
500
esac
467
501
 
468
502
AC_ARG_WITH([sysvinit-path],
469
 
        [AS_HELP_STRING([--with-sysvinit-path=PATH],
470
 
                [Specify the path to where the SysV init scripts are located @<:@default=based on distro@:>@])],
471
 
        [SYSTEM_SYSVINIT_PATH="$withval"],
472
 
        [])
 
503
        [AS_HELP_STRING([--with-sysvinit-path=PATH],
 
504
                [Specify the path to where the SysV init scripts are located @<:@default=based on distro@:>@])],
 
505
        [SYSTEM_SYSVINIT_PATH="$withval"],
 
506
        [])
473
507
 
474
508
AC_ARG_WITH([sysvrcd-path],
475
509
        [AS_HELP_STRING([--with-sysvrcd-path=PATH],
515
549
AM_CONDITIONAL(TARGET_MANDRIVA, test x"$with_distro" = xmandriva)
516
550
AM_CONDITIONAL(TARGET_MEEGO, test x"$with_distro" = xmeego)
517
551
AM_CONDITIONAL(TARGET_ANGSTROM, test x"$with_distro" = xangstrom)
 
552
AM_CONDITIONAL(TARGET_MAGEIA, test x"$with_distro" = xmageia)
518
553
 
519
554
AM_CONDITIONAL(HAVE_PLYMOUTH, test "$have_plymouth" = "yes")
520
555
AM_CONDITIONAL(HAVE_SYSV_COMPAT, test "$SYSTEM_SYSV_COMPAT" = "yes")
540
575
        [with_dbusinterfacedir=`pkg-config --variable=session_bus_services_dir dbus-1`/../interfaces])
541
576
 
542
577
AC_ARG_WITH([udevrulesdir],
543
 
        AS_HELP_STRING([--with-udevrulesdir=DIR], [Diectory for udev rules]),
 
578
        AS_HELP_STRING([--with-udevrulesdir=DIR], [Directory for udev rules]),
544
579
        [],
545
580
        [with_udevrulesdir=`pkg-config --variable=udevdir udev`/rules.d])
546
581
 
547
 
AC_ARG_WITH([pamlibdir],
548
 
        AS_HELP_STRING([--with-pamlibdir=DIR], [Diectory for PAM modules]),
549
 
        [],
550
 
        [with_pamlibdir=/lib/`$CC -print-multi-os-directory`/security])
551
 
 
552
 
AC_ARG_WITH([rootdir],
553
 
        AS_HELP_STRING([--with-rootdir=DIR], [Root directory for files necessary for boot]),
554
 
        [],
555
 
        [with_rootdir=${ac_default_prefix}])
 
582
AC_ARG_WITH([rootprefix],
 
583
        AS_HELP_STRING([--with-rootprefix=DIR], [rootfs directory prefix for config files and kernel modules]),
 
584
        [], [with_rootprefix=${ac_default_prefix}])
556
585
 
557
586
AC_ARG_WITH([rootlibdir],
558
587
        AS_HELP_STRING([--with-rootlibdir=DIR], [Root directory for libraries necessary for boot]),
559
588
        [],
560
589
        [with_rootlibdir=${libdir}])
561
590
 
 
591
AC_ARG_WITH([pamlibdir],
 
592
        AS_HELP_STRING([--with-pamlibdir=DIR], [Directory for PAM modules]),
 
593
        [],
 
594
        [with_pamlibdir=${with_rootlibdir}/security])
 
595
 
 
596
AC_ARG_ENABLE([split-usr],
 
597
        AS_HELP_STRING([--enable-split-usr], [Assume that /bin, /sbin aren\'t symlinks into /usr]),
 
598
        [],
 
599
        [AS_IF([test "x${ac_default_prefix}" != "x${with_rootprefix}"], [
 
600
                enable_split_usr=yes
 
601
        ], [
 
602
                enable_split_usr=no
 
603
        ])])
 
604
 
 
605
AS_IF([test "x${enable_split_usr}" = "xyes"], [
 
606
        AC_DEFINE(HAVE_SPLIT_USR, 1, [Define if /bin, /sbin aren't symlinks into /usr])
 
607
])
 
608
 
562
609
AC_SUBST([dbuspolicydir], [$with_dbuspolicydir])
563
610
AC_SUBST([dbussessionservicedir], [$with_dbussessionservicedir])
564
611
AC_SUBST([dbussystemservicedir], [$with_dbussystemservicedir])
565
612
AC_SUBST([dbusinterfacedir], [$with_dbusinterfacedir])
566
613
AC_SUBST([udevrulesdir], [$with_udevrulesdir])
567
614
AC_SUBST([pamlibdir], [$with_pamlibdir])
568
 
AC_SUBST([rootdir], [$with_rootdir])
 
615
AC_SUBST([rootprefix], [$with_rootprefix])
569
616
AC_SUBST([rootlibdir], [$with_rootlibdir])
570
617
 
571
618
AC_CONFIG_FILES([Makefile po/Makefile.in])
583
630
        PAM:                     ${have_pam}
584
631
        AUDIT:                   ${have_audit}
585
632
        SELinux:                 ${have_selinux}
 
633
        XZ:                      ${have_xz}
586
634
        ACL:                     ${have_acl}
587
635
        binfmt:                  ${have_binfmt}
 
636
        vconsole:                ${have_vconsole}
 
637
        readahead:               ${have_readahead}
 
638
        quotacheck:              ${have_quotacheck}
 
639
        randomseed:              ${have_randomseed}
 
640
        logind:                  ${have_logind}
588
641
        hostnamed:               ${have_hostnamed}
589
642
        timedated:               ${have_timedated}
590
643
        localed:                 ${have_localed}
 
644
        coredump:                ${have_coredump}
591
645
        plymouth:                ${have_plymouth}
592
646
        prefix:                  ${prefix}
593
 
        root dir:                ${with_rootdir}
 
647
        rootprefix:              ${with_rootprefix}
 
648
        libexec dir:             ${libexecdir}
594
649
        lib dir:                 ${libdir}
595
650
        rootlib dir:             ${with_rootlibdir}
596
 
        pam modules dir:         ${with_pamlibdir}
 
651
        PAM modules dir:         ${with_pamlibdir}
597
652
        udev rules dir:          ${with_udevrulesdir}
598
 
        dbus policy dir:         ${with_dbuspolicydir}
599
 
        dbus session dir:        ${with_dbussessionservicedir}
600
 
        dbus system dir:         ${with_dbussystemservicedir}
601
 
        dbus interfaces dir:     ${with_dbusinterfacedir}
 
653
        D-Bus policy dir:        ${with_dbuspolicydir}
 
654
        D-Bus session dir:       ${with_dbussessionservicedir}
 
655
        D-Bus system dir:        ${with_dbussystemservicedir}
 
656
        D-Bus interfaces dir:    ${with_dbusinterfacedir}
 
657
        Split /usr:              ${enable_split_usr}
 
658
        man pages:               ${have_manpages}
602
659
])