SummaryRefsLogTreeCommitDiffStats
diff options
context:
space:
mode:
authorMathieu Lirzin <mthl@gnu.org>2017-01-14 17:24:25 +0100
committerMathieu Lirzin <mthl@gnu.org>2017-09-28 13:15:24 +0200
commitade37c96b748e5588c148e66e1420b5e4f0e8fd5 (patch)
tree126927664cc9b99c32d8039048c957b5312ef5ba
parent44e0e6f305e9f579af40915723b1965c565e96b9 (diff)
downloadmcron-ade37c96b748e5588c148e66e1420b5e4f0e8fd5.tar.gz
mcron-ade37c96b748e5588c148e66e1420b5e4f0e8fd5.tar.bz2
mcron-ade37c96b748e5588c148e66e1420b5e4f0e8fd5.zip
build: Support Guile 2.2.
* configure.ac: Use 'GUILE_PKG' and 'GUILE_PROGS'. Remove explicit Guile version check and check for 'guild'. Honor $GUILE_EFFECTIVE_VERSION in 'moduledir'.
-rw-r--r--configure.ac25
1 files changed, 14 insertions, 11 deletions
diff --git a/configure.ac b/configure.ac
index 5940555..efb3fe1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,7 @@
## Process this file with autoconf to produce a configure script.
# Copyright © 2003, 2005, 2012, 2014 Dale Mellor
# <dale_mellor@users.sourceforge.net>
-# Copyright © 2015, 2016 Mathieu Lirzin <mthl@gnu.org>
+# Copyright © 2015, 2016, 2017 Mathieu Lirzin <mthl@gnu.org>
#
# This file is part of GNU Mcron.
#
@@ -29,9 +29,6 @@ AC_REQUIRE_AUX_FILE([git-version-gen])
AM_INIT_AUTOMAKE([subdir-objects -Wall -Wno-override])
AM_SILENT_RULES([yes]) # enables silent rules by default
-moduledir="${datarootdir}/guile/site/2.0"
-AC_SUBST([moduledir])
-AC_SUBST([mcronmoduledir], ["${moduledir}/mcron"])
AC_MSG_CHECKING([whether debugging is requested])
AC_ARG_ENABLE(debug,
AC_HELP_STRING([--enable-debug],
@@ -55,16 +52,22 @@ AC_PROG_AWK
AC_PROG_EGREP
AM_PROG_CC_C_O
-PKG_CHECK_MODULES([GUILE], [guile-2.0 >= 2.0.7])
-AC_PATH_PROG([GUILE], [guile])
+# Check for Guile 2.x. development files
+GUILE_PKG([2.2 2.0])
-# search guild
-AC_PATH_PROG([GUILD], [guild])
-AS_IF([test -z "$ac_cv_path_GUILD"],
- [AC_MSG_ERROR(['guild' program cannot be found.])])
+# Set directories for installed Guile modules
+moduledir="${datarootdir}/guile/site/$GUILE_EFFECTIVE_VERSION"
+AC_SUBST([moduledir])
+AC_SUBST([mcronmoduledir], ["${moduledir}/mcron"])
+
+# Set Guile flags without using GUILE_FLAGS which is requiring the unused
+# 'config.rpath' script.
+PKG_CHECK_MODULES(GUILE, [guile-$GUILE_EFFECTIVE_VERSION])
# Checks for programs.
-
+
+GUILE_PROGS
+
AM_MISSING_PROG(HELP2MAN, help2man, $missing_dir)
AC_CHECK_PROGS(SED, sed)