forked from pool/pesign-obs-integration
Accepting request 987156 from Base:System
OBS-URL: https://build.opensuse.org/request/show/987156 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/pesign-obs-integration?expand=0&rev=48
This commit is contained in:
commit
6f006467c6
28
attr.patch
Normal file
28
attr.patch
Normal file
@ -0,0 +1,28 @@
|
||||
From 118395dd551022faea75debac0dca30515f03949 Mon Sep 17 00:00:00 2001
|
||||
From: Callum Farmer <gmbr3@opensuse.org>
|
||||
Date: Wed, 22 Jun 2022 14:41:34 +0100
|
||||
Subject: [PATCH] Fix %attr issues
|
||||
|
||||
1) Avoid assigning %attr's to symlinks which causes rpmbuild spam
|
||||
2) Change perms mask to 07777 to ensure SUID/SGID is copied over
|
||||
---
|
||||
pesign-gen-repackage-spec | 6 ++++--
|
||||
1 file changed, 4 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pesign-gen-repackage-spec b/pesign-gen-repackage-spec
|
||||
index 688c375..e5c961a 100755
|
||||
--- a/pesign-gen-repackage-spec
|
||||
+++ b/pesign-gen-repackage-spec
|
||||
@@ -416,8 +416,10 @@ sub print_files {
|
||||
$attrs .= "\%dir ";
|
||||
utime($f->{mtime}, $f->{mtime}, $path);
|
||||
}
|
||||
- $attrs .= sprintf('%%attr(%04o, %s, %s) ', ($f->{mode} & 0777),
|
||||
- $f->{owner}, $f->{group});
|
||||
+ unless (-l "$path") {
|
||||
+ $attrs .= sprintf('%%attr(%04o, %s, %s) ', ($f->{mode} & 07777),
|
||||
+ $f->{owner}, $f->{group});
|
||||
+ }
|
||||
if ($f->{flags} & $filetypes{config}) {
|
||||
$attrs .= "%config ";
|
||||
my @cfg_attrs;
|
41
lang.patch
Normal file
41
lang.patch
Normal file
@ -0,0 +1,41 @@
|
||||
From bce11d8c51c7298887a5c576ba0f577cac80eb5e Mon Sep 17 00:00:00 2001
|
||||
From: Callum Farmer <gmbr3@opensuse.org>
|
||||
Date: Thu, 23 Jun 2022 13:20:37 +0100
|
||||
Subject: [PATCH] Support %lang
|
||||
|
||||
---
|
||||
pesign-gen-repackage-spec | 7 +++++--
|
||||
1 file changed, 5 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pesign-gen-repackage-spec b/pesign-gen-repackage-spec
|
||||
index 688c375..3d1e1d2 100755
|
||||
--- a/pesign-gen-repackage-spec
|
||||
+++ b/pesign-gen-repackage-spec
|
||||
@@ -166,7 +166,7 @@ sub load_package {
|
||||
$res{$tag} = query_single($rpm, $tag);
|
||||
}
|
||||
my @files;
|
||||
- my @list = query_array($rpm, qw(filenames fileflags filemodes fileusername filegroupname filesizes filemtimes filelinktos fileverifyflags));
|
||||
+ my @list = query_array($rpm, qw(filenames fileflags filemodes fileusername filegroupname filesizes filemtimes filelinktos fileverifyflags filelangs));
|
||||
for my $file (@list) {
|
||||
my $new = {
|
||||
name => $file->[0],
|
||||
@@ -178,6 +178,7 @@ sub load_package {
|
||||
mtime => $file->[6],
|
||||
target => $file->[7],
|
||||
verify => $file->[8],
|
||||
+ lang => $file->[9],
|
||||
};
|
||||
push(@files, $new);
|
||||
if ($new->{name} =~ /\.ko$/ && S_ISREG($new->{mode})) {
|
||||
@@ -462,7 +463,9 @@ sub print_files {
|
||||
if ($verify_attrs) {
|
||||
$attrs .= "%verify(not $verify_attrs) ";
|
||||
}
|
||||
-
|
||||
+ if ($f->{lang} ne "") {
|
||||
+ $attrs .= sprintf('%%lang(%s) ', $f->{lang});
|
||||
+ }
|
||||
if ($compress ne "" &&
|
||||
$f->{name} =~ /\.ko$/ && S_ISREG($f->{mode})) {
|
||||
chmod($f->{mode}, $path);
|
@ -1,3 +1,11 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Jun 22 20:02:36 UTC 2022 - Callum Farmer <gmbr3@opensuse.org>
|
||||
|
||||
- Add attr.patch to fix:
|
||||
* Avoid assigning %attr's to symlinks which causes rpmbuild spam
|
||||
* Change perms mask to 07777 to ensure SUID/SGID is copied over
|
||||
- Add lang.patch to support %lang
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jun 15 11:13:51 UTC 2022 - gmbr3@opensuse.org
|
||||
|
||||
|
@ -26,6 +26,8 @@ Group: Development/Tools/Other
|
||||
URL: https://en.opensuse.org/openSUSE:UEFI_Image_File_Sign_Tools
|
||||
Source: %{name}-%{version}.tar.gz
|
||||
Patch: order.patch
|
||||
Patch1: attr.patch
|
||||
Patch2: lang.patch
|
||||
BuildRequires: openssl
|
||||
Requires: fipscheck
|
||||
Requires: mozilla-nss-tools
|
||||
|
Loading…
x
Reference in New Issue
Block a user