aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpsykose <alice@ayaya.dev>2023-02-21 15:54:20 +0000
committerpsykose <alice@ayaya.dev>2023-02-21 16:55:30 +0100
commit63c6640b45628425a5531d5df4de205e8cbc84df (patch)
tree7ae5180e4ac4bfdeffe4162f3d94fbe20002b3d5
parent19dd70e408b92fbfbc79011331b1d19f504d5ddf (diff)
main/lvm2: upgrade to 2.03.19
this also correctly readds the mlockall patch- it was empty before. includes.patch isn't needed anymore. coreutils/bash are also not required for the build anymore
-rw-r--r--main/lvm2/0001-lvresize-use-POSIX-shell.patch45
-rw-r--r--main/lvm2/APKBUILD15
-rw-r--r--main/lvm2/includes.patch13
-rw-r--r--main/lvm2/mlockall-default-config.patch26
4 files changed, 53 insertions, 46 deletions
diff --git a/main/lvm2/0001-lvresize-use-POSIX-shell.patch b/main/lvm2/0001-lvresize-use-POSIX-shell.patch
index 447234d0fdd..cf9609bac8b 100644
--- a/main/lvm2/0001-lvresize-use-POSIX-shell.patch
+++ b/main/lvm2/0001-lvresize-use-POSIX-shell.patch
@@ -8,7 +8,7 @@ Subject: [PATCH] lvresize: use POSIX shell
1 file changed, 14 insertions(+), 14 deletions(-)
diff --git a/scripts/lvresize_fs_helper.sh b/scripts/lvresize_fs_helper.sh
-index 031b8453b..df153eb09 100755
+index 90b1a97..1c48a71 100755
--- a/scripts/lvresize_fs_helper.sh
+++ b/scripts/lvresize_fs_helper.sh
@@ -1,4 +1,4 @@
@@ -17,52 +17,52 @@ index 031b8453b..df153eb09 100755
#
# Copyright (C) 2022 Red Hat, Inc. All rights reserved.
#
-@@ -73,7 +73,7 @@ fsextend() {
+@@ -69,7 +69,7 @@ fsextend() {
fi
fi
- if [[ "$FSTYPE" == "ext"* ]]; then
+ if [ "${FSTYPE#ext}" != "$FSTYPE" ]; then
logmsg "resize2fs ${DEVPATH}"
- resize2fs "$DEVPATH"
- if [ $? -eq 0 ]; then
-@@ -82,7 +82,7 @@ fsextend() {
+ if resize2fs "$DEVPATH"; then
+ logmsg "resize2fs done"
+@@ -77,7 +77,7 @@ fsextend() {
logmsg "resize2fs failed"
RESIZEFS_FAILED=1
fi
- elif [[ "$FSTYPE" == "xfs" ]]; then
+ elif [ "$FSTYPE" = "xfs" ]; then
logmsg "xfs_growfs ${DEVPATH}"
- xfs_growfs "$DEVPATH"
- if [ $? -eq 0 ]; then
-@@ -109,7 +109,7 @@ fsextend() {
+ if xfs_growfs "$DEVPATH"; then
+ logmsg "xfs_growfs done"
+@@ -102,7 +102,7 @@ fsextend() {
# If the fs was temporarily unmounted, now remount it.
# Not considered a command failure if this fails.
- if [[ $DO_UNMOUNT -eq 1 && $REMOUNT -eq 1 ]]; then
+ if [ "$DO_UNMOUNT" -eq 1 ] && [ "$REMOUNT" -eq 1 ]; then
logmsg "remount ${DEVPATH} ${MOUNTDIR}"
- mount -t "$FSTYPE" "$DEVPATH" "$MOUNTDIR"
- if [ $? -eq 0 ]; then
-@@ -162,7 +162,7 @@ fsreduce() {
+ if mount -t "$FSTYPE" "$DEVPATH" "$MOUNTDIR"; then
+ logmsg "remount done"
+@@ -151,7 +151,7 @@ fsreduce() {
fi
fi
- if [[ "$FSTYPE" == "ext"* ]]; then
+ if [ "${FSTYPE#ext}" != "$FSTYPE" ]; then
- NEWSIZEKB=$(($NEWSIZEBYTES/1024))
+ NEWSIZEKB=$(( NEWSIZEBYTES / 1024 ))
logmsg "resize2fs ${DEVPATH} ${NEWSIZEKB}k"
- resize2fs "$DEVPATH" "$NEWSIZEKB"k
-@@ -208,7 +208,7 @@ fsreduce() {
+ if resize2fs "$DEVPATH" "$NEWSIZEKB"k; then
+@@ -194,7 +194,7 @@ fsreduce() {
# If the fs was temporarily unmounted, now remount it.
# Not considered a command failure if this fails.
- if [[ $DO_UNMOUNT -eq 1 && $REMOUNT -eq 1 ]]; then
+ if [ "$DO_UNMOUNT" -eq 1 ] && [ "$REMOUNT" -eq 1 ]; then
logmsg "remount ${DEVPATH} ${MOUNTDIR}"
- mount -t "$FSTYPE" "$DEVPATH" "$MOUNTDIR"
- if [ $? -eq 0 ]; then
-@@ -307,7 +307,7 @@ DO_FSCK=0
+ if mount -t "$FSTYPE" "$DEVPATH" "$MOUNTDIR"; then
+ logmsg "remount done"
+@@ -291,7 +291,7 @@ DO_FSCK=0
# mounted and the script unmounted it.
REMOUNT=0
@@ -71,7 +71,7 @@ index 031b8453b..df153eb09 100755
errorexit "${SCRIPTNAME} must be run as root."
fi
-@@ -388,11 +388,11 @@ done
+@@ -372,11 +372,11 @@ done
#
# There are three top level commands: --fsextend, --fsreduce, --cryptresize.
@@ -85,7 +85,7 @@ index 031b8453b..df153eb09 100755
case "$FSTYPE" in
ext[234]) ;;
"xfs") ;;
-@@ -404,7 +404,7 @@ if [[ "$DO_FSEXTEND" -eq 1 || "$DO_FSREDUCE" -eq 1 ]]; then
+@@ -388,7 +388,7 @@ if [[ "$DO_FSEXTEND" -eq 1 || "$DO_FSREDUCE" -eq 1 ]]; then
fi
fi
@@ -94,7 +94,7 @@ index 031b8453b..df153eb09 100755
errorexit "Missing required --cryptpath for --cryptresize."
fi
-@@ -422,15 +422,15 @@ if [ ! -e "$DEVPATH" ]; then
+@@ -406,15 +406,15 @@ if [ ! -e "$DEVPATH" ]; then
errorexit "Device does not exist \"$DEVPATH\"."
fi
@@ -113,7 +113,7 @@ index 031b8453b..df153eb09 100755
errorexit "Cannot use --fsck with xfs."
fi
-@@ -440,7 +440,7 @@ if [ "$DO_MOUNT" -eq 1 ]; then
+@@ -424,7 +424,7 @@ if [ "$DO_MOUNT" -eq 1 ]; then
errorexit "Failed to create temp dir."
fi
# In case the script terminates without doing cleanup
@@ -122,6 +122,3 @@ index 031b8453b..df153eb09 100755
if [ "$TMP_MOUNT_DONE" -eq 1 ]; then
logmsg "exit unmount ${TMPDIR}"
umount "$TMPDIR"
---
-2.38.1
-
diff --git a/main/lvm2/APKBUILD b/main/lvm2/APKBUILD
index d6c88835820..be3cc6475f7 100644
--- a/main/lvm2/APKBUILD
+++ b/main/lvm2/APKBUILD
@@ -1,7 +1,7 @@
# Contributor: Jacek Migacz <jacekmigacz@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=lvm2
-pkgver=2.03.18
+pkgver=2.03.19
pkgrel=0
pkgdesc="Logical Volume Manager 2 utilities"
url="https://sourceware.org/lvm2/"
@@ -11,14 +11,11 @@ license="GPL-2.0-only LGPL-2.1-only"
# lvm2 will dlopen libs so we need to add explicit depend
depends="lvm2-libs=$pkgver-r$pkgrel"
depends_dev="linux-headers"
-makedepends_build="coreutils"
makedepends_host="$depends_dev libaio-dev util-linux-dev"
-_extra_deepends="bash coreutils"
-makedepends="$makedepends_build $makedepends_host $_extra_depends"
+makedepends="$makedepends_build $makedepends_host"
source="https://mirrors.kernel.org/sourceware/lvm2/LVM2.$pkgver.tgz
fix-stdio-usage.patch
library_dir-default-config.patch
- includes.patch
mlockall-default-config.patch
0001-lvresize-use-POSIX-shell.patch
lvm.initd
@@ -78,6 +75,7 @@ build() {
--with-cache-repair=/sbin/cache_repair \
--with-cache-restore=/sbin/cache_restore \
--with-dmeventd-path=/sbin/dmeventd \
+ --without-systemd-run \
--enable-udev_rules \
CLDFLAGS="$LDFLAGS"
make
@@ -146,12 +144,11 @@ extra() {
}
sha512sums="
-58043bdcad882065f15d772401d29fc7fb2d0a6b6b75063915dc38bb11cd847517dd18ae7e2acb3935e6c32ef620a275c2b2b9c307434f7457ea3203b87254c1 LVM2.2.03.18.tgz
+a40691f6f4c9300c95784be0fcb055a2b8e07bfdc87f000f2357ccb54fdb814a679fb79f5c9790a7440ef538e9997e46d56e539814bfdf138b4e76603aeb2994 LVM2.2.03.19.tgz
c65ef16840321d8a58373e872713eeccbc315a84bb35beebccb6bc6063295b0f54b7c0726c799efd8cafedd011c21f51ec8e85f8a50d0d5df80b7428aedf29c3 fix-stdio-usage.patch
b790cfcb55aa0362c7046c26a8e050708edecaf0233946adbb34d9c1d967d3614bc19e0c91695da4fd12d7b18adb74041ae11239cd635310cc44b8a7079ccbec library_dir-default-config.patch
-735cfd163643e24301eab2c244e396091fc1248c58b6fffb0d1a337bede78ece89341acdd2172b5cc65d9f2e944aaee320caa5dfb6ff3d6310dcd449e0c21929 includes.patch
-cf83e1357eefb8bdf1542850d66d8007d620e4050b5715dc83f4a921d36ce9ce47d0d13c5d85f2b0ff8318d2877eec2f63b931bd47417a81a538327af927da3e mlockall-default-config.patch
-fe7fb9c74c42aadc5d1d165423f2b31436c65bbab0c98d36787f5a49f54bb9342fd91aa68699e7a016550cf568faec34ae3c7ed47b56c15f9cd9ceeb3888db94 0001-lvresize-use-POSIX-shell.patch
+07f77491cffa0d9dcda86004e2df428d5d52652a3bda8037a4b09c9c786146253314a11bae42512231c664a8fae110fec815bd12135fc3c6152b94e2101f8213 mlockall-default-config.patch
+3cec0a44e44b15dcfc0bb22f8a4318e76bf719fe9a550b6cf99160ea4181707f81ba6a50c8dafedc942638b1ae8bfde901eeff83ba0d6cb8383a178274ba54a5 0001-lvresize-use-POSIX-shell.patch
a853078660fd2fd943538924f56e81dc5793294e26b8f61d93e6188893f15f4a438d33792b341c1865d61e03f4a371b7c7ee0db5f4130ef7cb7aeaeb9290086a lvm.initd
07caf8fa942290f3c953cc2463aaf55bac01d0bcb9351daf3880fa4d0eefb67fe00761c46a7a4da91cd2f8e492a12fed35853a15dc939cd80d19d3303bc3951d lvm.confd
ca06220065525e93347efb7a5746a367cf55cb03574e50eed29bd7c4eae036bdd199b52c42d81811b6e742649e73ab8e66525f663bed66f9d1d82d0efde50332 dmeventd.initd
diff --git a/main/lvm2/includes.patch b/main/lvm2/includes.patch
deleted file mode 100644
index a98b1bfddef..00000000000
--- a/main/lvm2/includes.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-diff --git a/tools/vgimportdevices.c b/tools/vgimportdevices.c
-index ab359d31c..e6160e3fa 100644
---- a/tools/vgimportdevices.c
-+++ b/tools/vgimportdevices.c
-@@ -16,6 +16,8 @@
- #include "lib/cache/lvmcache.h"
- #include "lib/device/device_id.h"
-
-+#include <sys/file.h>
-+
- struct vgimportdevices_params {
- uint32_t added_devices;
- };
diff --git a/main/lvm2/mlockall-default-config.patch b/main/lvm2/mlockall-default-config.patch
index e69de29bb2d..5e25893715e 100644
--- a/main/lvm2/mlockall-default-config.patch
+++ b/main/lvm2/mlockall-default-config.patch
@@ -0,0 +1,26 @@
+diff --git a/conf/example.conf.in b/conf/example.conf.in
+index 923d238..a069dac 100644
+--- a/conf/example.conf.in
++++ b/conf/example.conf.in
+@@ -1778,7 +1778,7 @@ activation {
+ # Prior to version 2.02.62, LVM used mlockall() to pin the whole
+ # process's memory while activating devices.
+ # This configuration option has an automatic default value.
+- # use_mlockall = 0
++ # use_mlockall = 1
+
+ # Configuration option activation/monitoring.
+ # Monitor LVs that are activated.
+diff --git a/lib/config/defaults.h b/lib/config/defaults.h
+index 571054d..1ff3637 100644
+--- a/lib/config/defaults.h
++++ b/lib/config/defaults.h
+@@ -66,7 +66,7 @@
+ #define DEFAULT_LVMLOCKD_LOCK_RETRIES 3
+ #define DEFAULT_LVMETAD_UPDATE_WAIT_TIME 10
+ #define DEFAULT_PRIORITISE_WRITE_LOCKS 1
+-#define DEFAULT_USE_MLOCKALL 0
++#define DEFAULT_USE_MLOCKALL 1
+ #define DEFAULT_METADATA_READ_ONLY 0
+ #define DEFAULT_LVDISPLAY_SHOWS_FULL_DEVICE_PATH 0
+ #define DEFAULT_UNKNOWN_DEVICE_NAME "[unknown]"