summaryrefslogtreecommitdiff
path: root/sys-fs/lvm2
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2021-05-11 19:55:43 +0100
committerV3n3RiX <venerix@redcorelinux.org>2021-05-11 19:55:43 +0100
commit185fa19bbf68a4d4dca534d2b46729207a177f16 (patch)
treea8a537b82fda83a0799c2ca9887f212558363aa7 /sys-fs/lvm2
parentc8fd0d84af0bfd1949542adc2cbb735b1d28f9ed (diff)
gentoo resync : 11.05.2021
Diffstat (limited to 'sys-fs/lvm2')
-rw-r--r--sys-fs/lvm2/Manifest10
-rw-r--r--sys-fs/lvm2/files/lvm2-2.03.12-dynamic-static-ldflags.patch (renamed from sys-fs/lvm2/files/lvm2-2.03.05-dynamic-static-ldflags.patch)35
-rw-r--r--sys-fs/lvm2/files/lvm2-2.03.12-static-libm.patch25
-rw-r--r--sys-fs/lvm2/files/lvm2-2.03.12-static-pkgconfig-libs.patch117
-rw-r--r--sys-fs/lvm2/lvm2-2.02.188.ebuild295
-rw-r--r--sys-fs/lvm2/lvm2-2.03.12.ebuild (renamed from sys-fs/lvm2/lvm2-2.03.11.ebuild)6
6 files changed, 465 insertions, 23 deletions
diff --git a/sys-fs/lvm2/Manifest b/sys-fs/lvm2/Manifest
index 7be5853d2a7a..ad563bfc3489 100644
--- a/sys-fs/lvm2/Manifest
+++ b/sys-fs/lvm2/Manifest
@@ -21,14 +21,18 @@ AUX lvm2-2.02.63-always-make-static-libdm.patch 1420 BLAKE2B baf7010b5965f5c2b9a
AUX lvm2-2.02.67-createinitrd.patch 660 BLAKE2B 23e784e6769bc1f47fa57d690e6bebdf16d784d775a06af1c8eb7c54dd63a12abb0edd8331c8d033d7a0dda058252453a46dd35bd820fd47ba1407e9568b3858 SHA512 17fbba5d34ece5c1c25ef35fa3bbc3d6fcd20b44bd766c049bbc120853a8d60c9544db5790645a7814db5c272fd12d383699a8a9be6f4e9c56a7c0a1bb29ade2
AUX lvm2-2.02.99-locale-muck.patch 405 BLAKE2B 07ac7c7f54d06dbdeae1c6bf0959fd0c223b30cbd67c08f853e02f520d212f7b6dcf7c3b6c3d3b7370bb004adbb23b226bf0d0792b5799ddbaff5ab655124ca2 SHA512 1c898693f71d165d55458ab87886a25206930c202b5aea95eba394ad06162cc710c1435e598acb9bcd3fbf46abf5409be972f6ce73bd02b2e177e1af780ae7ad
AUX lvm2-2.03.05-dmeventd-no-idle-exit.patch 2737 BLAKE2B 957f51a45f41920e73141cff56612e1bc334ef455fe262f1563d7c476ed534922f8f7a5f99d4f8ad69bb8830b7b1b97cf7afeb9a628058d54ffcef9d6497956f SHA512 c8ba4930114d8f6af230c21840e966def269e064c2236db6402a527f4e4050762082f37a770c551d3dab8d1b21642cfee701e48231f2bf42d50e41056725b711
-AUX lvm2-2.03.05-dynamic-static-ldflags.patch 2696 BLAKE2B 7464ee428e2cb8834181d3023399f2f913912bc58cb69af1fe9bb4418aecea1e4815c79d349e335cf60a7566052a34eb48db75f4f69bc0b0c2454def45edb18d SHA512 cb8e517967501fe11fe6c19543c37b26ada300bc06156b9f84e96fed96818e4a63e5a4322736d8e1eff4025a268dfb5570c4ec514bdf92df219a626f8bacd607
AUX lvm2-2.03.05-pthread-pkgconfig.patch 1442 BLAKE2B 6d2864c91fc38ba3c8e97641610c028bcd67b16bccf380b9fa8d7c5d18b714f91e35a4eeaa668f6b07dd057a663ac8c9f7e0936fb040d6ab258652327ca9bf22 SHA512 f20104a2f78900211bfadca486961039ce3e153dba9a242e4a2400c7e7efe06d061a76a4691f45233cc85aa15858cb8f44bf7bacb44007a8026c7c4794de4873
AUX lvm2-2.03.06-example.conf.in.patch 1833 BLAKE2B 21f9d51be4a704417dc35ed7d5ae385dab1376e3f25c030d215fd3b5d0a495f97d4230dd13cf88472b9699321f091ce90ac7162644f9c7f04ed9d8c5fd0eafe9 SHA512 49b0db05552be36153986322e28098ffc006ff2bad3fc91de99ce63f75207b0bbdfd8e4cdb5fb07decb4a84c883b552135a8b203186a10f2360a3616caf10957
+AUX lvm2-2.03.12-dynamic-static-ldflags.patch 2591 BLAKE2B b1edda6bd715d805ae12967ca453e08859c44f5e48d32e6d264682a6aac6a27fb47aa8fcb36b68b28e3237d76c8b5d060b050736c38d6913a7647b6168a98c3d SHA512 5c9c1d65579a14585c68a348c00b867a48398ebe7a871e6bfcc8cd3a6776c260aa6200f22c108f95ecd65b61ba4b260a5e6acae17dc8c9e639692bbcca2bdf37
+AUX lvm2-2.03.12-static-libm.patch 1000 BLAKE2B 4bde7eda80a00f7c692341ebc74ab30308f3157162caba4d789dac42318fd5a16d6b1471463bc2a1f02f50313ce274ecc5aeb039c90e0b979d73146cc9497fba SHA512 cc7764fdaadd767e88d68a3a071f72a7ce30e5bc98fb55b49cf8ba00c3c5a1cac288f2aad0fec94eba5dd2100108756f1315b9704e872d7d64100bbeff1b7a17
+AUX lvm2-2.03.12-static-pkgconfig-libs.patch 4438 BLAKE2B 0b24f49401f0ac5c440e3b6dbb768d368ed30609cdb9720598700855c2d8394feb5f495945ef67129ce3897b50a1d029ac8e46a7303461f2163b52605b694a02 SHA512 a68db7128107220631db0b3752a1c4ff89d376a50e71700c24ed12833a1a1394caf88769ab376277a838f1878991c0c208b3d40e61ffd616b988c2f6dacf3095
AUX lvmetad.initd-2.02.116-r3 345 BLAKE2B d458efd01fa08debe0857072c880adf951477445dd619a052f50cab9da39d8a38c9d480fc2d20fe899e01dcbcdaea0696d5c3e65af128652feea3186857d206e SHA512 f3143c6e1d00893009c68141f5ffd7e1e6bcf5b7ef0ff8505bc6c7049d83b2f9ddd2dc5a3cfdc2641a20603830b5dba07d73740cc5ce82e6b1b602a9b737a241
AUX lvmlockd.initd-2.02.166-r1 390 BLAKE2B aebfa2a654eca784da24fd4e4d46b3e6c97256a42b725e015a13c9673e79c0d1a10213d1eecb6c75d4ce1ebd99e6200010f19c36d758018bdef303ea08ee5549 SHA512 6359b3cbff1fa05944fb69582234220cac593b2c8f8317162a728bac72ced4f8b492ce11e6ced6d848a7654fa4a506c1e658f546cff302344a739646479a62dc
AUX lvmpolld.initd-2.02.183 348 BLAKE2B cba0419add6591320dc60ef7616b66706e042b566284a4ec42002fbb5331a7173fc8b4b39be7198426fe4bbdcd3ad94b69fc3d8950705b6331c5f3f4cda4ad66 SHA512 b9b8376cbc8b6703868afab18e5baa4ef5354569e57f0596d38a8005fa725299f6858ac86b39fcca10e5a0f1adbd3a4cfa6cc6b62405e78916cc1287d8b36d0d
DIST LVM2.2.02.187.tgz 2405544 BLAKE2B be804be3c64927a8848e8ea8de228fb563b6f8c22628b785aabb33fc993629e5370788216bd814246aeb3a5546fd5446383ce24342e716579887556edf2bbed2 SHA512 3ce56f0c0d2e7dbcdae5be263199f73ee5c4c052599d53cde9b16500a326d0340893344f4671839be06b5b4225d592175d01c9974db14f2dc220d6e9a1d47e91
-DIST LVM2.2.03.11.tgz 2528527 BLAKE2B 4c02e630e033f9bfed44468b5b8dff4af52c943cb9d6385bfe568ba50463dfc97cd968d79c34eb2528d66930d6c2895de17fe546a34d80fd17a5892560bcb670 SHA512 50f21337e397fc5b4692bb08e5d48409b907b96b39168343bab2d40bb74fd84ff466e15f3d664305bc044f3f6be4369fa7378399d5a838793632e74706f17653
+DIST LVM2.2.02.188.tgz 2421550 BLAKE2B bed90c8454cd4b20fdeec6dcbf5a9f97c9310671aea3b2252f8069cfa439fcb050f5ad95f928a7125a1734a4dc5ac985da99a4a570538e377a7205191a505476 SHA512 8c9db17c49dc8ebcab6c7f246ab85870a80658be811cf7f4d8f36abbebafa355b030bfc1e3bcbad73ccccb7fcd06d4a95ac547ca15d18d33715126da92703dca
+DIST LVM2.2.03.12.tgz 2594040 BLAKE2B 4e5630f27c818b79a1241b96a9d58d7078ece4a061b9bb4f26fddf77036fa2a319cc4f23835a6c784b025b3ddd07a18ce0a7ad3038fc90e90c2990d309a5d64a SHA512 e4d3bfb38b346251a2ea2cee7b79f2e12ed407652b659b35b65f58c8bb252943cee1c511713aeec8ff3400790e0e99ea6b83e8740050defe5cbb118f18bf7700
EBUILD lvm2-2.02.187-r2.ebuild 10034 BLAKE2B 3a2417d5126141dd67488386fd2520856580fc82f1a9d6763373b5f3050a673a43787a7deef7b4b2ffa23558eea504e5c1ee81e2c9c0af8a9185a54ed657fd5b SHA512 d8e223ac76bb91c9596e0c9ba49dd150fb36403bd57dabe31d3bc2ebdd3c4c729ff33b2c85ed1154e4d5f38654739505dcd634ba9dfaa94f1f9d97ce7e37db7d
-EBUILD lvm2-2.03.11.ebuild 9487 BLAKE2B bf73d0d3a535485c35172217fefb2d0a3649bc53cec8d45e8efe170227c615993bca04f0b11d49d7f23243b9ab15a8309b92f245b2c3265313a04cbc15af75bd SHA512 42e8bd43676ccf4962f201f09fdbcf4edab82a1324c00326b07ed10aec95e872288dacc0b68346e01629bf936b3481aeeb1f7b257a9e5f96cb96fc11aeb15a1b
+EBUILD lvm2-2.02.188.ebuild 10042 BLAKE2B 6b0117f19053c1083231f5e555ddfac6467b23308eb2d8da0461038c00bbb558ecc32204ce62d6ba7bb248594048ad3d0be681b3d623323b56c5278d5ed1dac3 SHA512 e06227795ad67abbeff1ed7c57d87b0c58ee0be191b0e58abd45f859b230a3af4f2bda08bf51767550e33b34deb80735f2d81ae1176d0507aa999440d8da3569
+EBUILD lvm2-2.03.12.ebuild 9485 BLAKE2B e971fe6fc271ac3bf5f526db5b95ccfe8e7c8abe13d9368bebbad3449f218b11b5c37d97cf6fbbe389f646aeaee9b0ad9e8dd3069cd6891d983159d2956eecb8 SHA512 c9e89d9332032bb673edb4e5b7c2755722b0d67a4583c738f339b27ba271785a42e9d0d2eeb939da42115a596a25057ba10c86845e1f69bd2e51dccbcc58acf5
MISC metadata.xml 1034 BLAKE2B f0f14e228cefe806333830eec09a076c06985750b08669036f951e7aefb45b2482091f4da404ccce7e5180e7294adc2940311d360773a7ec72e16f96d9d82961 SHA512 ccdb84869eaa98af048d561791879796ea8a82cb2603241496ce050133402f66e0e5b7d6eab161bc9739451712e73370616698ff492377e54d8dd5582abfbc69
diff --git a/sys-fs/lvm2/files/lvm2-2.03.05-dynamic-static-ldflags.patch b/sys-fs/lvm2/files/lvm2-2.03.12-dynamic-static-ldflags.patch
index 2b9a5dd945c5..80b6bc7a023f 100644
--- a/sys-fs/lvm2/files/lvm2-2.03.05-dynamic-static-ldflags.patch
+++ b/sys-fs/lvm2/files/lvm2-2.03.12-dynamic-static-ldflags.patch
@@ -1,9 +1,10 @@
-From 93101699f5e1190184c00c99ab7b6e9717e5019a Mon Sep 17 00:00:00 2001
+From 4bdd215fd84e83a8119d0b971904221743a87a23 Mon Sep 17 00:00:00 2001
From: "Robin H. Johnson" <robbat2@gentoo.org>
Date: Wed, 24 Jul 2019 11:11:35 +0200
Subject: [PATCH] Add dynamic static ldflags
Forward-ported from 2.02.178 to 2.03.05
+Forward-ported from 2.03.05 to 2.03.12
Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
---
configure.ac | 2 ++
@@ -13,18 +14,18 @@ Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
4 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/configure.ac b/configure.ac
-index 1e45c0edcb..cc2625294a 100644
+index 1a49e7fe7e..354b53b5ec 100644
--- a/configure.ac
+++ b/configure.ac
-@@ -33,6 +33,7 @@ case "$host_os" in
- CLDFLAGS="${CLDFLAGS:"$LDFLAGS"} -Wl,--version-script,.export.sym"
+@@ -32,6 +32,7 @@ case "$host_os" in
+ linux*)
# equivalent to -rdynamic
ELDFLAGS="-Wl,--export-dynamic"
+ STATIC_LDFLAGS="-Wl,--no-export-dynamic"
# FIXME Generate list and use --dynamic-list=.dlopen.sym
CLDWHOLEARCHIVE="-Wl,-whole-archive"
CLDNOWHOLEARCHIVE="-Wl,-no-whole-archive"
-@@ -1758,6 +1759,7 @@ AC_SUBST(SYSCONFDIR)
+@@ -1860,6 +1861,7 @@ AC_SUBST(SYSCONFDIR)
AC_SUBST(SYSTEMD_LIBS)
AC_SUBST(SNAPSHOTS)
AC_SUBST(STATICDIR)
@@ -33,23 +34,23 @@ index 1e45c0edcb..cc2625294a 100644
AC_SUBST(TESTSUITE_DATA)
AC_SUBST(THIN)
diff --git a/daemons/dmeventd/Makefile.in b/daemons/dmeventd/Makefile.in
-index 6bd36d0325..a3c30ec1a0 100644
+index af51198aae..f7896e581e 100644
--- a/daemons/dmeventd/Makefile.in
+++ b/daemons/dmeventd/Makefile.in
-@@ -66,7 +66,7 @@ dmeventd: $(LIB_SHARED) dmeventd.o
+@@ -76,7 +76,7 @@ dmeventd: $(LIB_SHARED) dmeventd.o
dmeventd.static: $(LIB_STATIC) dmeventd.o
@echo " [CC] $@"
-- $(Q) $(CC) $(CFLAGS) $(LDFLAGS) -static -L. -L$(interfacebuilddir) dmeventd.o \
-+ $(Q) $(CC) $(CFLAGS) $(LDFLAGS) $(STATIC_LDFLAGS) -static -L. -L$(interfacebuilddir) dmeventd.o \
+- $(Q) $(CC) $(CFLAGS) $(LDFLAGS) -static dmeventd.o \
++ $(Q) $(CC) $(CFLAGS) $(LDFLAGS) $(STATIC_LDFLAGS) -static dmeventd.o \
-o $@ $(DL_LIBS) $(DMEVENT_LIBS) $(LIBS) $(STATIC_LIBS)
ifeq ("@PKGCONFIG@", "yes")
diff --git a/make.tmpl.in b/make.tmpl.in
-index f3332e91c1..1489c2afad 100644
+index 200ea2e05f..99f02e8b77 100644
--- a/make.tmpl.in
+++ b/make.tmpl.in
-@@ -68,6 +68,7 @@ DEFS += @DEFS@
+@@ -69,6 +69,7 @@ DEFS += @DEFS@
# FIXME set this only where it's needed, not globally?
CFLAGS ?= @COPTIMISE_FLAG@ @CFLAGS@
LDFLAGS ?= @LDFLAGS@
@@ -58,18 +59,18 @@ index f3332e91c1..1489c2afad 100644
ELDFLAGS += @ELDFLAGS@
LDDEPS += @LDDEPS@
diff --git a/tools/Makefile.in b/tools/Makefile.in
-index 2620daa17c..e5fc9c4ae4 100644
+index ec546ca632..cdede2a058 100644
--- a/tools/Makefile.in
+++ b/tools/Makefile.in
-@@ -136,7 +136,7 @@ man-generator: man-generator.o
+@@ -137,7 +137,7 @@ man-generator: man-generator.o
lvm.static: $(OBJECTS) lvm-static.o $(LVMINTERNAL_LIBS)
@echo " [CC] $@"
-- $(Q) $(CC) $(CFLAGS) $(LDFLAGS) -static -L$(interfacebuilddir) -o $@ $+ \
-+ $(Q) $(CC) $(CFLAGS) $(LDFLAGS) $(STATIC_LDFLAGS) -static -L$(interfacebuilddir) -o $@ $+ \
- $(DMEVENT_LIBS) $(STATIC_LIBS) $(LVMLIBS)
+- $(Q) $(CC) $(CFLAGS) $(LDFLAGS) -static -L$(interfacebuilddir) \
++ $(Q) $(CC) $(CFLAGS) $(LDFLAGS) $(STATIC_LDFLAGS) -static -L$(interfacebuilddir) \
+ -o $@ $+ $(LVMLIBS) $(STATIC_LIBS)
liblvm2cmd.a: $(top_builddir)/lib/liblvm-internal.a $(OBJECTS) lvmcmdlib.o lvm2cmd.o
--
-2.22.0
+2.31.1
diff --git a/sys-fs/lvm2/files/lvm2-2.03.12-static-libm.patch b/sys-fs/lvm2/files/lvm2-2.03.12-static-libm.patch
new file mode 100644
index 000000000000..5bb776c9b5ed
--- /dev/null
+++ b/sys-fs/lvm2/files/lvm2-2.03.12-static-libm.patch
@@ -0,0 +1,25 @@
+From 4917d9c8b6227256a4a83ff937119d6aa53d654e Mon Sep 17 00:00:00 2001
+From: "Robin H. Johnson" <robbat2@gentoo.org>
+Date: Sun, 9 May 2021 11:02:54 +0200
+Subject: [PATCH] Add libm to static libs
+
+---
+ make.tmpl.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/make.tmpl.in b/make.tmpl.in
+index ae189546d0..8ee00bd9e8 100644
+--- a/make.tmpl.in
++++ b/make.tmpl.in
+@@ -64,7 +64,7 @@ PYCOMPILE = $(top_srcdir)/autoconf/py-compile
+ LIBS += @LIBS@ $(SELINUX_LIBS) $(UDEV_LIBS) $(RT_LIBS) $(M_LIBS)
+ LVMLIBS = $(DMEVENT_LIBS) $(READLINE_LIBS) $(EDITLINE_LIBS) $(SYSTEMD_LIBS) $(BLKID_LIBS) $(AIO_LIBS) $(LIBS)
+ # Extra libraries always linked with static binaries
+-STATIC_LIBS = $(PTHREAD_LIBS) $(SELINUX_STATIC_LIBS) $(UDEV_STATIC_LIBS) $(BLKID_STATIC_LIBS)
++STATIC_LIBS = $(PTHREAD_LIBS) $(SELINUX_STATIC_LIBS) $(UDEV_STATIC_LIBS) $(BLKID_STATIC_LIBS) $(M_LIBS)
+ DEFS += @DEFS@
+ # FIXME set this only where it's needed, not globally?
+ CFLAGS ?= @COPTIMISE_FLAG@ @CFLAGS@
+--
+2.31.1
+
diff --git a/sys-fs/lvm2/files/lvm2-2.03.12-static-pkgconfig-libs.patch b/sys-fs/lvm2/files/lvm2-2.03.12-static-pkgconfig-libs.patch
new file mode 100644
index 000000000000..083a7327c6a6
--- /dev/null
+++ b/sys-fs/lvm2/files/lvm2-2.03.12-static-pkgconfig-libs.patch
@@ -0,0 +1,117 @@
+From 88aeb306dfd1e0174bf02cc208d46f0d722204dc Mon Sep 17 00:00:00 2001
+From: "Robin H. Johnson" <robbat2@gentoo.org>
+Date: Sun, 9 May 2021 11:00:22 +0200
+Subject: [PATCH] Use pkgconfig to detect static libs
+
+---
+ configure.ac | 20 ++++++++++++++++++--
+ make.tmpl.in | 5 ++++-
+ 2 files changed, 22 insertions(+), 3 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 354b53b5ec..e872d70256 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1097,6 +1097,7 @@ if test "$BLKID_WIPING" != no; then
+ PKG_CHECK_MODULES(BLKID, blkid >= 2.24,
+ [ BLKID_WIPING=yes
+ BLKID_PC="blkid"
++ BLKID_STATIC_LIBS=`$PKG_CONFIG --static --libs $BLKID_PC`
+ DEFAULT_USE_BLKID_WIPING=1
+ AC_DEFINE([BLKID_WIPING_SUPPORT], 1, [Define to 1 to use libblkid detection of signatures when wiping.])
+ ], [if test "$BLKID_WIPING" = maybe; then
+@@ -1145,6 +1146,7 @@ AC_MSG_RESULT($UDEV_SYNC)
+ if test "$UDEV_SYNC" = yes; then
+ pkg_config_init
+ PKG_CHECK_MODULES(UDEV, libudev >= 143, [UDEV_PC="libudev"])
++ UDEV_STATIC_LIBS=`$PKG_CONFIG --static --libs libudev`
+ AC_DEFINE([UDEV_SYNC_SUPPORT], 1, [Define to 1 to enable synchronisation with udev processing.])
+
+ AC_CHECK_LIB(udev, udev_device_get_is_initialized, AC_DEFINE([HAVE_LIBUDEV_UDEV_DEVICE_GET_IS_INITIALIZED], 1,
+@@ -1369,19 +1371,30 @@ dnl -- Check for selinux
+ if test "$SELINUX" = yes; then
+ AC_CHECK_LIB([sepol], [sepol_check_context], [
+ AC_DEFINE([HAVE_SEPOL], 1, [Define to 1 if sepol_check_context is available.])
+- SELINUX_LIBS="-lsepol"])
++ SEPOL_LIBS="-lsepol"])
++
++ dnl -- init pkgconfig if required
++ AS_IF([test x$PKGCONFIG_INIT != x1], [pkg_config_init])
++ PKG_CHECK_MODULES(SELINUX, libselinux, [
++ SELINUX_PC="libselinux"
++ SELINUX_STATIC_LIBS=`$PKG_CONFIG --static --libs libselinux`
++ SELINUX_LIBS="$SELINUX_LIBS $SEPOL_LIBS"
++ AC_DEFINE([HAVE_SELINUX], 1, [Define to 1 to include support for selinux.])
++ ], [
++ dnl -- old non-pkgconfig method, is buggy with static builds
+
+ AC_CHECK_LIB([selinux], [is_selinux_enabled], [
+ AC_CHECK_HEADERS([selinux/selinux.h],, hard_bailout)
+ AC_CHECK_HEADERS([selinux/label.h])
+ AC_DEFINE([HAVE_SELINUX], 1, [Define to 1 to include support for selinux.])
+- SELINUX_LIBS="-lselinux $SELINUX_LIBS"
++ SELINUX_LIBS="-lselinux $SEPOL_LIBS"
+ SELINUX_PC="libselinux"
+ HAVE_SELINUX=yes ], [
+ AC_MSG_WARN(Disabling selinux)
+ SELINUX_LIBS=
+ SELINUX_PC=
+ HAVE_SELINUX=no ])
++ ])
+ fi
+
+ ################################################################################
+@@ -1755,6 +1768,7 @@ AC_DEFINE_UNQUOTED(LVM_CONFIGURE_LINE, "$CONFIGURE_LINE", [configure command lin
+ ################################################################################
+ AC_SUBST(AWK)
+ AC_SUBST(BLKID_PC)
++AC_SUBST(BLKID_STATIC_LIBS)
+ AC_SUBST(BUILD_CMIRRORD)
+ AC_SUBST(BUILD_DMEVENTD)
+ AC_SUBST(BUILD_LVMDBUSD)
+@@ -1857,6 +1871,7 @@ AC_SUBST(SALCK_LIBS)
+ AC_SUBST(SBINDIR)
+ AC_SUBST(SELINUX_LIBS)
+ AC_SUBST(SELINUX_PC)
++AC_SUBST(SELINUX_STATIC_LIBS)
+ AC_SUBST(SYSCONFDIR)
+ AC_SUBST(SYSTEMD_LIBS)
+ AC_SUBST(SNAPSHOTS)
+@@ -1875,6 +1890,7 @@ AC_SUBST(CACHE_REPAIR_CMD)
+ AC_SUBST(CACHE_RESTORE_CMD)
+ AC_SUBST(UDEV_PC)
+ AC_SUBST(UDEV_RULES)
++AC_SUBST(UDEV_STATIC_LIBS)
+ AC_SUBST(UDEV_SYNC)
+ AC_SUBST(UDEV_SYSTEMD_BACKGROUND_JOBS)
+ AC_SUBST(UDEV_RULE_EXEC_DETECTION)
+diff --git a/make.tmpl.in b/make.tmpl.in
+index 99f02e8b77..ae189546d0 100644
+--- a/make.tmpl.in
++++ b/make.tmpl.in
+@@ -64,7 +64,7 @@ PYCOMPILE = $(top_srcdir)/autoconf/py-compile
+ LIBS += @LIBS@ $(SELINUX_LIBS) $(UDEV_LIBS) $(RT_LIBS) $(M_LIBS)
+ LVMLIBS = $(DMEVENT_LIBS) $(READLINE_LIBS) $(EDITLINE_LIBS) $(SYSTEMD_LIBS) $(BLKID_LIBS) $(AIO_LIBS) $(LIBS)
+ # Extra libraries always linked with static binaries
+-STATIC_LIBS = $(PTHREAD_LIBS)
++STATIC_LIBS = $(PTHREAD_LIBS) $(SELINUX_STATIC_LIBS) $(UDEV_STATIC_LIBS) $(BLKID_STATIC_LIBS)
+ DEFS += @DEFS@
+ # FIXME set this only where it's needed, not globally?
+ CFLAGS ?= @COPTIMISE_FLAG@ @CFLAGS@
+@@ -83,10 +83,13 @@ PTHREAD_LIBS = @PTHREAD_LIBS@
+ READLINE_LIBS = @READLINE_LIBS@
+ EDITLINE_LIBS = @EDITLINE_LIBS@
+ SELINUX_LIBS = @SELINUX_LIBS@
++SELINUX_STATIC_LIBS = @SELINUX_STATIC_LIBS@
+ UDEV_CFLAGS = @UDEV_CFLAGS@
+ UDEV_LIBS = @UDEV_LIBS@
++UDEV_STATIC_LIBS = @UDEV_STATIC_LIBS@
+ BLKID_CFLAGS = @BLKID_CFLAGS@
+ BLKID_LIBS = @BLKID_LIBS@
++BLKID_STATIC_LIBS = @BLKID_STATIC_LIBS@
+ SYSTEMD_LIBS = @SYSTEMD_LIBS@
+ VALGRIND_CFLAGS = @VALGRIND_CFLAGS@
+ USE_TRACKING = @USE_TRACKING@
+--
+2.31.1
+
diff --git a/sys-fs/lvm2/lvm2-2.02.188.ebuild b/sys-fs/lvm2/lvm2-2.02.188.ebuild
new file mode 100644
index 000000000000..05bdee02a554
--- /dev/null
+++ b/sys-fs/lvm2/lvm2-2.02.188.ebuild
@@ -0,0 +1,295 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+inherit autotools linux-info multilib systemd toolchain-funcs udev flag-o-matic
+
+DESCRIPTION="User-land utilities for LVM2 (device-mapper) software"
+HOMEPAGE="https://sourceware.org/lvm2/"
+SRC_URI="ftp://sourceware.org/pub/lvm2/${PN/lvm/LVM}.${PV}.tgz
+ ftp://sourceware.org/pub/lvm2/old/${PN/lvm/LVM}.${PV}.tgz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
+IUSE="readline static static-libs systemd lvm2create_initrd sanlock selinux +udev +thin device-mapper-only"
+REQUIRED_USE="device-mapper-only? ( !lvm2create_initrd !sanlock !thin )
+ systemd? ( udev )"
+
+DEPEND_COMMON="
+ dev-libs/libaio[static-libs?]
+ static? ( dev-libs/libaio[static-libs] )
+ !static? ( dev-libs/libaio[static-libs?] )
+ readline? ( sys-libs/readline:0= )
+ sanlock? ( sys-cluster/sanlock )
+ systemd? ( >=sys-apps/systemd-205:0= )
+ udev? ( >=virtual/libudev-208:=[static-libs(-)?] )"
+# /run is now required for locking during early boot. /var cannot be assumed to
+# be available -- thus, pull in recent enough baselayout for /run.
+# This version of LVM is incompatible with cryptsetup <1.1.2.
+RDEPEND="${DEPEND_COMMON}
+ >=sys-apps/baselayout-2.2
+ !<sys-apps/openrc-0.11
+ !<sys-fs/cryptsetup-1.1.2
+ !!sys-fs/lvm-user
+ >=sys-apps/util-linux-2.16
+ lvm2create_initrd? ( sys-apps/makedev )
+ thin? ( >=sys-block/thin-provisioning-tools-0.3.0 )"
+# note: thin- 0.3.0 is required to avoid --disable-thin_check_needs_check
+DEPEND="${DEPEND_COMMON}
+ static? (
+ selinux? ( sys-libs/libselinux[static-libs] )
+ >=sys-apps/util-linux-2.16[static-libs]
+ )"
+BDEPEND="
+ sys-devel/autoconf-archive
+ virtual/pkgconfig
+"
+
+S="${WORKDIR}/${PN/lvm/LVM}.${PV}"
+
+PATCHES=(
+ # Gentoo specific modification(s):
+ "${FILESDIR}"/${PN}-2.02.178-example.conf.in.patch
+
+ # For upstream -- review and forward:
+ "${FILESDIR}"/${PN}-2.02.63-always-make-static-libdm.patch
+ "${FILESDIR}"/${PN}-2.02.56-lvm2create_initrd.patch
+ "${FILESDIR}"/${PN}-2.02.67-createinitrd.patch #301331
+ "${FILESDIR}"/${PN}-2.02.99-locale-muck.patch #330373
+ "${FILESDIR}"/${PN}-2.02.178-asneeded.patch # -Wl,--as-needed
+ "${FILESDIR}"/${PN}-2.02.178-dynamic-static-ldflags.patch #332905
+ "${FILESDIR}"/${PN}-2.02.178-static-pkgconfig-libs.patch #370217, #439414 + blkid
+ "${FILESDIR}"/${PN}-2.02.176-pthread-pkgconfig.patch #492450
+ "${FILESDIR}"/${PN}-2.02.171-static-libm.patch #617756
+ "${FILESDIR}"/${PN}-2.02.166-HPPA-no-O_DIRECT.patch #657446
+ #"${FILESDIR}"/${PN}-2.02.145-mkdev.patch #580062 # Merged upstream
+ "${FILESDIR}"/${PN}-2.02.184-dmeventd-no-idle-exit.patch
+ #"${FILESDIR}"/${PN}-2.02.184-allow-reading-metadata-with-invalid-creation_time.patch #682380 # merged upstream
+ "${FILESDIR}"/${PN}-2.02.184-mksh_build.patch #686652
+ "${FILESDIR}"/${PN}-2.02.186-udev_remove_unsupported_option.patch #700160
+)
+
+pkg_setup() {
+ local CONFIG_CHECK="~SYSVIPC"
+
+ if use udev; then
+ local WARNING_SYSVIPC="CONFIG_SYSVIPC:\tis not set (required for udev sync)\n"
+ if linux_config_exists; then
+ local uevent_helper_path=$(linux_chkconfig_string UEVENT_HELPER_PATH)
+ if [[ -n "${uevent_helper_path}" ]] && [[ "${uevent_helper_path}" != '""' ]]; then
+ ewarn "It's recommended to set an empty value to the following kernel config option:"
+ ewarn "CONFIG_UEVENT_HELPER_PATH=${uevent_helper_path}"
+ fi
+ fi
+ fi
+
+ check_extra_config
+
+ # 1. Genkernel no longer copies /sbin/lvm blindly.
+ if use static; then
+ elog "Warning, we no longer overwrite /sbin/lvm and /sbin/dmsetup with"
+ elog "their static versions. If you need the static binaries,"
+ elog "you must append .static to the filename!"
+ fi
+}
+
+src_prepare() {
+ default
+
+ sed -i \
+ -e "1iAR = $(tc-getAR)" \
+ -e "s:CC ?= @CC@:CC = $(tc-getCC):" \
+ make.tmpl.in || die #444082
+
+ sed -i -e '/FLAG/s:-O2::' configure{.ac,} || die #480212
+
+ if use udev && ! use device-mapper-only; then
+ sed -i -e '/use_lvmetad =/s:0:1:' conf/example.conf.in || die #514196
+ elog "Notice that \"use_lvmetad\" setting is enabled with USE=\"udev\" in"
+ elog "/etc/lvm/lvm.conf, which will require restart of udev, lvm, and lvmetad"
+ elog "if it was previously disabled."
+ fi
+
+ sed -i -e "s:/usr/bin/true:$(type -P true):" scripts/blk_availability_systemd_red_hat.service.in || die #517514
+
+ # Don't install thin man page when not requested
+ if ! use thin ; then
+ sed -i -e 's/^\(MAN7+=.*\) $(LVMTHINMAN) \(.*\)$/\1 \2/' man/Makefile.in || die
+ fi
+
+ eautoreconf
+}
+
+src_configure() {
+ filter-flags -flto
+ local myeconfargs=()
+
+ # Most of this package does weird stuff.
+ # The build options are tristate, and --without is NOT supported
+ # options: 'none', 'internal', 'shared'
+ myeconfargs+=(
+ $(use_enable !device-mapper-only dmfilemapd)
+ $(use_enable !device-mapper-only dmeventd)
+ $(use_enable !device-mapper-only cmdlib)
+ $(use_enable !device-mapper-only applib)
+ $(use_enable !device-mapper-only fsadm)
+ $(use_enable !device-mapper-only lvmetad)
+ $(use_enable !device-mapper-only lvmpolld)
+ $(usex device-mapper-only --disable-udev-systemd-background-jobs '')
+
+ # This only causes the .static versions to become available
+ $(usex static --enable-static_link '')
+
+ # dmeventd requires mirrors to be internal, and snapshot available
+ # so we cannot disable them
+ --with-mirrors="$(usex device-mapper-only none internal)"
+ --with-snapshots="$(usex device-mapper-only none internal)"
+
+ # disable O_DIRECT support on hppa, breaks pv detection (#99532)
+ $(usex hppa --disable-o_direct '')
+ )
+
+ if use thin; then
+ myeconfargs+=( --with-thin=internal --with-cache=internal )
+ local texec
+ for texec in check dump repair restore; do
+ myeconfargs+=( --with-thin-${texec}="${EPREFIX}"/sbin/thin_${texec} )
+ myeconfargs+=( --with-cache-${texec}="${EPREFIX}"/sbin/cache_${texec} )
+ done
+ else
+ myeconfargs+=( --with-thin=none --with-cache=none )
+ fi
+
+ myeconfargs+=( --with-clvmd=none --with-cluster=none )
+
+ myeconfargs+=(
+ $(use_enable readline)
+ $(use_enable selinux)
+ --enable-pkgconfig
+ --with-confdir="${EPREFIX}"/etc
+ --exec-prefix="${EPREFIX}"
+ --sbindir="${EPREFIX}/sbin"
+ --with-staticdir="${EPREFIX}"/sbin
+ --libdir="${EPREFIX}/$(get_libdir)"
+ --with-usrlibdir="${EPREFIX}/usr/$(get_libdir)"
+ --with-default-dm-run-dir=/run
+ --with-default-run-dir=/run/lvm
+ --with-default-locking-dir=/run/lock/lvm
+ --with-default-pid-dir=/run
+ $(use_enable udev udev_rules)
+ $(use_enable udev udev_sync)
+ $(use_with udev udevdir "$(get_udevdir)"/rules.d)
+ $(use_enable sanlock lvmlockd-sanlock)
+ $(use_enable systemd udev-systemd-background-jobs)
+ $(use_enable systemd notify-dbus)
+ --with-systemdsystemunitdir="$(systemd_get_systemunitdir)"
+ CLDFLAGS="${LDFLAGS}"
+ )
+ # Hard-wire this to bash as some shells (dash) don't know
+ # "-o pipefail" #682404
+ CONFIG_SHELL="/bin/bash" \
+ econf "${myeconfargs[@]}"
+}
+
+src_compile() {
+ pushd include >/dev/null
+ emake V=1
+ popd >/dev/null
+
+ if use device-mapper-only ; then
+ emake V=1 device-mapper
+ else
+ emake V=1
+ emake V=1 CC="$(tc-getCC)" -C scripts lvm2_activation_generator_systemd_red_hat
+ fi
+}
+
+src_install() {
+ local inst INSTALL_TARGETS
+ INSTALL_TARGETS=( install install_tmpfiles_configuration )
+ # install systemd related files only when requested, bug #522430
+ use systemd && INSTALL_TARGETS+=( install_systemd_units install_systemd_generators )
+ use device-mapper-only && INSTALL_TARGETS=( install_device-mapper )
+ for inst in ${INSTALL_TARGETS[@]}; do
+ emake V=1 DESTDIR="${D}" ${inst}
+ done
+
+ newinitd "${FILESDIR}"/device-mapper.rc-2.02.105-r2 device-mapper
+ newconfd "${FILESDIR}"/device-mapper.conf-1.02.22-r3 device-mapper
+
+ if use !device-mapper-only ; then
+ newinitd "${FILESDIR}"/dmeventd.initd-2.02.184-r2 dmeventd
+ newinitd "${FILESDIR}"/lvm.rc-2.02.187 lvm
+ newconfd "${FILESDIR}"/lvm.confd-2.02.184-r3 lvm
+ if ! use udev ; then
+ # We keep the variable but remove udev from it.
+ sed -r -i \
+ -e '/^rc_need=/s/\<udev\>//g' \
+ "${ED}/etc/conf.d/lvm" || die "Could not drop udev from rc_need"
+ fi
+
+ newinitd "${FILESDIR}"/lvm-monitoring.initd-2.02.105-r2 lvm-monitoring
+ newinitd "${FILESDIR}"/lvmetad.initd-2.02.116-r3 lvmetad
+ newinitd "${FILESDIR}"/lvmpolld.initd-2.02.183 lvmpolld
+ fi
+
+ if use sanlock; then
+ newinitd "${FILESDIR}"/lvmlockd.initd-2.02.166-r1 lvmlockd
+ fi
+
+ if use static-libs; then
+ dolib.a libdm/ioctl/libdevmapper.a
+ if use !device-mapper-only; then
+ # depends on lvmetad
+ dolib.a libdaemon/client/libdaemonclient.a #462908
+ # depends on dmeventd
+ dolib.a daemons/dmeventd/libdevmapper-event.a
+ fi
+ else
+ rm -f "${ED}"/usr/$(get_libdir)/{libdevmapper-event,liblvm2cmd,liblvm2app,libdevmapper}.a
+ fi
+
+ if use lvm2create_initrd; then
+ dosbin scripts/lvm2create_initrd/lvm2create_initrd
+ doman scripts/lvm2create_initrd/lvm2create_initrd.8
+ newdoc scripts/lvm2create_initrd/README README.lvm2create_initrd
+ fi
+
+ insinto /etc
+ doins "${FILESDIR}"/dmtab
+
+ dodoc README VERSION* WHATS_NEW WHATS_NEW_DM doc/*.{c,txt} conf/*.conf
+}
+
+pkg_postinst() {
+ if [[ -z "${REPLACING_VERSIONS}" ]]; then
+ # This is a new installation
+ ewarn "Make sure the \"lvm\" init script is in the runlevels:"
+ ewarn "# rc-update add lvm boot"
+ ewarn
+ ewarn "Make sure to enable lvmetad in /etc/lvm/lvm.conf if you want"
+ ewarn "to enable lvm autoactivation and metadata caching."
+ fi
+
+ if use udev && [[ -d /run ]] ; then
+ local permission_run_expected="drwxr-xr-x"
+ local permission_run=$(stat -c "%A" /run)
+ if [[ "${permission_run}" != "${permission_run_expected}" ]] ; then
+ ewarn "Found the following problematic permissions:"
+ ewarn ""
+ ewarn " ${permission_run} /run"
+ ewarn ""
+ ewarn "Expected:"
+ ewarn ""
+ ewarn " ${permission_run_expected} /run"
+ ewarn ""
+ ewarn "This is known to be causing problems for UDEV-enabled LVM services."
+ fi
+ fi
+}
+
+src_test() {
+ einfo "Tests are disabled because of device-node mucking, if you want to"
+ einfo "run tests, compile the package and see ${S}/tests"
+}
diff --git a/sys-fs/lvm2/lvm2-2.03.11.ebuild b/sys-fs/lvm2/lvm2-2.03.12.ebuild
index d8d945f5a7d3..5a5bd509c37a 100644
--- a/sys-fs/lvm2/lvm2-2.03.11.ebuild
+++ b/sys-fs/lvm2/lvm2-2.03.12.ebuild
@@ -58,10 +58,10 @@ PATCHES=(
"${FILESDIR}"/${PN}-2.02.67-createinitrd.patch #301331
"${FILESDIR}"/${PN}-2.02.99-locale-muck.patch #330373
#"${FILESDIR}"/${PN}-2.02.178-asneeded.patch # -Wl,--as-needed
- "${FILESDIR}"/${PN}-2.03.05-dynamic-static-ldflags.patch #332905
- "${FILESDIR}"/${PN}-2.02.178-static-pkgconfig-libs.patch #370217, #439414 + blkid
+ "${FILESDIR}"/${PN}-2.03.12-dynamic-static-ldflags.patch #332905
+ "${FILESDIR}"/${PN}-2.03.12-static-pkgconfig-libs.patch #370217, #439414 + blkid
"${FILESDIR}"/${PN}-2.03.05-pthread-pkgconfig.patch #492450
- "${FILESDIR}"/${PN}-2.02.171-static-libm.patch #617756
+ "${FILESDIR}"/${PN}-2.03.12-static-libm.patch #617756
"${FILESDIR}"/${PN}-2.02.166-HPPA-no-O_DIRECT.patch #657446
#"${FILESDIR}"/${PN}-2.02.145-mkdev.patch #580062 # Merged upstream
"${FILESDIR}"/${PN}-2.03.05-dmeventd-no-idle-exit.patch