# GNU Guix --- Functional package management for GNU
-# Copyright © 2012, 2013, 2014 Ludovic Courtès <ludo@gnu.org>
+# Copyright © 2012, 2013, 2014, 2015 Ludovic Courtès <ludo@gnu.org>
#
# This file is part of GNU Guix.
#
#
BUILT_SOURCES += nix/libstore/schema.sql.hh
-CLEANFILES += $(BUILT_SOURCES)
+CLEANFILES += $(BUILT_SOURCES) etc/guix-daemon.service
noinst_LIBRARIES = libformat.a libutil.a libstore.a
-# Use '-std=c++0x' for 'std::shared_ptr'.
-AM_CXXFLAGS = -Wall -std=c++0x
+# Use '-std=c++11' for 'std::shared_ptr', 'auto', lambdas, and more.
+AM_CXXFLAGS = -Wall -std=c++11
libformat_a_SOURCES = \
nix/boost/format/free_funcs.cc \
nix/libstore/references.hh \
nix/libstore/pathlocks.hh \
nix/libstore/globals.hh \
- nix/libstore/schema.sql.hh \
nix/libstore/worker-protocol.hh \
nix/libstore/remote-store.hh \
nix/libstore/derivations.hh \
-DNIX_CONF_DIR=\"$(sysconfdir)/guix\" \
-DNIX_LIBEXEC_DIR=\"$(libexecdir)\" \
-DNIX_BIN_DIR=\"$(bindir)\" \
- -DOPENSSL_PATH="\"guix-authenticate\""
+ -DOPENSSL_PATH="\"guix-authenticate\"" \
+ -DDEFAULT_CHROOT_DIRS="\"\""
libstore_a_CXXFLAGS = $(AM_CXXFLAGS) \
$(SQLITE3_CFLAGS) $(LIBGCRYPT_CFLAGS)
nix/nix-daemon/guix-daemon.cc
guix_daemon_CPPFLAGS = \
+ -DLOCALEDIR=\"$(localedir)\" \
$(libutil_a_CPPFLAGS) \
-I$(top_srcdir)/nix/libstore
nodist_pkglibexec_SCRIPTS = \
nix/scripts/list-runtime-roots \
- nix/scripts/substitute-binary
+ nix/scripts/substitute
if BUILD_DAEMON_OFFLOAD
nodist_libexec_SCRIPTS = \
nix/scripts/guix-authenticate
+# The '.service' file for systemd.
+systemdservicedir = $(libdir)/systemd/system
+nodist_systemdservice_DATA = etc/guix-daemon.service
+
+etc/guix-daemon.service: etc/guix-daemon.service.in \
+ $(top_builddir)/config.status
+ $(MKDIR_P) "`dirname "$@"`"
+ $(SED) -e 's|@''bindir''@|$(bindir)|' < \
+ "$(srcdir)/etc/guix-daemon.service.in" > "$@.tmp"
+ mv "$@.tmp" "$@"
+
EXTRA_DIST += \
- nix/sync-with-upstream \
nix/libstore/schema.sql \
nix/AUTHORS \
- nix/COPYING
+ nix/COPYING \
+ etc/guix-daemon.service.in
AM_TESTS_ENVIRONMENT += \
top_builddir="$(abs_top_builddir)"