commit:     b5a390b55e55d101008b7791524d61cfe6de8d79
Author:     Martin Dummer <martin.dummer <AT> gmx <DOT> net>
AuthorDate: Mon Jun 24 20:31:06 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Tue Jun 25 02:04:17 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b5a390b5

sys-fs/btrfsmaintenance: fix syntax error in shellscript

Signed-off-by: Martin Dummer <martin.dummer <AT> gmx.net>
Closes: https://github.com/gentoo/gentoo/pull/37282
Signed-off-by: Sam James <sam <AT> gentoo.org>

 ...ntenance-0.5.1.ebuild => btrfsmaintenance-0.5.1-r1.ebuild} |  1 +
 .../files/btrfsmaintenance-0.5.1-script-fix.patch             | 11 +++++++++++
 2 files changed, 12 insertions(+)

diff --git a/sys-fs/btrfsmaintenance/btrfsmaintenance-0.5.1.ebuild 
b/sys-fs/btrfsmaintenance/btrfsmaintenance-0.5.1-r1.ebuild
similarity index 97%
rename from sys-fs/btrfsmaintenance/btrfsmaintenance-0.5.1.ebuild
rename to sys-fs/btrfsmaintenance/btrfsmaintenance-0.5.1-r1.ebuild
index 82b7ba58cf41..e26232645159 100644
--- a/sys-fs/btrfsmaintenance/btrfsmaintenance-0.5.1.ebuild
+++ b/sys-fs/btrfsmaintenance/btrfsmaintenance-0.5.1-r1.ebuild
@@ -21,6 +21,7 @@ RDEPEND="
        systemd? ( sys-apps/systemd )
        !systemd? ( virtual/cron )
 "
+PATCHES=( "${FILESDIR}/${P}-script-fix.patch" )
 
 src_prepare() {
        # Fix config path into watching service

diff --git 
a/sys-fs/btrfsmaintenance/files/btrfsmaintenance-0.5.1-script-fix.patch 
b/sys-fs/btrfsmaintenance/files/btrfsmaintenance-0.5.1-script-fix.patch
new file mode 100644
index 000000000000..2bd65f80f0c7
--- /dev/null
+++ b/sys-fs/btrfsmaintenance/files/btrfsmaintenance-0.5.1-script-fix.patch
@@ -0,0 +1,11 @@
+--- a/btrfsmaintenance-functions
++++ b/btrfsmaintenance-functions
+@@ -101,7 +101,7 @@
+       else
+               # Flock older than 2.27 does not support --verbose option, check
+               # if it's available as we'd like to log the information
+-              if /usr/bin/flock --help 2>&1 | grep -q -- --verbose;
++              if /usr/bin/flock --help 2>&1 | grep -q -- --verbose; then
+                       verbose="--verbose"
+               fi
+ 

Reply via email to