Gentoo Archives: gentoo-commits

From: "Anthony G. Basile" <blueness@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/musl:master commit in: sys-fs/lvm2/files/
Date: Mon, 27 Apr 2020 12:45:21
Message-Id: 1587991491.1869cd26ba6b5b19d011168f9f15170b77fcd7dc.blueness@gentoo
1 commit: 1869cd26ba6b5b19d011168f9f15170b77fcd7dc
2 Author: Petr Vaněk <arkamar <AT> atlas <DOT> cz>
3 AuthorDate: Sun Apr 26 11:07:21 2020 +0000
4 Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
5 CommitDate: Mon Apr 27 12:44:51 2020 +0000
6 URL: https://gitweb.gentoo.org/proj/musl.git/commit/?id=1869cd26
7
8 sys-fs/lvm2: clean unused files
9
10 Package-Manager: Portage-2.3.89, Repoman-2.3.20
11 Signed-off-by: Anthony G. Basile <blueness <AT> gentoo.org>
12
13 sys-fs/lvm2/files/dmeventd.initd-2.02.67-r1 | 25 ----
14 sys-fs/lvm2/files/lvm.confd-2.02.28-r2 | 5 -
15 sys-fs/lvm2/files/lvm.rc-2.02.172 | 149 --------------------
16 sys-fs/lvm2/files/lvm.rc-2.02.184-r3 | 154 ---------------------
17 ...183-implement-libc-specific-reopen_stream.patch | 24 ----
18 5 files changed, 357 deletions(-)
19
20 diff --git a/sys-fs/lvm2/files/dmeventd.initd-2.02.67-r1 b/sys-fs/lvm2/files/dmeventd.initd-2.02.67-r1
21 deleted file mode 100644
22 index 930e84b..0000000
23 --- a/sys-fs/lvm2/files/dmeventd.initd-2.02.67-r1
24 +++ /dev/null
25 @@ -1,25 +0,0 @@
26 -#!/sbin/openrc-run
27 -# Copyright 1999-2016 Gentoo Foundation
28 -# Distributed under the terms of the GNU General Public License v2
29 -
30 -PIDFILE=/run/dmeventd.pid
31 -BIN=/sbin/dmeventd
32 -
33 -depend() {
34 - # As of .67-r1, we call ALL lvm start/stop scripts with --sysinit, that
35 - # means dmeventd is NOT notified, as it cannot be safely running
36 - after lvm device-mapper
37 -}
38 -
39 -start() {
40 - ebegin "Starting dmeventd"
41 - start-stop-daemon --start --exec $BIN --pidfile $PIDFILE
42 - eend $?
43 -}
44 -
45 -stop() {
46 - ebegin "Stopping dmeventd"
47 - start-stop-daemon --stop --exec $BIN --pidfile $PIDFILE
48 - eend $?
49 -}
50 -
51
52 diff --git a/sys-fs/lvm2/files/lvm.confd-2.02.28-r2 b/sys-fs/lvm2/files/lvm.confd-2.02.28-r2
53 deleted file mode 100644
54 index 2fbd866..0000000
55 --- a/sys-fs/lvm2/files/lvm.confd-2.02.28-r2
56 +++ /dev/null
57 @@ -1,5 +0,0 @@
58 -# LVM should normally only be started after mdraid is available
59 -# this is because LVM physical volumes are very often MD devices.
60 -RC_AFTER="mdraid"
61 -
62 -# vim: ft=gentoo-conf-d
63
64 diff --git a/sys-fs/lvm2/files/lvm.rc-2.02.172 b/sys-fs/lvm2/files/lvm.rc-2.02.172
65 deleted file mode 100644
66 index 4bc363c..0000000
67 --- a/sys-fs/lvm2/files/lvm.rc-2.02.172
68 +++ /dev/null
69 @@ -1,149 +0,0 @@
70 -#!/sbin/openrc-run
71 -# Copyright 1999-2018 Gentoo Authors
72 -# Distributed under the terms of the GNU General Public License v2
73 -
74 -_get_lvm_path() {
75 - local lvm_path=
76 - for lvm_path in /bin/lvm /sbin/lvm ; do
77 - [ -x "$lvm_path" ] && break
78 - done
79 - echo "${lvm_path}"
80 -}
81 -
82 -_need_lvmetad()
83 -{
84 - local lvm_path="$(_get_lvm_path)"
85 - [ ! -x "${lvm_path}" ] && return 1
86 - ${lvm_path} dumpconfig global 2>/dev/null | grep -q 'use_lvmetad=1'
87 -}
88 -
89 -_need_lvmlockd()
90 -{
91 - local lvm_path="$(_get_lvm_path)"
92 - [ ! -x "${lvm_path}" ] && return 1
93 - ${lvm_path} dumpconfig global 2>/dev/null | grep -q 'use_lvmlockd=1'
94 -}
95 -
96 -depend() {
97 - before checkfs fsck
98 - after modules device-mapper
99 - # We may use lvmetad based on the configuration. If we added lvmetad
100 - # support while lvm2 is running then we aren't dependent on it. For the
101 - # more common case, if its disabled in the config we aren't dependent
102 - # on it.
103 - config /etc/lvm/lvm.conf
104 - local _need=
105 - if service_started; then
106 - _need=$(service_get_value need)
107 - else
108 - if _need_lvmetad; then
109 - _need="${_need} lvmetad"
110 - fi
111 - if _need_lvmlockd; then
112 - _need="${_need} lvmlockd"
113 - fi
114 - fi
115 - need sysfs ${_need}
116 -}
117 -
118 -config='global { locking_dir = "/run/lock/lvm" }'
119 -
120 -dm_in_proc() {
121 - local retval=0
122 - for x in devices misc ; do
123 - grep -qs 'device-mapper' /proc/${x}
124 - retval=$((${retval} + $?))
125 - done
126 - return ${retval}
127 -}
128 -
129 -start() {
130 - # LVM support for /usr, /home, /opt ....
131 - # This should be done *before* checking local
132 - # volumes, or they never get checked.
133 -
134 - # NOTE: Add needed modules for LVM or RAID, etc
135 - # to /etc/modules.autoload if needed
136 - lvm_path="$(_get_lvm_path)"
137 - for lvm_path in /bin/lvm /sbin/lvm ; do
138 - [ -x "$lvm_path" ] && break
139 - done
140 - if [ ! -x "$lvm_path" ]; then
141 - eerror "Cannot find lvm binary in /sbin or /bin!"
142 - return 1
143 - fi
144 - if [ -z "${CDBOOT}" ] ; then
145 - if [ -e /proc/modules ] && ! dm_in_proc ; then
146 - modprobe dm-mod 2>/dev/null
147 - fi
148 - if [ -d /proc/lvm ] || dm_in_proc ; then
149 - ebegin "Setting up the Logical Volume Manager"
150 - #still echo stderr for debugging
151 - lvm_commands="#!${lvm_path}\n"
152 - # Extra PV find pass because some devices might not have been available until very recently
153 - lvm_commands="${lvm_commands}pvscan --config '${config}'\n"
154 - # Now make the nodes
155 - lvm_commands="${lvm_commands}vgscan --config '${config}' --mknodes\n"
156 - # And turn them on!
157 - lvm_commands="${lvm_commands}vgchange --config '${config}' --sysinit -a ly\n"
158 - if _need_lvmlockd; then
159 - # Start lockd VGs as required
160 - lvm_commands="${lvm_commands}vgchange --config '${config}' --lock-start --lock-opt auto\n"
161 - fi
162 - # Order of this is important, have to work around dash and LVM readline
163 - printf "%b\n" "${lvm_commands}" | $lvm_path /proc/self/fd/0 >/dev/null
164 - eend $? "Failed to setup the LVM"
165 - fi
166 - fi
167 -}
168 -
169 -start_post()
170 -{
171 - # Save if we needed lvmetad
172 - if _need_lvmetad; then
173 - service_set_value need lvmetad
174 - fi
175 -}
176 -
177 -stop() {
178 - for lvm_path in /bin/lvm /sbin/lvm ; do
179 - [ -x "$lvm_path" ] && break
180 - done
181 - if [ ! -x "$lvm_path" ]; then
182 - eerror "Cannot find lvm binary in /sbin or /bin!"
183 - return 1
184 - fi
185 -
186 - # Stop LVM2
187 - if [ -x /sbin/vgs ] && \
188 - [ -x /sbin/vgchange ] && \
189 - [ -x /sbin/lvchange ] && \
190 - [ -f /etc/lvmtab -o -d /etc/lvm ] && \
191 - [ -d /proc/lvm -o "`grep device-mapper /proc/misc 2>/dev/null`" ]
192 - then
193 - einfo "Shutting down the Logical Volume Manager"
194 -
195 - VGS=$($lvm_path vgs --config "${config}" -o vg_name --noheadings --nosuffix --rows 2> /dev/null)
196 -
197 - if [ "$VGS" ]
198 - then
199 - local _ending="eend"
200 - [ "$RC_RUNLEVEL" = shutdown ] && _ending="ewend"
201 - ebegin " Shutting Down LVs & VGs"
202 - #still echo stderr for debugging
203 - lvm_commands="#!${lvm_path}\n"
204 - # Extra PV find pass because some devices might not have been available until very recently
205 - lvm_commands="${lvm_commands}lvchange --config '${config}' --sysinit -a ln ${VGS}\n"
206 - # Now make the nodes
207 - lvm_commands="${lvm_commands}vgchange --config '${config}' --sysinit -a ln ${VGS}\n"
208 - # Order of this is important, have to work around dash and LVM readline
209 - printf "%b\n" "${lvm_commands}" | $lvm_path /proc/self/fd/0 --config "${config}" >/dev/null
210 - ${_ending} $? "Failed (possibly some LVs still needed for /usr or root)"
211 - fi
212 -
213 - einfo "Finished shutting down the Logical Volume Manager"
214 - return 0
215 - fi
216 -}
217 -
218 -# vim:ts=4
219
220 diff --git a/sys-fs/lvm2/files/lvm.rc-2.02.184-r3 b/sys-fs/lvm2/files/lvm.rc-2.02.184-r3
221 deleted file mode 100644
222 index b48efb0..0000000
223 --- a/sys-fs/lvm2/files/lvm.rc-2.02.184-r3
224 +++ /dev/null
225 @@ -1,154 +0,0 @@
226 -#!/sbin/openrc-run
227 -# Copyright 1999-2019 Gentoo Authors
228 -# Distributed under the terms of the GNU General Public License v2
229 -
230 -_get_lvm_path() {
231 - local lvm_path=
232 - for lvm_path in /bin/lvm /sbin/lvm ; do
233 - [ -x "$lvm_path" ] && break
234 - done
235 - echo "${lvm_path}"
236 -}
237 -
238 -_need_lvmetad()
239 -{
240 - local lvm_path="$(_get_lvm_path)"
241 - [ ! -x "${lvm_path}" ] && return 1
242 - ${lvm_path} dumpconfig global 2>/dev/null | grep -q 'use_lvmetad=1'
243 -}
244 -
245 -_need_lvmlockd()
246 -{
247 - local lvm_path="$(_get_lvm_path)"
248 - [ ! -x "${lvm_path}" ] && return 1
249 - ${lvm_path} dumpconfig global 2>/dev/null | grep -q 'use_lvmlockd=1'
250 -}
251 -
252 -depend() {
253 - before checkfs fsck
254 - after modules device-mapper
255 - # We may use lvmetad based on the configuration. If we added lvmetad
256 - # support while lvm2 is running then we aren't dependent on it. For the
257 - # more common case, if its disabled in the config we aren't dependent
258 - # on it.
259 - config /etc/lvm/lvm.conf
260 - local _need=
261 - if service_started; then
262 - _need=$(service_get_value need)
263 - else
264 - if _need_lvmetad; then
265 - _need="${_need} lvmetad"
266 - fi
267 - if _need_lvmlockd; then
268 - _need="${_need} lvmlockd"
269 - fi
270 - fi
271 - # Make sure you review /etc/conf.d/lvm as well!
272 - # Depending on your system, it might also introduce udev & mdraid
273 - need sysfs ${_need}
274 -}
275 -
276 -config='global { locking_dir = "/run/lock/lvm" }'
277 -
278 -dm_in_proc() {
279 - local retval=0
280 - for x in devices misc ; do
281 - grep -qs 'device-mapper' /proc/${x}
282 - retval=$((${retval} + $?))
283 - done
284 - return ${retval}
285 -}
286 -
287 -start() {
288 - # LVM support for /usr, /home, /opt ....
289 - # This should be done *before* checking local
290 - # volumes, or they never get checked.
291 -
292 - # NOTE: Add needed modules for LVM or RAID, etc
293 - # to /etc/modules.autoload if needed
294 - lvm_path="$(_get_lvm_path)"
295 - for lvm_path in /bin/lvm /sbin/lvm ; do
296 - [ -x "$lvm_path" ] && break
297 - done
298 - if [ ! -x "$lvm_path" ]; then
299 - eerror "Cannot find lvm binary in /sbin or /bin!"
300 - return 1
301 - fi
302 - if [ -z "${CDBOOT}" ] ; then
303 - if [ -e /proc/modules ] && ! dm_in_proc ; then
304 - modprobe dm-mod 2>/dev/null
305 - fi
306 - if [ -d /proc/lvm ] || dm_in_proc ; then
307 - ebegin "Setting up the Logical Volume Manager"
308 - #still echo stderr for debugging
309 - lvm_commands="#!${lvm_path}\n"
310 - # Extra PV find pass because some devices might not have been available until very recently
311 - lvm_commands="${lvm_commands}pvscan --config '${config}'\n"
312 - # Now make the nodes
313 - lvm_commands="${lvm_commands}vgscan --config '${config}' --mknodes\n"
314 - # And turn them on!
315 - lvm_commands="${lvm_commands}vgchange --config '${config}' --sysinit -a ly\n"
316 - if _need_lvmlockd; then
317 - # Start lockd VGs as required
318 - lvm_commands="${lvm_commands}vgchange --config '${config}' --lock-start --lock-opt auto\n"
319 - fi
320 - # Order of this is important, have to work around dash and LVM readline
321 - printf "%b\n" "${lvm_commands}" | $lvm_path /proc/self/fd/0 >/dev/null
322 - eend $? "Failed to setup the LVM"
323 - fi
324 - fi
325 -}
326 -
327 -start_post()
328 -{
329 - # Save if we needed lvmetad
330 - if _need_lvmetad; then
331 - service_set_value need lvmetad
332 - fi
333 -}
334 -
335 -stop() {
336 - for lvm_path in /bin/lvm /sbin/lvm ; do
337 - [ -x "$lvm_path" ] && break
338 - done
339 - if [ ! -x "$lvm_path" ]; then
340 - eerror "Cannot find lvm binary in /sbin or /bin!"
341 - return 1
342 - fi
343 -
344 - # Stop LVM2
345 - if [ -x /sbin/vgs ] && \
346 - [ -x /sbin/vgchange ] && \
347 - [ -x /sbin/lvchange ] && \
348 - [ -f /etc/lvmtab -o -d /etc/lvm ] && \
349 - [ -d /proc/lvm -o "`grep device-mapper /proc/misc 2>/dev/null`" ]
350 - then
351 - einfo "Shutting down the Logical Volume Manager"
352 -
353 - VGS=$($lvm_path vgs --config "${config}" -o vg_name --noheadings --nosuffix --rows 2> /dev/null)
354 -
355 - if [ "$VGS" ]
356 - then
357 - local _ending="eend"
358 - [ "$RC_RUNLEVEL" = shutdown ] && _ending="ewend"
359 - ebegin " Shutting Down LVs & VGs"
360 - #still echo stderr for debugging
361 - lvm_commands="#!${lvm_path}\n"
362 - # Extra PV find pass because some devices might not have been available until very recently
363 - lvm_commands="${lvm_commands}lvchange --config '${config}' --sysinit -a ln ${VGS}\n"
364 - # Now make the nodes
365 - lvm_commands="${lvm_commands}vgchange --config '${config}' --sysinit -a ln ${VGS}\n"
366 - # Order of this is important, have to work around dash and LVM readline
367 - printf "%b\n" "${lvm_commands}" | $lvm_path /proc/self/fd/0 --config "${config}" >/dev/null
368 - rc=$?
369 - msg="Failed (possibly some LVs still needed for /usr or root)"
370 - [ "$RC_RUNLEVEL" = shutdown ] && msg="${msg} [rc=$rc]" && rc=0
371 - ${_ending} $rc "${msg}"
372 - fi
373 -
374 - einfo "Finished shutting down the Logical Volume Manager"
375 - return 0
376 - fi
377 -}
378 -
379 -# vim:ts=4
380
381 diff --git a/sys-fs/lvm2/files/lvm2-2.02.183-implement-libc-specific-reopen_stream.patch b/sys-fs/lvm2/files/lvm2-2.02.183-implement-libc-specific-reopen_stream.patch
382 deleted file mode 100644
383 index 6034be3..0000000
384 --- a/sys-fs/lvm2/files/lvm2-2.02.183-implement-libc-specific-reopen_stream.patch
385 +++ /dev/null
386 @@ -1,24 +0,0 @@
387 -diff --git a/lib/log/log.c b/lib/log/log.c
388 -index 79fbd7a..0999d10 100644
389 ---- a/lib/log/log.c
390 -+++ b/lib/log/log.c
391 -@@ -161,6 +161,7 @@ static void _check_and_replace_standard_log_streams(FILE *old_stream, FILE *new_
392 - * Close and reopen standard stream on file descriptor fd.
393 - */
394 - int reopen_standard_stream(FILE **stream, const char *mode)
395 -+#ifdef __GLIBC__
396 - {
397 - int fd, fd_copy, new_fd;
398 - const char *name;
399 -@@ -207,6 +208,11 @@ int reopen_standard_stream(FILE **stream, const char *mode)
400 - *stream = new_stream;
401 - return 1;
402 - }
403 -+#else
404 -+{
405 -+ return (freopen(NULL, mode, *stream) != NULL);
406 -+}
407 -+#endif
408 -
409 - void init_log_fn(lvm2_log_fn_t log_fn)
410 - {