meson: src: install libvirt daemon sysconf files

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
This commit is contained in:
Pavel Hrdina 2020-06-25 17:46:33 +02:00
parent 25ab77a197
commit 3d1bd8e8bb
30 changed files with 89 additions and 65 deletions

View File

@ -35,11 +35,9 @@ tapset_DATA =
endif WITH_DTRACE_PROBES endif WITH_DTRACE_PROBES
RPC_PROBE_FILES = RPC_PROBE_FILES =
LOGROTATE_FILES_IN = LOGROTATE_FILES_IN =
SYSCONF_FILES =
include security/Makefile.inc.am include security/Makefile.inc.am
include access/Makefile.inc.am include access/Makefile.inc.am
include logging/Makefile.inc.am
include locking/Makefile.inc.am include locking/Makefile.inc.am
include admin/Makefile.inc.am include admin/Makefile.inc.am
include vbox/Makefile.inc.am include vbox/Makefile.inc.am
@ -205,23 +203,6 @@ libvirt_functions.stp: $(RPC_PROBE_FILES) $(top_srcdir)/scripts/gensystemtap.py
endif WITH_DTRACE_PROBES endif WITH_DTRACE_PROBES
install-sysconfig:
$(MKDIR_P) $(DESTDIR)$(sysconfdir)/sysconfig
for f in $(SYSCONF_FILES:%.sysconf=%) ; \
do \
tgt=`basename $$f`; \
$(INSTALL_DATA) $(srcdir)/$$f.sysconf \
$(DESTDIR)$(sysconfdir)/sysconfig/$$tgt; \
done
uninstall-sysconfig:
for f in $(SYSCONF_FILES:%.sysconf=%) ; \
do \
tgt=`basename $$f`; \
rm -f $(DESTDIR)$(sysconfdir)/sysconfig/$$tgt; \
done
rmdir $(DESTDIR)$(sysconfdir)/sysconfig || :
LOGROTATE_FILES := $(LOGROTATE_FILES_IN:remote/%.in=%) LOGROTATE_FILES := $(LOGROTATE_FILES_IN:remote/%.in=%)
BUILT_SOURCES += $(LOGROTATE_FILES) BUILT_SOURCES += $(LOGROTATE_FILES)

View File

@ -3,9 +3,3 @@
DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(INTERFACE_DRIVER_SOURCES)) DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(INTERFACE_DRIVER_SOURCES))
STATEFUL_DRIVER_SOURCE_FILES += \ STATEFUL_DRIVER_SOURCE_FILES += \
$(addprefix $(srcdir)/,$(INTERFACE_DRIVER_SOURCES)) $(addprefix $(srcdir)/,$(INTERFACE_DRIVER_SOURCES))
if WITH_INTERFACE
SYSCONF_FILES += interface/virtinterfaced.sysconf
endif WITH_INTERFACE

View File

@ -52,4 +52,9 @@ if conf.has('WITH_INTERFACE')
'name': 'virtinterfaced', 'name': 'virtinterfaced',
'in_file': files('virtinterfaced.init.in') 'in_file': files('virtinterfaced.init.in')
} }
sysconf_files += {
'name': 'virtinterfaced',
'file': files('virtinterfaced.sysconf'),
}
endif endif

View File

@ -5,8 +5,6 @@ STATEFUL_DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(LIBXL_DRIVER_SOURCES))
if WITH_LIBXL if WITH_LIBXL
SYSCONF_FILES += libxl/virtxend.sysconf
INSTALL_DATA_DIRS += libxl INSTALL_DATA_DIRS += libxl
install-data-libxl: install-data-libxl:

View File

@ -71,4 +71,9 @@ if conf.has('WITH_LIBXL')
'name': 'virtxend', 'name': 'virtxend',
'in_file': files('virtxend.init.in'), 'in_file': files('virtxend.init.in'),
} }
sysconf_files += {
'name': 'virtxend',
'file': files('virtxend.sysconf'),
}
endif endif

View File

@ -1,7 +1,6 @@
# vim: filetype=automake # vim: filetype=automake
RPC_PROBE_FILES += $(srcdir)/locking/lock_protocol.x RPC_PROBE_FILES += $(srcdir)/locking/lock_protocol.x
SYSCONF_FILES += locking/virtlockd.sysconf
INSTALL_DATA_DIRS += locking INSTALL_DATA_DIRS += locking

View File

@ -149,6 +149,11 @@ if conf.has('WITH_LIBVIRTD')
'in_file': files('virtlockd.init.in'), 'in_file': files('virtlockd.init.in'),
} }
sysconf_files += {
'name': 'virtlockd',
'file': files('virtlockd.sysconf'),
}
if conf.has('WITH_SANLOCK') if conf.has('WITH_SANLOCK')
virt_helpers += { virt_helpers += {
'name': 'libvirt_sanlock_helper', 'name': 'libvirt_sanlock_helper',

View File

@ -1,3 +0,0 @@
# vim: filetype=automake
SYSCONF_FILES += logging/virtlogd.sysconf

View File

@ -93,6 +93,11 @@ if conf.has('WITH_LIBVIRTD')
'name': 'virtlogd', 'name': 'virtlogd',
'in_file': files('virtlogd.init.in'), 'in_file': files('virtlogd.init.in'),
} }
sysconf_files += {
'name': 'virtlogd',
'file': files('virtlogd.sysconf'),
}
endif endif
log_inc_dir = include_directories('.') log_inc_dir = include_directories('.')

View File

@ -11,8 +11,6 @@ STATEFUL_DRIVER_SOURCE_FILES += \
if WITH_LXC if WITH_LXC
SYSCONF_FILES += lxc/virtlxcd.sysconf
if WITH_DTRACE_PROBES if WITH_DTRACE_PROBES
RPC_PROBE_FILES += $(srcdir)/lxc/lxc_monitor_protocol.x RPC_PROBE_FILES += $(srcdir)/lxc/lxc_monitor_protocol.x
endif endif

View File

@ -154,4 +154,9 @@ if conf.has('WITH_LXC')
'name': 'virtlxcd', 'name': 'virtlxcd',
'in_file': files('virtlxcd.init.in'), 'in_file': files('virtlxcd.init.in'),
} }
sysconf_files += {
'name': 'virtlxcd',
'file': files('virtlxcd.sysconf'),
}
endif endif

View File

@ -205,6 +205,12 @@ virt_daemon_units = []
# * in_file - source init file (required) # * in_file - source init file (required)
openrc_init_files = [] openrc_init_files = []
# sysconf_files
# install libvirt daemon sysconf files
# * name - daemon name (required)
# * file - source sysconf file (required)
sysconf_files = []
# list subdirectories # list subdirectories
@ -786,3 +792,11 @@ if conf.has('WITH_LIBVIRTD')
endforeach endforeach
endif endif
endif endif
foreach sysconf : sysconf_files
install_data(
sysconf['file'],
install_dir: sysconfdir / 'sysconfig',
rename: [ sysconf['name'] ],
)
endforeach

View File

@ -5,8 +5,6 @@ STATEFUL_DRIVER_SOURCE_FILES += \
$(addprefix $(srcdir)/,$(NETWORK_DRIVER_SOURCES)) $(addprefix $(srcdir)/,$(NETWORK_DRIVER_SOURCES))
if WITH_NETWORK if WITH_NETWORK
SYSCONF_FILES += network/virtnetworkd.sysconf
INSTALL_DATA_DIRS += network INSTALL_DATA_DIRS += network
UUID=$(shell uuidgen 2>/dev/null) UUID=$(shell uuidgen 2>/dev/null)

View File

@ -71,4 +71,9 @@ if conf.has('WITH_NETWORK')
'name': 'virtnetworkd', 'name': 'virtnetworkd',
'in_file': files('virtnetworkd.init.in'), 'in_file': files('virtnetworkd.init.in'),
} }
sysconf_files += {
'name': 'virtnetworkd',
'file': files('virtnetworkd.sysconf'),
}
endif endif

View File

@ -9,8 +9,3 @@ DRIVER_SOURCE_FILES += \
STATEFUL_DRIVER_SOURCE_FILES += \ STATEFUL_DRIVER_SOURCE_FILES += \
$(addprefix $(srcdir)/,$(NODE_DEVICE_DRIVER_SOURCES)) \ $(addprefix $(srcdir)/,$(NODE_DEVICE_DRIVER_SOURCES)) \
$(NULL) $(NULL)
if WITH_NODE_DEVICES
SYSCONF_FILES += node_device/virtnodedevd.sysconf
endif WITH_NODE_DEVICES

View File

@ -64,4 +64,9 @@ if conf.has('WITH_NODE_DEVICES')
'name': 'virtnodedevd', 'name': 'virtnodedevd',
'in_file': files('virtnodedevd.init.in'), 'in_file': files('virtnodedevd.init.in'),
} }
sysconf_files += {
'name': 'virtnodedevd',
'file': files('virtnodedevd.sysconf'),
}
endif endif

View File

@ -11,6 +11,4 @@ if WITH_NWFILTER
nwfilterxmldir = $(sysconfdir)/libvirt/nwfilter nwfilterxmldir = $(sysconfdir)/libvirt/nwfilter
nwfilterxml_DATA = $(NWFILTER_XML_FILES) nwfilterxml_DATA = $(NWFILTER_XML_FILES)
SYSCONF_FILES += nwfilter/virtnwfilterd.sysconf
endif WITH_NWFILTER endif WITH_NWFILTER

View File

@ -59,4 +59,9 @@ if conf.has('WITH_NWFILTER')
'name': 'virtnwfilterd', 'name': 'virtnwfilterd',
'in_file': files('virtnwfilterd.init.in'), 'in_file': files('virtnwfilterd.init.in'),
} }
sysconf_files += {
'name': 'virtnwfilterd',
'file': files('virtnwfilterd.sysconf'),
}
endif endif

View File

@ -4,7 +4,6 @@ DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(QEMU_DRIVER_SOURCES))
STATEFUL_DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(QEMU_DRIVER_SOURCES)) STATEFUL_DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(QEMU_DRIVER_SOURCES))
if WITH_QEMU if WITH_QEMU
SYSCONF_FILES += qemu/virtqemud.sysconf
INSTALL_DATA_DIRS += qemu INSTALL_DATA_DIRS += qemu

View File

@ -155,4 +155,9 @@ if conf.has('WITH_QEMU')
'name': 'virtqemud', 'name': 'virtqemud',
'in_file': files('virtqemud.init.in'), 'in_file': files('virtqemud.init.in'),
} }
sysconf_files += {
'name': 'virtqemud',
'file': files('virtqemud.sysconf'),
}
endif endif

View File

@ -7,11 +7,6 @@ LOGROTATE_FILES_IN += \
remote/libvirtd.logrotate.in \ remote/libvirtd.logrotate.in \
$(NULL) $(NULL)
SYSCONF_FILES += \
remote/libvirtd.sysconf \
remote/virtproxyd.sysconf \
$(NULL)
if WITH_LIBVIRTD if WITH_LIBVIRTD
INSTALL_DATA_DIRS += remote INSTALL_DATA_DIRS += remote

View File

@ -170,6 +170,11 @@ if conf.has('WITH_REMOTE')
'confd': files('libvirtd.confd'), 'confd': files('libvirtd.confd'),
} }
sysconf_files += {
'name': 'libvirtd',
'file': files('libvirtd.sysconf'),
}
virt_daemons += { virt_daemons += {
'name': 'virtproxyd', 'name': 'virtproxyd',
'c_args': [ 'c_args': [
@ -199,6 +204,11 @@ if conf.has('WITH_REMOTE')
'in_file': files('virtproxyd.init.in'), 'in_file': files('virtproxyd.init.in'),
'confd': files('virtproxyd.confd'), 'confd': files('virtproxyd.confd'),
} }
sysconf_files += {
'name': 'virtproxyd',
'file': files('virtproxyd.sysconf'),
}
endif endif
endif endif

View File

@ -3,7 +3,3 @@
DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(SECRET_DRIVER_SOURCES)) DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(SECRET_DRIVER_SOURCES))
STATEFUL_DRIVER_SOURCE_FILES += \ STATEFUL_DRIVER_SOURCE_FILES += \
$(addprefix $(srcdir)/,$(SECRET_DRIVER_SOURCES)) $(addprefix $(srcdir)/,$(SECRET_DRIVER_SOURCES))
if WITH_SECRETS
SYSCONF_FILES += secret/virtsecretd.sysconf
endif WITH_SECRETS

View File

@ -41,4 +41,9 @@ if conf.has('WITH_SECRETS')
'name': 'virtsecretd', 'name': 'virtsecretd',
'in_file': files('virtsecretd.init.in'), 'in_file': files('virtsecretd.init.in'),
} }
sysconf_files += {
'name': 'virtsecretd',
'file': files('virtsecretd.sysconf'),
}
endif endif

View File

@ -3,7 +3,3 @@
DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(STORAGE_DRIVER_SOURCES)) DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(STORAGE_DRIVER_SOURCES))
STATEFUL_DRIVER_SOURCE_FILES += \ STATEFUL_DRIVER_SOURCE_FILES += \
$(addprefix $(srcdir)/,$(STORAGE_DRIVER_SOURCES)) $(addprefix $(srcdir)/,$(STORAGE_DRIVER_SOURCES))
if WITH_STORAGE
SYSCONF_FILES += storage/virtstoraged.sysconf
endif WITH_STORAGE

View File

@ -139,6 +139,11 @@ if conf.has('WITH_STORAGE')
'name': 'virtstoraged', 'name': 'virtstoraged',
'in_file': files('virtstoraged.init.in'), 'in_file': files('virtstoraged.init.in'),
} }
sysconf_files += {
'name': 'virtstoraged',
'file': files('virtstoraged.sysconf'),
}
endif endif
if conf.has('WITH_STORAGE_DISK') if conf.has('WITH_STORAGE_DISK')

View File

@ -4,7 +4,3 @@ DRIVER_SOURCE_FILES += \
$(addprefix $(srcdir)/,$(VBOX_DRIVER_SOURCES)) \ $(addprefix $(srcdir)/,$(VBOX_DRIVER_SOURCES)) \
$(srcdir)/vbox/vbox_tmpl.c \ $(srcdir)/vbox/vbox_tmpl.c \
$(NULL) $(NULL)
if WITH_VBOX
SYSCONF_FILES += vbox/virtvboxd.sysconf
endif WITH_VBOX

View File

@ -64,4 +64,9 @@ if conf.has('WITH_VBOX')
'name': 'virtvboxd', 'name': 'virtvboxd',
'in_file': files('virtvboxd.init.in'), 'in_file': files('virtvboxd.init.in'),
} }
sysconf_files += {
'name': 'virtvboxd',
'file': files('virtvboxd.sysconf'),
}
endif endif

View File

@ -2,8 +2,3 @@
DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(VZ_DRIVER_SOURCES)) DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(VZ_DRIVER_SOURCES))
STATEFUL_DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(VZ_DRIVER_SOURCES)) STATEFUL_DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(VZ_DRIVER_SOURCES))
if WITH_VZ
SYSCONF_FILES += vz/virtvzd.sysconf
endif WITH_VZ

View File

@ -56,4 +56,9 @@ if conf.has('WITH_VZ')
'name': 'virtvzd', 'name': 'virtvzd',
'in_file': files('virtvzd.init.in'), 'in_file': files('virtvzd.init.in'),
} }
sysconf_files += {
'name': 'virtvzd',
'file': files('virtvzd.sysconf'),
}
endif endif