Gentoo Archives: gentoo-commits

From: Matthias Maier <tamiko@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-emulation/libvirt/files/, app-emulation/libvirt/
Date: Thu, 01 Aug 2019 14:28:47
Message-Id: 1564669690.b97942ec61c46b9d3123bfed2ddce8b5566566ef.tamiko@gentoo
1 commit: b97942ec61c46b9d3123bfed2ddce8b5566566ef
2 Author: Michal Privoznik <mprivozn <AT> redhat <DOT> com>
3 AuthorDate: Thu Aug 1 09:44:14 2019 +0000
4 Commit: Matthias Maier <tamiko <AT> gentoo <DOT> org>
5 CommitDate: Thu Aug 1 14:28:10 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b97942ec
7
8 app-emulation/libvirt-9999: Rebase libvirt-5.2.0-do-not-use-sysconf.patch
9
10 The original patch does not apply cleanly, because of upstream
11 commits 4304222f50d9ff364 and 9d7fcdbf83a1.
12
13 Signed-off-by: Michal Privoznik <mprivozn <AT> redhat.com>
14 Signed-off-by: Matthias Maier <tamiko <AT> gentoo.org>
15
16 .../files/libvirt-5.6.0-do-not-use-sysconf.patch | 174 +++++++++++++++++++++
17 app-emulation/libvirt/libvirt-9999.ebuild | 2 +-
18 2 files changed, 175 insertions(+), 1 deletion(-)
19
20 diff --git a/app-emulation/libvirt/files/libvirt-5.6.0-do-not-use-sysconf.patch b/app-emulation/libvirt/files/libvirt-5.6.0-do-not-use-sysconf.patch
21 new file mode 100644
22 index 00000000000..b847392cc13
23 --- /dev/null
24 +++ b/app-emulation/libvirt/files/libvirt-5.6.0-do-not-use-sysconf.patch
25 @@ -0,0 +1,174 @@
26 +From 8b27863cd4bd4eebefe6f39b42c181d073b457ff Mon Sep 17 00:00:00 2001
27 +Message-Id: <8b27863cd4bd4eebefe6f39b42c181d073b457ff.1564650738.git.mprivozn@××××××.com>
28 +From: Michal Privoznik <mprivozn@××××××.com>
29 +Date: Sat, 16 Mar 2019 12:33:00 +0100
30 +Subject: [PATCH] gentoo: do not use sysconf
31 +
32 +Signed-off-by: Michal Privoznik <mprivozn@××××××.com>
33 +---
34 + src/Makefile.am | 21 ++-------------------
35 + src/locking/virtlockd.service.in | 3 +--
36 + src/logging/virtlogd.service.in | 3 +--
37 + src/remote/libvirtd.service.in | 3 +--
38 + tools/Makefile.am | 13 ++-----------
39 + tools/libvirt-guests.service.in | 2 +-
40 + tools/libvirt-guests.sysconf | 7 +++++++
41 + 7 files changed, 15 insertions(+), 37 deletions(-)
42 +
43 +diff --git a/src/Makefile.am b/src/Makefile.am
44 +index 4a8cae11dc..6c93435066 100644
45 +--- a/src/Makefile.am
46 ++++ b/src/Makefile.am
47 +@@ -750,23 +750,6 @@ endif WITH_SETUID_RPC_CLIENT
48 +
49 + EXTRA_DIST += $(SYSCONF_FILES)
50 +
51 +-install-sysconfig:
52 +- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/sysconfig
53 +- for f in $(SYSCONF_FILES:%.sysconf=%) ; \
54 +- do \
55 +- tgt=`basename $$f`; \
56 +- $(INSTALL_DATA) $(srcdir)/$$f.sysconf \
57 +- $(DESTDIR)$(sysconfdir)/sysconfig/$$tgt; \
58 +- done
59 +-
60 +-uninstall-sysconfig:
61 +- for f in $(SYSCONF_FILES:%.sysconf=%) ; \
62 +- do \
63 +- tgt=`basename $$f`; \
64 +- rm -f $(DESTDIR)$(sysconfdir)/sysconfig/$$tgt; \
65 +- done
66 +- rmdir $(DESTDIR)$(sysconfdir)/sysconfig || :
67 +-
68 + LOGROTATE_FILES := $(LOGROTATE_FILES_IN:remote/%.in=%)
69 +
70 + EXTRA_DIST += $(LOGROTATE_FILES_IN)
71 +@@ -825,14 +808,14 @@ SYSTEMD_UNIT_FILES = $(notdir $(SYSTEMD_UNIT_FILES_IN:%.in=%))
72 + BUILT_SOURCES += $(SYSTEMD_UNIT_FILES)
73 + DISTCLEANFILES += $(SYSTEMD_UNIT_FILES)
74 +
75 +-install-systemd: $(SYSTEMD_UNIT_FILES) install-sysconfig
76 ++install-systemd: $(SYSTEMD_UNIT_FILES)
77 + $(MKDIR_P) $(DESTDIR)$(SYSTEMD_UNIT_DIR)
78 + for f in $(SYSTEMD_UNIT_FILES); \
79 + do \
80 + $(INSTALL_DATA) $$f $(DESTDIR)$(SYSTEMD_UNIT_DIR)/ ; \
81 + done
82 +
83 +-uninstall-systemd: uninstall-sysconfig
84 ++uninstall-systemd:
85 + rm -f $(SYSTEMD_UNIT_FILES:%=$(DESTDIR)$(SYSTEMD_UNIT_DIR)/%)
86 + rmdir $(DESTDIR)$(SYSTEMD_UNIT_DIR) || :
87 +
88 +diff --git a/src/locking/virtlockd.service.in b/src/locking/virtlockd.service.in
89 +index 3c9d587032..2449b201d9 100644
90 +--- a/src/locking/virtlockd.service.in
91 ++++ b/src/locking/virtlockd.service.in
92 +@@ -7,8 +7,7 @@ Documentation=man:virtlockd(8)
93 + Documentation=https://libvirt.org
94 +
95 + [Service]
96 +-EnvironmentFile=-/etc/sysconfig/virtlockd
97 +-ExecStart=@sbindir@/virtlockd $VIRTLOCKD_ARGS
98 ++ExecStart=@sbindir@/virtlockd
99 + ExecReload=/bin/kill -USR1 $MAINPID
100 + # Loosing the locks is a really bad thing that will
101 + # cause the machine to be fenced (rebooted), so make
102 +diff --git a/src/logging/virtlogd.service.in b/src/logging/virtlogd.service.in
103 +index 3d9ae36150..43736191d5 100644
104 +--- a/src/logging/virtlogd.service.in
105 ++++ b/src/logging/virtlogd.service.in
106 +@@ -7,8 +7,7 @@ Documentation=man:virtlogd(8)
107 + Documentation=https://libvirt.org
108 +
109 + [Service]
110 +-EnvironmentFile=-/etc/sysconfig/virtlogd
111 +-ExecStart=@sbindir@/virtlogd $VIRTLOGD_ARGS
112 ++ExecStart=@sbindir@/virtlogd
113 + ExecReload=/bin/kill -USR1 $MAINPID
114 + # Loosing the logs is a really bad thing that will
115 + # cause the machine to be fenced (rebooted), so make
116 +diff --git a/src/remote/libvirtd.service.in b/src/remote/libvirtd.service.in
117 +index 3ddf0e229b..a38f2b08fa 100644
118 +--- a/src/remote/libvirtd.service.in
119 ++++ b/src/remote/libvirtd.service.in
120 +@@ -20,12 +20,11 @@ Documentation=https://libvirt.org
121 +
122 + [Service]
123 + Type=notify
124 +-EnvironmentFile=-/etc/sysconfig/libvirtd
125 + # libvirtd.service is set to run on boot so that autostart of
126 + # VMs can be performed. We don't want it to stick around if
127 + # unused though, so we set a timeout. The socket activation
128 + # then ensures it gets started again if anything needs it
129 +-ExecStart=@sbindir@/libvirtd --timeout 120 $LIBVIRTD_ARGS
130 ++ExecStart=@sbindir@/libvirtd --timeout 120
131 + ExecReload=/bin/kill -HUP $MAINPID
132 + KillMode=process
133 + Restart=on-failure
134 +diff --git a/tools/Makefile.am b/tools/Makefile.am
135 +index 2807b9f6fd..cde5dba193 100644
136 +--- a/tools/Makefile.am
137 ++++ b/tools/Makefile.am
138 +@@ -334,15 +334,6 @@ install-data-local: install-systemd install-nss \
139 + uninstall-local: uninstall-systemd uninstall-nss \
140 + uninstall-bash-completion
141 +
142 +-install-sysconfig:
143 +- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/sysconfig
144 +- $(INSTALL_DATA) $(srcdir)/libvirt-guests.sysconf \
145 +- $(DESTDIR)$(sysconfdir)/sysconfig/libvirt-guests
146 +-
147 +-uninstall-sysconfig:
148 +- rm -f $(DESTDIR)$(sysconfdir)/sysconfig/libvirt-guests
149 +- rmdir $(DESTDIR)$(sysconfdir)/sysconfig ||:
150 +-
151 + EXTRA_DIST += libvirt-guests.sh.in
152 +
153 + libvirt-guests.sh: libvirt-guests.sh.in $(top_builddir)/config.status
154 +@@ -362,12 +353,12 @@ EXTRA_DIST += libvirt-guests.service.in
155 + SYSTEMD_UNIT_DIR = $(prefix)/lib/systemd/system
156 +
157 + if LIBVIRT_INIT_SCRIPT_SYSTEMD
158 +-install-systemd: libvirt-guests.service install-sysconfig libvirt-guests.sh
159 ++install-systemd: libvirt-guests.service libvirt-guests.sh
160 + $(MKDIR_P) $(DESTDIR)$(SYSTEMD_UNIT_DIR)
161 + $(INSTALL_DATA) libvirt-guests.service \
162 + $(DESTDIR)$(SYSTEMD_UNIT_DIR)/libvirt-guests.service
163 +
164 +-uninstall-systemd: uninstall-sysconfig
165 ++uninstall-systemd:
166 + rm -f $(DESTDIR)$(SYSTEMD_UNIT_DIR)/libvirt-guests.service
167 + rmdir $(DESTDIR)$(SYSTEMD_UNIT_DIR) ||:
168 +
169 +diff --git a/tools/libvirt-guests.service.in b/tools/libvirt-guests.service.in
170 +index 491ca62138..f0f417bffb 100644
171 +--- a/tools/libvirt-guests.service.in
172 ++++ b/tools/libvirt-guests.service.in
173 +@@ -10,7 +10,7 @@ Documentation=man:libvirtd(8)
174 + Documentation=https://libvirt.org
175 +
176 + [Service]
177 +-EnvironmentFile=-/etc/sysconfig/libvirt-guests
178 ++EnvironmentFile=-/etc/libvirt/libvirt-guests.conf
179 + # Hack just call traditional service until we factor
180 + # out the code
181 + ExecStart=@libexecdir@/libvirt-guests.sh start
182 +diff --git a/tools/libvirt-guests.sysconf b/tools/libvirt-guests.sysconf
183 +index 669b046507..45b0b9ea46 100644
184 +--- a/tools/libvirt-guests.sysconf
185 ++++ b/tools/libvirt-guests.sysconf
186 +@@ -1,3 +1,10 @@
187 ++#
188 ++# Warning: This configuration file is only sourced by the systemd
189 ++# libvirt-guests.service unit. The coresponding openrc facility is in
190 ++# /etc/init.d/libvirtd and /etc/conf.d/libvirtd
191 ++#
192 ++
193 ++
194 + # URIs to check for running guests
195 + # example: URIS='default xen:///system vbox+tcp://host/system lxc:///system'
196 + #URIS=default
197 +--
198 +2.21.0
199 +
200
201 diff --git a/app-emulation/libvirt/libvirt-9999.ebuild b/app-emulation/libvirt/libvirt-9999.ebuild
202 index 5c4936718f6..f12c9732aa3 100644
203 --- a/app-emulation/libvirt/libvirt-9999.ebuild
204 +++ b/app-emulation/libvirt/libvirt-9999.ebuild
205 @@ -122,7 +122,7 @@ DEPEND="${RDEPEND}
206 virtual/pkgconfig"
207
208 PATCHES=(
209 - "${FILESDIR}"/${PN}-5.2.0-do-not-use-sysconf.patch
210 + "${FILESDIR}"/${PN}-5.6.0-do-not-use-sysconf.patch
211 "${FILESDIR}"/${PN}-1.2.16-fix_paths_in_libvirt-guests_sh.patch
212 "${FILESDIR}"/${PN}-5.2.0-fix-paths-for-apparmor.patch
213 )