File test.patch of Package pesign-obs-integration
From 900e598c5fca01247340f02b44237adaf1a7d06e Mon Sep 17 00:00:00 2001
From: Callum Farmer <gmbr3@opensuse.org>
Date: Sun, 20 Apr 2025 16:58:53 +0100
Subject: [PATCH] Add RPM 4.19 scriptlets
* Add %preuntrans, %postuntrans scriptlets
Signed-off-by: Callum Farmer <gmbr3@opensuse.org>
---
pesign-gen-repackage-spec | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/pesign-gen-repackage-spec b/pesign-gen-repackage-spec
index 672ba6a..b9afdbd 100755
--- a/pesign-gen-repackage-spec
+++ b/pesign-gen-repackage-spec
@@ -145,6 +145,8 @@ my %script2tag = (
preun => "preun",
postun => "postun",
pretrans => "pretrans",
+ preuntrans => "preuntrans",
+ postuntrans => "postuntrans",
posttrans => "posttrans",
verifyscript => "verifyscript",
# FIXME: triggers
@@ -420,6 +422,8 @@ my %deptypes = (
preun => (1 << 11),
postun => (1 << 12),
verify => (1 << 13),
+ preuntrans => (1 << 20),
+ postuntrans => (1 << 21),
);
my %depflags = (
"<" => (1 << 1),
From f34d48cd43445b9eb743dabf0fa8c53210eecd51 Mon Sep 17 00:00:00 2001
From: Callum Farmer <gmbr3@opensuse.org>
Date: Mon, 21 Apr 2025 15:42:07 +0100
Subject: [PATCH] Accept none for compression
* Useful for kernel builds
Signed-off-by: Callum Farmer <gmbr3@opensuse.org>
---
README.md | 2 +-
pesign-gen-repackage-spec | 2 ++
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/README.md b/README.md
index b91205b..589520d 100644
--- a/README.md
+++ b/README.md
@@ -47,7 +47,7 @@ Consult the dh_signobs manpage for more information.
### Kernel Module Compression
When BRP_PESIGN_COMPRESS_MODULE is passed, the script tries to compress the
-kernel modules at the repackaging phase. Currently xz, gzip and zstd format is supported.
+kernel modules at the repackaging phase. Currently none, xz, gzip and zstd format is supported.
For enable the compression feature, put the following along with
BRP_PESIGN_FILES setup:
diff --git a/pesign-gen-repackage-spec b/pesign-gen-repackage-spec
index 672ba6a..be1b68c 100755
--- a/pesign-gen-repackage-spec
+++ b/pesign-gen-repackage-spec
@@ -491,6 +491,8 @@ sub print_files {
my $compress_ext = "";
my $compress_cmd = "";
+ $compress = "" if $compress eq "none";
+
if ($compress eq "xz") {
$compress_ext = ".xz";
$compress_cmd = "xz --lzma2=dict=2MiB -f";