39 lines
1.1 KiB
Diff
39 lines
1.1 KiB
Diff
From d0df2f1aef9784e09467a8b513fa14135a6d3928 Mon Sep 17 00:00:00 2001
|
|
From: xujing <xujing125@huawei.com>
|
|
Date: Tue, 8 Nov 2022 10:51:34 +0800
|
|
Subject: [PATCH] fix --cap-from-fs does not work
|
|
|
|
---
|
|
rpmrebuild_files.sh | 2 +-
|
|
rpmrebuild_parser.src | 1 +
|
|
2 files changed, 2 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/rpmrebuild_files.sh b/rpmrebuild_files.sh
|
|
index 1afc484..fb40709 100755
|
|
--- a/rpmrebuild_files.sh
|
|
+++ b/rpmrebuild_files.sh
|
|
@@ -193,7 +193,7 @@ while :; do
|
|
|
|
# %caps handling
|
|
if [ "X$RPMREBUILD_CAP_FROM_FS" = "Xyes" ]; then
|
|
- file_cap=$( getcap "$file" | cut -f2 -d= )
|
|
+ file_cap=$( getcap "$file" | cut -f2 -d' ' )
|
|
else
|
|
# get capability from rpm query
|
|
[ "X$file_cap" = "X(none)" ] && file_cap=""
|
|
diff --git a/rpmrebuild_parser.src b/rpmrebuild_parser.src
|
|
index 2f400ac..cbdb516 100755
|
|
--- a/rpmrebuild_parser.src
|
|
+++ b/rpmrebuild_parser.src
|
|
@@ -1235,6 +1235,7 @@ function CommandLineParsing
|
|
|
|
export RPMREBUILD_COMMENT_MISSING="no"
|
|
export RPMREBUILD_PUG_FROM_FS="no"
|
|
+ export RPMREBUILD_CAP_FROM_FS="no"
|
|
export RPMREBUILD_WARNING="no"
|
|
|
|
PAQUET=""
|
|
--
|
|
2.27.0
|
|
|