From f089dba5c9cde0a1dd20d6fa66fe279f8943c9b308518d1f11fecbf6baeb38ca Mon Sep 17 00:00:00 2001 From: "Dr. Werner Fink" Date: Wed, 11 Jan 2023 13:18:15 +0000 Subject: [PATCH] Handle script executable Zip archives OBS-URL: https://build.opensuse.org/package/show/Base:System/file?expand=0&rev=266 --- dc71304b.patch | 27 +++++++++++++++++++++++++++ file.changes | 6 ++++++ file.spec | 3 +++ 3 files changed, 36 insertions(+) create mode 100644 dc71304b.patch diff --git a/dc71304b.patch b/dc71304b.patch new file mode 100644 index 0000000..ca7acd7 --- /dev/null +++ b/dc71304b.patch @@ -0,0 +1,27 @@ +From dc71304b3b1fd2ed5f7098d59fb7f6ef10cfdc85 Mon Sep 17 00:00:00 2001 +From: Christos Zoulas +Date: Sat, 31 Dec 2022 20:24:08 +0000 +Subject: [PATCH] pyzip improvements (FC Stegerman) + +--- + magic/Magdir/archive | 7 ++++++- + 1 file changed, 6 insertions(+), 1 deletion(-) + +--- magic/Magdir/archive ++++ magic/Magdir/archive 2023-01-11 12:59:19.451975877 +0000 +@@ -1876,9 +1876,14 @@ + # https://en.wikipedia.org/wiki/ZIP_(file_format)#End_of_central_directory_record_(EOCD) + # by Michal Gorny + -2 uleshort 0 +->&-22 string PK\005\006 Zip archive, with extra data prepended ++>&-22 string PK\005\006 ++# without #! ++>>0 string !#! Zip archive, with extra data prepended + !:mime application/zip + !:ext zip/cbz ++# with #! ++>>0 string/w #!\ a ++>>>&-1 string/T x %s script executable (Zip archive) + + # ACE archive (from http://www.wotsit.org/download.asp?f=ace) + # by Stefan `Sec` Zehl diff --git a/file.changes b/file.changes index c1046d9..fe13550 100644 --- a/file.changes +++ b/file.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Jan 11 13:06:56 UTC 2023 - Dr. Werner Fink + +- Add patch dc71304b.patch + * Handle script executable Zip archives + ------------------------------------------------------------------- Tue Jan 10 13:28:51 UTC 2023 - Dr. Werner Fink diff --git a/file.spec b/file.spec index ed14613..c20b1ce 100644 --- a/file.spec +++ b/file.spec @@ -63,6 +63,8 @@ Patch31: file-5.19-biorad.dif Patch32: file-5.19-clicfs.dif Patch37: file-secure_getenv.patch Patch39: file-5.28-btrfs-image.dif +# PATCH-FIX-UPSTREAM +Patch42: dc71304b.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build %global _sysconfdir /etc %global magicdir %{_datadir}/file @@ -107,6 +109,7 @@ to develop applications that require the magic "file" interface. %prep %setup -q -n file-%{version} +%patch42 -p0 %patch1 -p0 -b .misc %patch4 -p0 -b .conf %patch5 -p0 -b .tex