forked from pool/pesign-obs-integration
Accepting request 693109 from home:gary_lin:branches:Base:System
- rpm: forward the missing rpm bits (bsc#1114605) + 0001-Passthrough-license-tag.patch + 0002-Enable-find_provides-and-requires.patch OBS-URL: https://build.opensuse.org/request/show/693109 OBS-URL: https://build.opensuse.org/package/show/Base:System/pesign-obs-integration?expand=0&rev=72
This commit is contained in:
parent
923a1088fe
commit
dd0209890e
41
0001-Passthrough-license-tag.patch
Normal file
41
0001-Passthrough-license-tag.patch
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
From 2bd2e52380ba9c568ceba2d8d92b9cd50a22c881 Mon Sep 17 00:00:00 2001
|
||||||
|
From: "Bernhard M. Wiedemann" <bwiedemann@suse.de>
|
||||||
|
Date: Tue, 2 Apr 2019 17:02:13 +0200
|
||||||
|
Subject: [PATCH 1/2] Passthrough %license tag
|
||||||
|
|
||||||
|
matters for fwupd package file /usr/share/licenses/fwupd/COPYING
|
||||||
|
|
||||||
|
and added 3 more bits from rpm/lib/rpmfiles.h
|
||||||
|
---
|
||||||
|
pesign-gen-repackage-spec | 8 +++++++-
|
||||||
|
1 file changed, 7 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/pesign-gen-repackage-spec b/pesign-gen-repackage-spec
|
||||||
|
index 1856d9d..9cd374a 100755
|
||||||
|
--- a/pesign-gen-repackage-spec
|
||||||
|
+++ b/pesign-gen-repackage-spec
|
||||||
|
@@ -345,6 +345,10 @@ my %filetypes = (
|
||||||
|
missingok => (1 << 3),
|
||||||
|
noreplace => (1 << 4),
|
||||||
|
ghost => (1 << 6),
|
||||||
|
+ license => (1 << 7),
|
||||||
|
+ readme => (1 << 8),
|
||||||
|
+ pubkey => (1 << 11),
|
||||||
|
+ artifact => (1 << 12),
|
||||||
|
);
|
||||||
|
|
||||||
|
my %verifyflags = (
|
||||||
|
@@ -381,7 +385,9 @@ sub print_files {
|
||||||
|
}
|
||||||
|
$attrs .= "(" . join(",", @cfg_attrs) . ")" if @cfg_attrs;
|
||||||
|
}
|
||||||
|
- $attrs .= "%doc " if $f->{flags} & $filetypes{doc};
|
||||||
|
+ for my $filetype (qw(doc license readme pubkey artifact)) {
|
||||||
|
+ $attrs .= "%$filetype " if $f->{flags} & $filetypes{$filetype};
|
||||||
|
+ }
|
||||||
|
if ($f->{flags} & $filetypes{ghost}) {
|
||||||
|
$attrs .= "%ghost ";
|
||||||
|
if (S_ISREG($f->{mode})) {
|
||||||
|
--
|
||||||
|
2.21.0
|
||||||
|
|
55
0002-Enable-find_provides-and-requires.patch
Normal file
55
0002-Enable-find_provides-and-requires.patch
Normal file
@ -0,0 +1,55 @@
|
|||||||
|
From 42b934760a75cf077d3c5831aaa14d3d104ba5cd Mon Sep 17 00:00:00 2001
|
||||||
|
From: "Bernhard M. Wiedemann" <bwiedemann@suse.de>
|
||||||
|
Date: Wed, 3 Apr 2019 05:48:28 +0200
|
||||||
|
Subject: [PATCH 2/2] Enable find_provides and requires
|
||||||
|
|
||||||
|
to get automatic provides instead of manual ones
|
||||||
|
like the original package did
|
||||||
|
|
||||||
|
Without this patch,
|
||||||
|
rpm -qpv --provides $rpm
|
||||||
|
differed significantly between OBS build and local osc build.
|
||||||
|
---
|
||||||
|
pesign-gen-repackage-spec | 12 +++++++-----
|
||||||
|
1 file changed, 7 insertions(+), 5 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/pesign-gen-repackage-spec b/pesign-gen-repackage-spec
|
||||||
|
index 9cd374a..61eb8ba 100755
|
||||||
|
--- a/pesign-gen-repackage-spec
|
||||||
|
+++ b/pesign-gen-repackage-spec
|
||||||
|
@@ -246,10 +246,6 @@ sub print_package {
|
||||||
|
if ($is_main) {
|
||||||
|
print SPEC "Name: $p->{name}\n";
|
||||||
|
print SPEC "Buildroot: $directory\n";
|
||||||
|
- print SPEC "\%define _use_internal_dependency_generator 0\n";
|
||||||
|
- print SPEC "\%define __find_provides %{nil}\n";
|
||||||
|
- print SPEC "\%define __find_requires %{nil}\n";
|
||||||
|
- print SPEC "\%define __find_supplements %{nil}\n";
|
||||||
|
if ($p->{nosource}) {
|
||||||
|
# We do not generate any no(src).rpm, but we want the
|
||||||
|
# %{sourcerpm} tag in the binary packages to match.
|
||||||
|
@@ -309,14 +305,20 @@ my %depflags = (
|
||||||
|
"<" => (1 << 1),
|
||||||
|
">" => (1 << 2),
|
||||||
|
"=" => (1 << 3),
|
||||||
|
+ find_requires => (1 << 14),
|
||||||
|
+ find_provides => (1 << 15),
|
||||||
|
rpmlib => (1 << 24),
|
||||||
|
+ config => (1 << 28),
|
||||||
|
);
|
||||||
|
|
||||||
|
sub print_deps {
|
||||||
|
my ($depname, $list) = @_;
|
||||||
|
|
||||||
|
+DEPLOOP:
|
||||||
|
foreach my $d (@$list) {
|
||||||
|
- next if ($d->{flags} & $depflags{rpmlib});
|
||||||
|
+ for my $flag (qw(rpmlib config find_requires find_provides)) {
|
||||||
|
+ next DEPLOOP if ($d->{flags} & $depflags{$flag});
|
||||||
|
+ }
|
||||||
|
|
||||||
|
print SPEC $depname;
|
||||||
|
my @deptypes;
|
||||||
|
--
|
||||||
|
2.21.0
|
||||||
|
|
@ -1,3 +1,10 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Apr 11 03:45:03 UTC 2019 - Gary Ching-Pang Lin <glin@suse.com>
|
||||||
|
|
||||||
|
- rpm: forward the missing rpm bits (bsc#1114605)
|
||||||
|
+ 0001-Passthrough-license-tag.patch
|
||||||
|
+ 0002-Enable-find_provides-and-requires.patch
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Dec 11 10:19:44 UTC 2018 - glin@suse.com
|
Tue Dec 11 10:19:44 UTC 2018 - glin@suse.com
|
||||||
- Version 10.1
|
- Version 10.1
|
||||||
|
@ -32,6 +32,8 @@ Requires: pesign
|
|||||||
BuildRequires: openssl
|
BuildRequires: openssl
|
||||||
Url: http://en.opensuse.org/openSUSE:UEFI_Image_File_Sign_Tools
|
Url: http://en.opensuse.org/openSUSE:UEFI_Image_File_Sign_Tools
|
||||||
Source: %{name}_%{version}.tar.gz
|
Source: %{name}_%{version}.tar.gz
|
||||||
|
Patch1: 0001-Passthrough-license-tag.patch
|
||||||
|
Patch2: 0002-Enable-find_provides-and-requires.patch
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
# suse-module-tools <= 15.0.10 contains modsign-verify
|
# suse-module-tools <= 15.0.10 contains modsign-verify
|
||||||
Requires: suse-module-tools >= 15.0.10
|
Requires: suse-module-tools >= 15.0.10
|
||||||
@ -42,6 +44,8 @@ boot loader, kernel and kernel modules in the openSUSE Buildservice.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -D -n %{name}
|
%setup -D -n %{name}
|
||||||
|
%patch1 -p1
|
||||||
|
%patch2 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user