2 # Process this file with autoconf to produce a configure script.
5 # autoconf claims that this should be package name;
6 # but it seems that the name of a randomly choosen but
7 # existing file is required.
11 AM_INIT_AUTOMAKE(yaird,${YAIRD_VERSION})
14 # Required optional feature to determine which template to install.
15 # Packagers are expected to put their own template in ./templates
16 # before configuring, so this should not get in their way.
17 # This should go away once we have option file parsing.
19 AC_ARG_ENABLE(template,
20 AC_HELP_STRING([--enable-template=name],[install templates/name.pm as initrd template (no default)]),
22 if test -f "templates/$enableval.pm"
24 INITRD_TEMPLATE="$enableval"
25 AC_SUBST(INITRD_TEMPLATE)
27 AC_MSG_ERROR(Template '$enableval' not found in ./templates)
30 [ AC_MSG_ERROR(required option --enable-template=xxx is missing) ])
33 AC_HELP_STRING([--enable-nuke],
34 [Nuke initramfs before moving to real root]),
36 case "${enableval}" in
37 yes) enable_nuke=true ;;
38 no) enable_nuke=false ;;
39 *) AC_MSG_ERROR(bad value ${enableval} for --enable-nuke) ;;
44 if test "$enable_nuke" = true; then
45 AC_DEFINE(ENABLE_NUKE,1,
46 [Define to nuke initramfs before moving to real root])
49 # Checks for programs.
50 AC_PATH_PROG(PERL,perl)
54 # XML formatting; unclear what processor is most widely available.
56 AC_PATH_PROG(XMLTO,xmlto,:)
58 # Checks for libraries.
59 # Checks for header files.
60 # Checks for typedefs, structures, and compiler characteristics.
61 # Checks for library functions.
63 # Use this when we need to compile C programs.
64 AM_CONFIG_HEADER(include/config.h)