aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2012-12-13 00:26:41 +0100
committerLudovic Courtès <ludo@gnu.org>2012-12-13 00:26:41 +0100
commit3a61f8017a11c2a482faef58861d7dc1d37a082e (patch)
treed4a0dc30af69dfe8bf984bfcd9aebcf4ae3106a9
parent8a9451c89e23d12c88d12557a0b612b851def528 (diff)
downloadguix-3a61f8017a11c2a482faef58861d7dc1d37a082e.tar.gz
guix-3a61f8017a11c2a482faef58861d7dc1d37a082e.zip
build: When `--enable-daemon', don't error out when Nix programs are missing.
* config-daemon.ac: Move AC_ARG_ENABLE([daemon]...)... * configure.ac: ... here. When Nix programs are not found, error out only when $guix_build_daemon is no.
-rw-r--r--config-daemon.ac5
-rw-r--r--configure.ac7
2 files changed, 6 insertions, 6 deletions
diff --git a/config-daemon.ac b/config-daemon.ac
index edd372fba9..f48741dfda 100644
--- a/config-daemon.ac
+++ b/config-daemon.ac
@@ -1,10 +1,5 @@
dnl -*- Autoconf -*- fragment for the C++ daemon.
-AC_ARG_ENABLE([daemon],
- [AS_HELP_STRING([--enable-daemon], [build the Nix daemon (C++)])],
- [guix_build_daemon="$enableval"],
- [guix_build_daemon="no"])
-
AC_MSG_CHECKING([whether to build daemon])
AC_MSG_RESULT([$guix_build_daemon])
diff --git a/configure.ac b/configure.ac
index fdc1931b3c..0ea216e9d5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -30,6 +30,11 @@ AC_ARG_WITH(store-dir,
[storedir="/nix/store"])
AC_SUBST(storedir)
+AC_ARG_ENABLE([daemon],
+ [AS_HELP_STRING([--enable-daemon], [build the Nix daemon (C++)])],
+ [guix_build_daemon="$enableval"],
+ [guix_build_daemon="no"])
+
# Prepare a version of $localstatedir that does not contain references
# to shell variables.
guix_localstatedir="`eval echo $localstatedir | sed -e "s|NONE|/usr/local|g"`"
@@ -56,7 +61,7 @@ AC_ARG_WITH([nix-prefix],
AC_PATH_PROG([NIX_INSTANTIATE], [nix-instantiate])
AC_PATH_PROG([NIX_HASH], [nix-hash])
-if test "x$NIX_INSTANTIATE$NIX_HASH" = "x"; then
+if test "x$guix_build_daemon$NIX_INSTANTIATE$NIX_HASH" = "xno"; then
AC_MSG_ERROR([Nix programs not found; please install Nix or use `--with-nix-prefix'.])
fi