summaryrefslogtreecommitdiff
path: root/sys-boot/os-prober/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-06-15 00:09:17 +0100
committerV3n3RiX <venerix@koprulu.sector>2024-06-15 00:09:17 +0100
commit6a7029e0f7370d4d5dfe9e31cc2719a870482392 (patch)
tree28c6c747114eaedfd2db81f86ac2ff3d7d13111e /sys-boot/os-prober/files
parent5e41a38157bb40e8513e8e34426e85faba672fe7 (diff)
gentoo auto-resync : 15:06:2024 - 00:09:17
Diffstat (limited to 'sys-boot/os-prober/files')
-rw-r--r--sys-boot/os-prober/files/os-prober-1.81-boot-detected-twice-v2.patch57
-rw-r--r--sys-boot/os-prober/files/os-prober-1.81-boot-detected-twice.patch46
2 files changed, 0 insertions, 103 deletions
diff --git a/sys-boot/os-prober/files/os-prober-1.81-boot-detected-twice-v2.patch b/sys-boot/os-prober/files/os-prober-1.81-boot-detected-twice-v2.patch
deleted file mode 100644
index 41e661bae86f..000000000000
--- a/sys-boot/os-prober/files/os-prober-1.81-boot-detected-twice-v2.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-diff --git a/common.sh b/common.sh
-index cc7a335..820caea 100644
---- a/common.sh
-+++ b/common.sh
-@@ -326,3 +326,26 @@ umount() {
- fi
- }
-
-+list_mounts() {
-+ if [ -f /proc/self/mountinfo ]; then
-+ local x dev mount devs found mountinfo_placeholders
-+ found=:
-+
-+ # mountinfo may have 10 or 11 fields depending on mount namespaces
-+ if [ $(head -n1 /proc/self/mountinfo | wc -w) == 10 ]; then
-+ mountinfo_placeholders="x x"
-+ else
-+ mountinfo_placeholders="x x x"
-+ fi
-+
-+ while read -r x x dev x mount ${mountinfo_placeholders} fs x; do
-+ if [ -L "/sys/dev/block/$dev" ]; then
-+ devs="/dev/`readlink \"/sys/dev/block/$dev\" | rev | cut -d/ -f1 | rev`"
-+ printf '%s %s %s\n' "$(mapdevfs "$devs")" "$mount" "$fs"
-+ found="return 0"
-+ fi
-+ done < /proc/self/mountinfo
-+ $found
-+ fi
-+ grep "^/dev/" /proc/mounts | parse_proc_mounts
-+}
-diff --git a/linux-boot-prober b/linux-boot-prober
-index bacf219..804d9fe 100755
---- a/linux-boot-prober
-+++ b/linux-boot-prober
-@@ -17,7 +17,7 @@ bootmnt=
- bootsv=
- bootuuid=
-
--grep "^/dev/" /proc/mounts | parse_proc_mounts >"$OS_PROBER_TMP/mounted-map" || true
-+list_mounts >"$OS_PROBER_TMP/mounted-map" || true
-
- if [ -z "$1" ]; then
- ERR=y
-diff --git a/os-prober b/os-prober
-index b76d85b..8b0c89b 100755
---- a/os-prober
-+++ b/os-prober
-@@ -128,7 +128,7 @@ done
-
- # We need to properly canonicalize partitions with mount points and partitions
- # used in RAID
--grep "^/dev/" /proc/mounts | parse_proc_mounts >"$OS_PROBER_TMP/mounted-map" || true
-+list_mounts >"$OS_PROBER_TMP/mounted-map" || true
- : >"$OS_PROBER_TMP/swaps-map"
- if [ -f /proc/swaps ]; then
- grep "^/dev/" /proc/swaps | parse_proc_swaps >"$OS_PROBER_TMP/swaps-map" || true
diff --git a/sys-boot/os-prober/files/os-prober-1.81-boot-detected-twice.patch b/sys-boot/os-prober/files/os-prober-1.81-boot-detected-twice.patch
deleted file mode 100644
index b06b31d0077e..000000000000
--- a/sys-boot/os-prober/files/os-prober-1.81-boot-detected-twice.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-diff -urN o/common.sh os-prober-1.81/common.sh
---- o/common.sh 2023-01-22 13:43:23.333123217 -0800
-+++ os-prober-1.81/common.sh 2023-01-22 13:44:49.408153101 -0800
-@@ -326,3 +326,18 @@
- fi
- }
-
-+list_mounts() {
-+ if [ -f /proc/self/mountinfo ]; then
-+ local x dev mount devs found
-+ found=:
-+ while read -r x x dev x mount x x fs x; do
-+ if [ -L "/sys/dev/block/$dev" ]; then
-+ devs="/dev/`readlink \"/sys/dev/block/$dev\" | rev | cut -d/ -f1 | rev`"
-+ printf '%s %s %s\n' "$(mapdevfs "$devs")" "$mount" "$fs"
-+ found="return 0"
-+ fi
-+ done < /proc/self/mountinfo
-+ $found
-+ fi
-+ grep "^/dev/" /proc/mounts | parse_proc_mounts
-+}
-diff -urN o/linux-boot-prober os-prober-1.81/linux-boot-prober
---- o/linux-boot-prober 2023-01-22 13:43:23.334123229 -0800
-+++ os-prober-1.81/linux-boot-prober 2023-01-22 13:43:34.897260733 -0800
-@@ -17,7 +17,7 @@
- bootsv=
- bootuuid=
-
--grep "^/dev/" /proc/mounts | parse_proc_mounts >"$OS_PROBER_TMP/mounted-map" || true
-+list_mounts >"$OS_PROBER_TMP/mounted-map" || true
-
- if [ -z "$1" ]; then
- ERR=y
-diff -urN o/os-prober os-prober-1.81/os-prober
---- o/os-prober 2023-01-22 13:43:23.334123229 -0800
-+++ os-prober-1.81/os-prober 2023-01-22 13:43:34.897260733 -0800
-@@ -128,7 +128,7 @@
-
- # We need to properly canonicalize partitions with mount points and partitions
- # used in RAID
--grep "^/dev/" /proc/mounts | parse_proc_mounts >"$OS_PROBER_TMP/mounted-map" || true
-+list_mounts >"$OS_PROBER_TMP/mounted-map" || true
- : >"$OS_PROBER_TMP/swaps-map"
- if [ -f /proc/swaps ]; then
- grep "^/dev/" /proc/swaps | parse_proc_swaps >"$OS_PROBER_TMP/swaps-map" || true