The make logic assumes that the SYSTEMD_UNIT_FILES var can be built from
SYSTEMD_UNIT_FILES_IN by simply dropping the directory prefix and the
.in suffix.
This won't work in future when a single .in unit file can be used to
generate multiple different units.
Signed-off-by: Daniel P. Berrangé <berrange(a)redhat.com>
---
src/Makefile.am | 2 +-
src/locking/Makefile.inc.am | 5 ++++-
src/logging/Makefile.inc.am | 5 ++++-
src/remote/Makefile.inc.am | 5 ++++-
4 files changed, 13 insertions(+), 4 deletions(-)
diff --git a/src/Makefile.am b/src/Makefile.am
index d254069e4b..4c534d2f48 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -82,6 +82,7 @@ RPC_PROBE_FILES =
LOGROTATE_FILES_IN =
PODFILES =
MANINFILES =
+SYSTEMD_UNIT_FILES =
SYSTEMD_UNIT_FILES_IN =
SYSCONF_FILES =
sbin_PROGRAMS =
@@ -832,7 +833,6 @@ if WITH_LIBVIRTD
if LIBVIRT_INIT_SCRIPT_SYSTEMD
SYSTEMD_UNIT_DIR = $(prefix)/lib/systemd/system
-SYSTEMD_UNIT_FILES = $(notdir $(SYSTEMD_UNIT_FILES_IN:%.in=%))
BUILT_SOURCES += $(SYSTEMD_UNIT_FILES)
DISTCLEANFILES += $(SYSTEMD_UNIT_FILES)
diff --git a/src/locking/Makefile.inc.am b/src/locking/Makefile.inc.am
index 161410051c..1f002acce6 100644
--- a/src/locking/Makefile.inc.am
+++ b/src/locking/Makefile.inc.am
@@ -77,12 +77,15 @@ MANINFILES += virtlockd.8.in
CLEANFILES += $(man8_MANS)
MAINTAINERCLEANFILES += $(MANINFILES)
-SYSTEMD_UNIT_FILES_IN += \
+VIRTLOCKD_UNIT_FILES_IN = \
locking/virtlockd.service.in \
locking/virtlockd.socket.in \
locking/virtlockd-admin.socket.in \
$(NULL)
+SYSTEMD_UNIT_FILES += $(notdir $(VIRTLOCKD_UNIT_FILES_IN:%.in=%))
+SYSTEMD_UNIT_FILES_IN += $(VIRTLOCKD_UNIT_FILES_IN)
+
lockdriverdir = $(libdir)/libvirt/lock-driver
lockdriver_LTLIBRARIES =
diff --git a/src/logging/Makefile.inc.am b/src/logging/Makefile.inc.am
index f0c49330f5..ef853cdcc4 100644
--- a/src/logging/Makefile.inc.am
+++ b/src/logging/Makefile.inc.am
@@ -50,12 +50,15 @@ PODFILES += logging/virtlogd.pod
MANINFILES += virtlogd.8.in
SYSCONF_FILES += logging/virtlogd.sysconf
-SYSTEMD_UNIT_FILES_IN += \
+VIRTLOGD_UNIT_FILES_IN = \
logging/virtlogd.service.in \
logging/virtlogd.socket.in \
logging/virtlogd-admin.socket.in \
$(NULL)
+SYSTEMD_UNIT_FILES += $(notdir $(VIRTLOGD_UNIT_FILES_IN:%.in=%))
+SYSTEMD_UNIT_FILES_IN += $(VIRTLOGD_UNIT_FILES_IN)
+
if WITH_LIBVIRTD
sbin_PROGRAMS += virtlogd
diff --git a/src/remote/Makefile.inc.am b/src/remote/Makefile.inc.am
index c56f9230f2..e1a3fb1888 100644
--- a/src/remote/Makefile.inc.am
+++ b/src/remote/Makefile.inc.am
@@ -90,7 +90,7 @@ SYSCONF_FILES += remote/libvirtd.sysconf
PODFILES += remote/libvirtd.pod
MANINFILES += libvirtd.8.in
-SYSTEMD_UNIT_FILES_IN += \
+LIBVIRTD_UNIT_FILES_IN = \
remote/libvirtd.service.in \
remote/libvirtd.socket.in \
remote/libvirtd-ro.socket.in \
@@ -100,6 +100,9 @@ SYSTEMD_UNIT_FILES_IN += \
remote/virt-guest-shutdown.target.in \
$(NULL)
+SYSTEMD_UNIT_FILES += $(notdir $(LIBVIRTD_UNIT_FILES_IN:%.in=%))
+SYSTEMD_UNIT_FILES_IN += $(LIBVIRTD_UNIT_FILES_IN)
+
REMOTE_PROTOCOL = $(srcdir)/remote/remote_protocol.x
LXC_PROTOCOL = $(srcdir)/remote/lxc_protocol.x
QEMU_PROTOCOL = $(srcdir)/remote/qemu_protocol.x
--
2.21.0