blob: 7f9c9c4f8edb753f32f7252b98bcb8edffd982cd [file] [log] [blame]
Scott James Remnant8a0cd072006-05-14 18:28:58 +01001# Process this file with autoconf to produce a configure script.
2
Scott James Remnanta86d3982007-10-15 17:55:09 +01003AC_PREREQ(2.61)
Scott James Remnant5d6466d2007-10-15 01:40:52 +01004AC_INIT([upstart], [0.5.0], [upstart-devel@lists.ubuntu.com])
Scott James Remnant30bc02b2008-01-16 01:49:20 +00005AC_COPYRIGHT([[Copyright © 2008 Canonical Ltd.]])
Scott James Remnant8a0cd072006-05-14 18:28:58 +01006AC_CONFIG_SRCDIR([init/main.c])
7AC_CONFIG_MACRO_DIR([m4])
8
Scott James Remnant8985dd32006-10-12 15:26:29 +01009AC_GNU_SOURCE
10
Scott James Remnant0c3bef32007-10-08 13:20:56 +010011AM_INIT_AUTOMAKE([1.10 gnu nostdinc check-news dist-bzip2])
Scott James Remnant8a0cd072006-05-14 18:28:58 +010012
Scott James Remnante16d32c2007-10-08 13:37:44 +010013AM_GNU_GETTEXT_VERSION([0.16.1])
Scott James Remnant8a0cd072006-05-14 18:28:58 +010014AM_GNU_GETTEXT()
15
16# Checks for programs.
17AC_PROG_CC
Scott James Remnantc043a8a2007-04-24 12:59:54 +010018AM_PROG_CC_C_O
Scott James Remnant8a0cd072006-05-14 18:28:58 +010019AC_PROG_LIBTOOL
20
21# Checks for libraries.
Scott James Remnant477d9d42008-04-12 14:07:48 +010022NIH_INIT([dbus])
Scott James Remnant8a0cd072006-05-14 18:28:58 +010023
24# Checks for header files.
25
26# Checks for typedefs, structures, and compiler characteristics.
27
28# Checks for library functions.
29
30# Other checks
Scott James Remnant59093a82006-10-10 13:09:58 +010031AC_ARG_ENABLE(compat,
32 AS_HELP_STRING([--enable-compat],
33 [Enable compatibility tools]),
34[case "$enable_compat" in
35 yes|sysv) compat=sysv ;;
36 no) compat=none ;;
37 *) AC_MSG_ERROR([bad value $enable_compat for --enable-compat]) ;;
38esac], [compat_sysv=none])dnl
39AM_CONDITIONAL(COMPAT_SYSV, test "x$compat" = "xsysv")dnl
40
Scott James Remnant680d2fd2008-02-29 17:41:38 +000041AC_MSG_CHECKING([whether to include sbindir in PATH])
42eval upstart_sbindir=\"$sbindir\"
43case $upstart_sbindir in
44 /sbin|//sbin|/usr/sbin|/usr/local/sbin)
45 AC_MSG_RESULT([no])
46 ;;
47 *)
48 AC_MSG_RESULT([yes])
49 AC_DEFINE_UNQUOTED([EXTRA_PATH], ["$upstart_sbindir"],
50 [Directory to append to path.])
51 ;;
52esac
53
Scott James Remnant8a0cd072006-05-14 18:28:58 +010054
Scott James Remnant5222c402006-09-27 22:48:48 +010055AC_CONFIG_FILES([ Makefile m4/Makefile po/Makefile.in intl/Makefile
Scott James Remnant08169c12008-05-08 23:14:22 +010056 nih/Makefile init/Makefile dbus/Makefile doc/Makefile ])
Scott James Remnant3e32e082007-10-16 00:08:24 +010057# util/Makefile compat/sysv/Makefile logd/Makefile
Scott James Remnant8a0cd072006-05-14 18:28:58 +010058AC_CONFIG_HEADERS([config.h])
59AC_OUTPUT