1 |
commit: 3bdaffb1d7782f5223b0739933f141d82c1c70b2 |
2 |
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu May 4 18:58:18 2017 +0000 |
4 |
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu May 4 18:58:31 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3bdaffb1 |
7 |
|
8 |
sys-fs/lvm2: bump per bug #602872. |
9 |
|
10 |
Package-Manager: portage-2.3.3 |
11 |
Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org> |
12 |
|
13 |
sys-fs/lvm2/Manifest | 1 + |
14 |
sys-fs/lvm2/lvm2-2.02.171.ebuild | 297 +++++++++++++++++++++++++++++++++++++++ |
15 |
2 files changed, 298 insertions(+) |
16 |
|
17 |
diff --git a/sys-fs/lvm2/Manifest b/sys-fs/lvm2/Manifest |
18 |
index 16a2de5aa63..1875a4de597 100644 |
19 |
--- a/sys-fs/lvm2/Manifest |
20 |
+++ b/sys-fs/lvm2/Manifest |
21 |
@@ -3,3 +3,4 @@ DIST LVM2.2.02.136.tgz 1891010 SHA256 c6af90097d8f7cd851d38c4f57bb3ad7039cfa123f |
22 |
DIST LVM2.2.02.139.tgz 1897293 SHA256 f423b1f2eee70efd671afc0982caa92e9413a582404057244021314172ec3a07 SHA512 f112207d7447606915026495b931bffc4c0d68d36b9a8792fe4b7abf8b743bc4559da5c79145cb4d457337118e60552f9df511e31f2799001d29d006f7946cc0 WHIRLPOOL 8a1ca0bb6946b1f6761223a4a9e7c5e3e5247ff4b85bc08734258f4616fbabb0ea7a3b22b4a245367997ad810b4b304b747d8da0bd128c241fbafe645855b7f9 |
23 |
DIST LVM2.2.02.145.tgz 1986370 SHA256 98b7c4c07c485a462c6a86e1a5265757133ceea36289ead8a419af29ef39560b SHA512 84e28b3efc940837ea9da70fce620744aea0945ba29383b76ad7bcd4b5259b897c714162a8e8b7cfe26ae736a3ad2eca633a3e0df4d6280a32b28bd4cf472d27 WHIRLPOOL b8c6f4b737625547d4c2994d055f3334e2954f160d10840f1405b6a78f25fc17ba1d270f574408c151140e2afceb007cbfa1c146ed105bbdeca001a03368d549 |
24 |
DIST LVM2.2.02.166.tgz 2148324 SHA256 e120b066b85b224552efda40204488c5123de068725676fd6e5c8bc655051b94 SHA512 8bebe9b474f791b5edf5366b0bd24861fbbaf8a83afa2a9e2a8e3917e05e4ecbf6877f018be03ffb4e9b4c8832208264165b85182bf79a07661adf35128b4a21 WHIRLPOOL a4c2e0b2e8da85301b2518b35193304436715fdf45cbc7bc28fd6f7b88af15e611134d5a530d2311b23544aa67c3a7f13fd3780d4d46fc10854e624fb8b27870 |
25 |
+DIST LVM2.2.02.171.tgz 2333643 SHA256 b815a711a2fabaa5c3dc1a4a284df0268bf0f325f0fc0f5c9530c9bbb54b9964 SHA512 801adcc2ae483f81edf6bfba73090b6b8f710370e48764f08a62da71d617157075bea01593c2535ad5ba71dcb5e0cfe83cec9a65180a6e8b9e0d214bdee79883 WHIRLPOOL fedd62612c6bb4b7764277a0d4474ff3557f041858c71eb7bf2a1c06b646637fe719f91a12c1b5c58ccefa7f4d2daba6bf30409340c52fd3a1b8b01ce62467ab |
26 |
|
27 |
diff --git a/sys-fs/lvm2/lvm2-2.02.171.ebuild b/sys-fs/lvm2/lvm2-2.02.171.ebuild |
28 |
new file mode 100644 |
29 |
index 00000000000..6ce42856b02 |
30 |
--- /dev/null |
31 |
+++ b/sys-fs/lvm2/lvm2-2.02.171.ebuild |
32 |
@@ -0,0 +1,297 @@ |
33 |
+# Copyright 1999-2017 Gentoo Foundation |
34 |
+# Distributed under the terms of the GNU General Public License v2 |
35 |
+ |
36 |
+EAPI=6 |
37 |
+inherit autotools eutils linux-info multilib systemd toolchain-funcs udev flag-o-matic |
38 |
+ |
39 |
+DESCRIPTION="User-land utilities for LVM2 (device-mapper) software" |
40 |
+HOMEPAGE="https://sourceware.org/lvm2/" |
41 |
+SRC_URI="ftp://sourceware.org/pub/lvm2/${PN/lvm/LVM}.${PV}.tgz |
42 |
+ ftp://sourceware.org/pub/lvm2/old/${PN/lvm/LVM}.${PV}.tgz" |
43 |
+ |
44 |
+LICENSE="GPL-2" |
45 |
+SLOT="0" |
46 |
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux" |
47 |
+IUSE="readline static static-libs systemd clvm cman corosync lvm1 lvm2create_initrd openais sanlock selinux +udev +thin device-mapper-only" |
48 |
+REQUIRED_USE="device-mapper-only? ( !clvm !cman !corosync !lvm1 !lvm2create_initrd !openais !sanlock !thin ) |
49 |
+ systemd? ( udev ) |
50 |
+ clvm? ( !systemd )" |
51 |
+ |
52 |
+DEPEND_COMMON=" |
53 |
+ clvm? ( |
54 |
+ cman? ( =sys-cluster/cman-3* ) |
55 |
+ corosync? ( sys-cluster/corosync ) |
56 |
+ openais? ( sys-cluster/openais ) |
57 |
+ =sys-cluster/libdlm-3* |
58 |
+ ) |
59 |
+ |
60 |
+ readline? ( sys-libs/readline:0= ) |
61 |
+ sanlock? ( sys-cluster/sanlock ) |
62 |
+ systemd? ( >=sys-apps/systemd-205:0= ) |
63 |
+ udev? ( >=virtual/libudev-208:=[static-libs?] )" |
64 |
+# /run is now required for locking during early boot. /var cannot be assumed to |
65 |
+# be available -- thus, pull in recent enough baselayout for /run. |
66 |
+# This version of LVM is incompatible with cryptsetup <1.1.2. |
67 |
+RDEPEND="${DEPEND_COMMON} |
68 |
+ >=sys-apps/baselayout-2.2 |
69 |
+ !<sys-apps/openrc-0.11 |
70 |
+ !<sys-fs/cryptsetup-1.1.2 |
71 |
+ !!sys-fs/clvm |
72 |
+ !!sys-fs/lvm-user |
73 |
+ >=sys-apps/util-linux-2.16 |
74 |
+ lvm2create_initrd? ( sys-apps/makedev ) |
75 |
+ thin? ( >=sys-block/thin-provisioning-tools-0.3.0 )" |
76 |
+# note: thin- 0.3.0 is required to avoid --disable-thin_check_needs_check |
77 |
+# USE 'static' currently only works with eudev, bug 520450 |
78 |
+DEPEND="${DEPEND_COMMON} |
79 |
+ virtual/pkgconfig |
80 |
+ >=sys-devel/binutils-2.20.1-r1 |
81 |
+ sys-devel/autoconf-archive |
82 |
+ static? ( |
83 |
+ selinux? ( sys-libs/libselinux[static-libs] ) |
84 |
+ udev? ( >=sys-fs/eudev-3.1.2[static-libs] ) |
85 |
+ >=sys-apps/util-linux-2.16[static-libs] |
86 |
+ )" |
87 |
+ |
88 |
+S=${WORKDIR}/${PN/lvm/LVM}.${PV} |
89 |
+ |
90 |
+PATCHES=( |
91 |
+ # Gentoo specific modification(s): |
92 |
+ "${FILESDIR}"/${PN}-2.02.129-example.conf.in.patch |
93 |
+ |
94 |
+ # For upstream -- review and forward: |
95 |
+ "${FILESDIR}"/${PN}-2.02.63-always-make-static-libdm.patch |
96 |
+ "${FILESDIR}"/${PN}-2.02.56-lvm2create_initrd.patch |
97 |
+ "${FILESDIR}"/${PN}-2.02.67-createinitrd.patch #301331 |
98 |
+ "${FILESDIR}"/${PN}-2.02.99-locale-muck.patch #330373 |
99 |
+ "${FILESDIR}"/${PN}-2.02.70-asneeded.patch # -Wl,--as-needed |
100 |
+ "${FILESDIR}"/${PN}-2.02.139-dynamic-static-ldflags.patch #332905 |
101 |
+ "${FILESDIR}"/${PN}-2.02.129-static-pkgconfig-libs.patch #370217, #439414 + blkid |
102 |
+ "${FILESDIR}"/${PN}-2.02.130-pthread-pkgconfig.patch #492450 |
103 |
+ #"${FILESDIR}"/${PN}-2.02.145-mkdev.patch #580062 # Merged upstream |
104 |
+) |
105 |
+ |
106 |
+pkg_setup() { |
107 |
+ local CONFIG_CHECK="~SYSVIPC" |
108 |
+ |
109 |
+ if use udev; then |
110 |
+ local WARNING_SYSVIPC="CONFIG_SYSVIPC:\tis not set (required for udev sync)\n" |
111 |
+ if linux_config_exists; then |
112 |
+ local uevent_helper_path=$(linux_chkconfig_string UEVENT_HELPER_PATH) |
113 |
+ if [ -n "${uevent_helper_path}" ] && [ "${uevent_helper_path}" != '""' ]; then |
114 |
+ ewarn "It's recommended to set an empty value to the following kernel config option:" |
115 |
+ ewarn "CONFIG_UEVENT_HELPER_PATH=${uevent_helper_path}" |
116 |
+ fi |
117 |
+ fi |
118 |
+ fi |
119 |
+ |
120 |
+ check_extra_config |
121 |
+ |
122 |
+ # 1. Genkernel no longer copies /sbin/lvm blindly. |
123 |
+ if use static; then |
124 |
+ elog "Warning, we no longer overwrite /sbin/lvm and /sbin/dmsetup with" |
125 |
+ elog "their static versions. If you need the static binaries," |
126 |
+ elog "you must append .static to the filename!" |
127 |
+ fi |
128 |
+} |
129 |
+ |
130 |
+src_prepare() { |
131 |
+ default |
132 |
+ |
133 |
+ sed -i \ |
134 |
+ -e "1iAR = $(tc-getAR)" \ |
135 |
+ -e "s:CC ?= @CC@:CC = $(tc-getCC):" \ |
136 |
+ make.tmpl.in || die #444082 |
137 |
+ |
138 |
+ sed -i -e '/FLAG/s:-O2::' configure{.in,} || die #480212 |
139 |
+ |
140 |
+ if use udev && ! use device-mapper-only; then |
141 |
+ sed -i -e '/use_lvmetad =/s:0:1:' conf/example.conf.in || die #514196 |
142 |
+ elog "Notice that \"use_lvmetad\" setting is enabled with USE=\"udev\" in" |
143 |
+ elog "/etc/lvm/lvm.conf, which will require restart of udev, lvm, and lvmetad" |
144 |
+ elog "if it was previously disabled." |
145 |
+ fi |
146 |
+ |
147 |
+ sed -i -e "s:/usr/bin/true:$(type -P true):" scripts/blk_availability_systemd_red_hat.service.in || die #517514 |
148 |
+ |
149 |
+ # Without thin-privision-tools, there is nothing to install for target install_man7: |
150 |
+ use thin || { sed -i -e '/^install_lvm2/s:install_man7::' man/Makefile.in || die; } |
151 |
+ |
152 |
+ eautoreconf |
153 |
+} |
154 |
+ |
155 |
+src_configure() { |
156 |
+ filter-flags -flto |
157 |
+ local myconf=() |
158 |
+ local buildmode |
159 |
+ |
160 |
+ myconf+=( $(use_enable !device-mapper-only dmeventd) ) |
161 |
+ myconf+=( $(use_enable !device-mapper-only cmdlib) ) |
162 |
+ myconf+=( $(use_enable !device-mapper-only applib) ) |
163 |
+ myconf+=( $(use_enable !device-mapper-only fsadm) ) |
164 |
+ myconf+=( $(use_enable !device-mapper-only lvmetad) ) |
165 |
+ use device-mapper-only && myconf+=( --disable-udev-systemd-background-jobs ) |
166 |
+ |
167 |
+ # Most of this package does weird stuff. |
168 |
+ # The build options are tristate, and --without is NOT supported |
169 |
+ # options: 'none', 'internal', 'shared' |
170 |
+ if use static; then |
171 |
+ buildmode="internal" |
172 |
+ # This only causes the .static versions to become available |
173 |
+ myconf+=( --enable-static_link ) |
174 |
+ else |
175 |
+ buildmode="shared" |
176 |
+ fi |
177 |
+ dmbuildmode=$(use !device-mapper-only && echo internal || echo none) |
178 |
+ |
179 |
+ # dmeventd requires mirrors to be internal, and snapshot available |
180 |
+ # so we cannot disable them |
181 |
+ myconf+=( --with-mirrors=${dmbuildmode} ) |
182 |
+ myconf+=( --with-snapshots=${dmbuildmode} ) |
183 |
+ if use thin; then |
184 |
+ myconf+=( --with-thin=internal --with-cache=internal ) |
185 |
+ local texec |
186 |
+ for texec in check dump repair restore; do |
187 |
+ myconf+=( --with-thin-${texec}="${EPREFIX}"/sbin/thin_${texec} ) |
188 |
+ myconf+=( --with-cache-${texec}="${EPREFIX}"/sbin/cache_${texec} ) |
189 |
+ done |
190 |
+ else |
191 |
+ myconf+=( --with-thin=none --with-cache=none ) |
192 |
+ fi |
193 |
+ |
194 |
+ if use lvm1; then |
195 |
+ myconf+=( --with-lvm1=${buildmode} ) |
196 |
+ else |
197 |
+ myconf+=( --with-lvm1=none ) |
198 |
+ fi |
199 |
+ |
200 |
+ # disable O_DIRECT support on hppa, breaks pv detection (#99532) |
201 |
+ use hppa && myconf+=( --disable-o_direct ) |
202 |
+ |
203 |
+ if use clvm; then |
204 |
+ myconf+=( --with-cluster=${buildmode} ) |
205 |
+ # 4-state! Make sure we get it right, per bug 210879 |
206 |
+ # Valid options are: none, cman, gulm, all |
207 |
+ # |
208 |
+ # 2009/02: |
209 |
+ # gulm is removed now, now dual-state: |
210 |
+ # cman, none |
211 |
+ # all still exists, but is not needed |
212 |
+ # |
213 |
+ # 2009/07: |
214 |
+ # TODO: add corosync and re-enable ALL |
215 |
+ local clvmd="" |
216 |
+ use cman && clvmd="cman" |
217 |
+ #clvmd="${clvmd/cmangulm/all}" |
218 |
+ use corosync && clvmd="${clvmd:+$clvmd,}corosync" |
219 |
+ use openais && clvmd="${clvmd:+$clvmd,}openais" |
220 |
+ [ -z "${clvmd}" ] && clvmd="none" |
221 |
+ myconf+=( --with-clvmd=${clvmd} ) |
222 |
+ myconf+=( --with-pool=${buildmode} ) |
223 |
+ myconf+=( --enable-lvmlockd-dlm ) |
224 |
+ else |
225 |
+ myconf+=( --with-clvmd=none --with-cluster=none ) |
226 |
+ fi |
227 |
+ |
228 |
+ econf \ |
229 |
+ $(use_enable readline) \ |
230 |
+ $(use_enable selinux) \ |
231 |
+ --enable-pkgconfig \ |
232 |
+ --with-confdir="${EPREFIX}"/etc \ |
233 |
+ --exec-prefix="${EPREFIX}" \ |
234 |
+ --sbindir="${EPREFIX}/sbin" \ |
235 |
+ --with-staticdir="${EPREFIX}"/sbin \ |
236 |
+ --libdir="${EPREFIX}/$(get_libdir)" \ |
237 |
+ --with-usrlibdir="${EPREFIX}/usr/$(get_libdir)" \ |
238 |
+ --with-default-dm-run-dir=/run \ |
239 |
+ --with-default-run-dir=/run/lvm \ |
240 |
+ --with-default-locking-dir=/run/lock/lvm \ |
241 |
+ --with-default-pid-dir=/run \ |
242 |
+ $(use_enable udev udev_rules) \ |
243 |
+ $(use_enable udev udev_sync) \ |
244 |
+ $(use_with udev udevdir "$(get_udevdir)"/rules.d) \ |
245 |
+ $(use_enable sanlock lvmlockd-sanlock) \ |
246 |
+ $(use_enable systemd udev-systemd-background-jobs) \ |
247 |
+ --with-systemdsystemunitdir="$(systemd_get_systemunitdir)" \ |
248 |
+ ${myconf[@]} \ |
249 |
+ CLDFLAGS="${LDFLAGS}" |
250 |
+} |
251 |
+ |
252 |
+src_compile() { |
253 |
+ pushd include >/dev/null |
254 |
+ emake |
255 |
+ popd >/dev/null |
256 |
+ |
257 |
+ if use device-mapper-only ; then |
258 |
+ emake device-mapper |
259 |
+ else |
260 |
+ emake |
261 |
+ emake CC="$(tc-getCC)" -C scripts lvm2_activation_generator_systemd_red_hat |
262 |
+ fi |
263 |
+} |
264 |
+ |
265 |
+src_install() { |
266 |
+ local inst |
267 |
+ INSTALL_TARGETS="install install_tmpfiles_configuration" |
268 |
+ # install systemd related files only when requested, bug #522430 |
269 |
+ use systemd && INSTALL_TARGETS="${INSTALL_TARGETS} install_systemd_units install_systemd_generators" |
270 |
+ use device-mapper-only && INSTALL_TARGETS="install_device-mapper" |
271 |
+ for inst in ${INSTALL_TARGETS}; do |
272 |
+ emake DESTDIR="${D}" ${inst} |
273 |
+ done |
274 |
+ |
275 |
+ newinitd "${FILESDIR}"/device-mapper.rc-2.02.105-r2 device-mapper |
276 |
+ newconfd "${FILESDIR}"/device-mapper.conf-1.02.22-r3 device-mapper |
277 |
+ |
278 |
+ if use !device-mapper-only ; then |
279 |
+ newinitd "${FILESDIR}"/dmeventd.initd-2.02.67-r1 dmeventd |
280 |
+ newinitd "${FILESDIR}"/lvm.rc-2.02.166-r2 lvm |
281 |
+ newconfd "${FILESDIR}"/lvm.confd-2.02.28-r2 lvm |
282 |
+ |
283 |
+ newinitd "${FILESDIR}"/lvm-monitoring.initd-2.02.105-r2 lvm-monitoring |
284 |
+ newinitd "${FILESDIR}"/lvmetad.initd-2.02.116-r3 lvmetad |
285 |
+ fi |
286 |
+ |
287 |
+ if use sanlock; then |
288 |
+ newinitd "${FILESDIR}"/lvmlockd.initd-2.02.166-r1 lvmlockd |
289 |
+ fi |
290 |
+ |
291 |
+ if use clvm; then |
292 |
+ newinitd "${FILESDIR}"/clvmd.rc-2.02.39 clvmd |
293 |
+ newconfd "${FILESDIR}"/clvmd.confd-2.02.39 clvmd |
294 |
+ fi |
295 |
+ |
296 |
+ if use static-libs; then |
297 |
+ dolib.a libdm/ioctl/libdevmapper.a |
298 |
+ dolib.a libdaemon/client/libdaemonclient.a #462908 |
299 |
+ #gen_usr_ldscript libdevmapper.so |
300 |
+ dolib.a daemons/dmeventd/libdevmapper-event.a |
301 |
+ #gen_usr_ldscript libdevmapper-event.so |
302 |
+ else |
303 |
+ rm -f "${ED}"usr/$(get_libdir)/{libdevmapper-event,liblvm2cmd,liblvm2app,libdevmapper}.a |
304 |
+ fi |
305 |
+ |
306 |
+ if use lvm2create_initrd; then |
307 |
+ dosbin scripts/lvm2create_initrd/lvm2create_initrd |
308 |
+ doman scripts/lvm2create_initrd/lvm2create_initrd.8 |
309 |
+ newdoc scripts/lvm2create_initrd/README README.lvm2create_initrd |
310 |
+ fi |
311 |
+ |
312 |
+ insinto /etc |
313 |
+ doins "${FILESDIR}"/dmtab |
314 |
+ |
315 |
+ dodoc README VERSION* WHATS_NEW WHATS_NEW_DM doc/*.{c,txt} conf/*.conf |
316 |
+} |
317 |
+ |
318 |
+pkg_postinst() { |
319 |
+ ewarn "Make sure the \"lvm\" init script is in the runlevels:" |
320 |
+ ewarn "# rc-update add lvm boot" |
321 |
+ ewarn |
322 |
+ ewarn "Make sure to enable lvmetad in /etc/lvm/lvm.conf if you want" |
323 |
+ ewarn "to enable lvm autoactivation and metadata caching." |
324 |
+} |
325 |
+ |
326 |
+src_test() { |
327 |
+ einfo "Tests are disabled because of device-node mucking, if you want to" |
328 |
+ einfo "run tests, compile the package and see ${S}/tests" |
329 |
+} |