diff --git a/file-5.31-awk-perl-recognition.patch b/file-5.31-awk-perl-recognition.patch deleted file mode 100644 index 7dbd659..0000000 --- a/file-5.31-awk-perl-recognition.patch +++ /dev/null @@ -1,98 +0,0 @@ -From 898f5d27b66b5d5592cb56fa9da5b776628ea6ca Mon Sep 17 00:00:00 2001 -From: Christos Zoulas -Date: Wed, 31 May 2017 15:48:50 +0000 -Subject: [PATCH] Fix \s vs \w confusion. - -Upstream commit: https://github.com/file/file/commit/898f5d27b66b5d5592cb56fa9da5b776628ea6ca - -Fixes awk/perl script recognition - -Signed-off-by: Marek Cermak ---- - magic/Magdir/commands | 4 ++-- - magic/Magdir/images | 14 +++++++------- - magic/Magdir/python | 4 ++-- - 3 files changed, 11 insertions(+), 11 deletions(-) - -diff --git a/magic/Magdir/commands b/magic/Magdir/commands -index 1a46efd8..f4326a9e 100644 ---- a/magic/Magdir/commands -+++ b/magic/Magdir/commands -@@ -56,7 +56,7 @@ - !:mime text/x-awk - 0 string/wt #!\ /usr/bin/awk awk script text executable - !:mime text/x-awk --0 regex/4096 =^[A-Za-z0-9_]{0,100}BEGIN[A-Za-z0-9_]{0,100}[{] awk or perl script text -+0 regex/4096 =^[\040\t\f\r\n]{0,100}BEGIN[\040\t\f\r\n]{0,100}[{] awk or perl script text - - # AT&T Bell Labs' Plan 9 shell - 0 string/wt #!\ /bin/rc Plan 9 rc shell script text executable -diff --git a/magic/Magdir/images b/magic/Magdir/images -index ce68e00d..d14c1de1 100644 ---- a/magic/Magdir/images -+++ b/magic/Magdir/images -@@ -175,42 +175,42 @@ - >>>&0 regex =[0-9]{1,50} \b %s - - 0 search/1 P1 -->0 regex/4 P1[A-Za-z0-9_] -+>0 regex/4 P1[\040\t\f\r\n] - >>0 use netpbm - >>>0 string x \b, bitmap - !:strength + 45 - !:mime image/x-portable-bitmap - - 0 search/1 P2 -->0 regex/4 P2[A-Za-z0-9_] -+>0 regex/4 P2[\040\t\f\r\n] - >>0 use netpbm - >>>0 string x \b, greymap - !:strength + 45 - !:mime image/x-portable-greymap - - 0 search/1 P3 -->0 regex/4 P3[A-Za-z0-9_] -+>0 regex/4 P3[\040\t\f\r\n] - >>0 use netpbm - >>>0 string x \b, pixmap - !:strength + 45 - !:mime image/x-portable-pixmap - - 0 string P4 -->0 regex/4 P4[A-Za-z0-9_] -+>0 regex/4 P4[\040\t\f\r\n] - >>0 use netpbm - >>>0 string x \b, rawbits, bitmap - !:strength + 45 - !:mime image/x-portable-bitmap - - 0 string P5 -->0 regex/4 P5[A-Za-z0-9_] -+>0 regex/4 P5[\040\t\f\r\n] - >>0 use netpbm - >>>0 string x \b, rawbits, greymap - !:strength + 45 - !:mime image/x-portable-greymap - - 0 string P6 -->0 regex/4 P6[A-Za-z0-9_] -+>0 regex/4 P6[\040\t\f\r\n] - >>0 use netpbm - >>>0 string x \b, rawbits, pixmap - !:strength + 45 -diff --git a/magic/Magdir/python b/magic/Magdir/python -index 81d1cc39..d6c2220a 100644 ---- a/magic/Magdir/python -+++ b/magic/Magdir/python -@@ -64,7 +64,7 @@ - # except: or finally: - # block - 0 search/4096 try: -->&0 regex \^[A-Za-z0-9_]*except.*: Python script text executable -+>&0 regex \^[\040\t\f\r\n]*except.*: Python script text executable - !:strength + 15 - !:mime text/x-python - >&0 search/4096 finally: Python script text executable --- -2.13.3 - diff --git a/file-5.31-gconv-cache-recognition.patch b/file-5.31-gconv-cache-recognition.patch deleted file mode 100644 index 55ed2fe..0000000 --- a/file-5.31-gconv-cache-recognition.patch +++ /dev/null @@ -1,49 +0,0 @@ -From 2093d2fde94ae6dd094196a455bf4f70d7e84747 Mon Sep 17 00:00:00 2001 -From: Christos Zoulas -Date: Thu, 10 Aug 2017 11:01:38 +0000 -Subject: [PATCH] Add gconv magic (Marek Cermak) - -Recognition of iconv/gconv module configuration cache - -https://bugzilla.redhat.com/show_bug.cgi?id=1342428 - -Upstream commit: https://github.com/file/file/commit/2093d2fde94ae6dd094196a455bf4f70d7e84747 - -Signed-off-by: Marek Cermak ---- - magic/Magdir/gconv | 10 ++++++++++ - magic/Makefile.am | 3 ++- - 2 files changed, 12 insertions(+), 1 deletion(-) - create mode 100644 magic/Magdir/gconv - -diff --git a/magic/Magdir/gconv b/magic/Magdir/gconv -new file mode 100644 -index 00000000..eec5ddcd ---- /dev/null -+++ b/magic/Magdir/gconv -@@ -0,0 +1,10 @@ -+ -+#------------------------------------------------------------------------------ -+# $File: gconv -+# gconv: file(1) magic for iconv/gconv module configuration cache -+# -+# Magic number defined in glibc/iconv/iconvconfig.h as GCONVCACHE_MAGIC -+# -+# From: Marek Cermak -+# -+0 lelong 0x20010324 gconv module configuration cache data -diff --git a/magic/Makefile.am b/magic/Makefile.am -index 25b8c3d4..5259a478 100644 ---- a/magic/Makefile.am -+++ b/magic/Makefile.am -@@ -99,6 +99,7 @@ $(MAGIC_FRAGMENT_DIR)/fsav \ - $(MAGIC_FRAGMENT_DIR)/fusecompress \ - $(MAGIC_FRAGMENT_DIR)/games \ - $(MAGIC_FRAGMENT_DIR)/gcc \ -+$(MAGIC_FRAGMENT_DIR)/gconv \ - $(MAGIC_FRAGMENT_DIR)/geo \ - $(MAGIC_FRAGMENT_DIR)/geos \ - $(MAGIC_FRAGMENT_DIR)/gimp \ --- -2.13.3 - diff --git a/file-5.31-mo-file-recognition.patch b/file-5.31-mo-file-recognition.patch deleted file mode 100644 index 3067d89..0000000 --- a/file-5.31-mo-file-recognition.patch +++ /dev/null @@ -1,32 +0,0 @@ -From 2e5e9e16a4847b2e60cabc70e6b9bd7d633cb68a Mon Sep 17 00:00:00 2001 -From: Christos Zoulas -Date: Sat, 22 Jul 2017 17:21:24 +0000 -Subject: [PATCH] Strength decreased in magic file magic/Magdir/dump for new-fs - dump file (little endian) to correctly recognize '*.mo' GNU message catalog - (little endian). - -https://bugzilla.redhat.com/show_bug.cgi?id=1226215 - -Upstream commit: https://github.com/file/file/commit/2e5e9e16a4847b2e60cabc70e6b9bd7d633cb68a - -Signed-off-by: Marek Cermak ---- - magic/Magdir/dump | 4 +++- - 1 file changed, 3 insertions(+), 1 deletion(-) - -diff --git a/magic/Magdir/dump b/magic/Magdir/dump -index 64742b7a..c5711661 100644 ---- a/magic/Magdir/dump -+++ b/magic/Magdir/dump -@@ -69,6 +69,8 @@ - >0 use old-dump-be - - 24 lelong 60012 new-fs dump file (little endian), -+# to correctly recognize '*.mo' GNU message catalog (little endian) -+!:strength - 15 - >0 use \^new-dump-be - - 24 lelong 60011 old-fs dump file (little endian), --- -2.13.3 - diff --git a/file-5.31-ruby-recognition.patch b/file-5.31-ruby-recognition.patch deleted file mode 100644 index 9794a55..0000000 --- a/file-5.31-ruby-recognition.patch +++ /dev/null @@ -1,78 +0,0 @@ -From d56eb7ea0b9c2a4edec17032a92fe66aebb1aa3a Mon Sep 17 00:00:00 2001 -From: Christos Zoulas -Date: Mon, 14 Aug 2017 13:39:18 +0000 -Subject: [PATCH] improvements (Marek Cermak) - -Fixed Ruby script recognition and classification - -https://bugzilla.redhat.com/show_bug.cgi?id=1050897 - -Upstream commit: https://github.com/file/file/commit/d56eb7ea0b9c2a4edec17032a92fe66aebb1aa3a - -Signed-off-by: Marek Cermak ---- - magic/Magdir/ruby | 35 +++++++++++++++++++++++++++-------- - 1 file changed, 27 insertions(+), 8 deletions(-) - -diff --git a/magic/Magdir/ruby b/magic/Magdir/ruby -index cc3abd0..a6b73d9 100644 ---- a/magic/Magdir/ruby -+++ b/magic/Magdir/ruby -@@ -6,27 +6,46 @@ - # From: Reuben Thomas - - # Ruby scripts --0 search/1/w #!\ /usr/bin/ruby Ruby script text executable -+0 search/1/w #!\ /usr/bin/ruby Ruby script text executable - !:strength + 15 - !:mime text/x-ruby - 0 search/1/w #!\ /usr/local/bin/ruby Ruby script text executable - !:strength + 15 - !:mime text/x-ruby --0 search/1 #!/usr/bin/env\ ruby Ruby script text executable -+0 search/1 #!/usr/bin/env\ ruby Ruby script text executable - !:strength + 15 - !:mime text/x-ruby --0 search/1 #!\ /usr/bin/env\ ruby Ruby script text executable -+0 search/1 #!\ /usr/bin/env\ ruby Ruby script text executable - !:strength + 15 - !:mime text/x-ruby - - # What looks like ruby, but does not have a shebang - # (modules and such) - # From: Lubomir Rintel --0 regex \^[\ \t]*require[\ \t]'[A-Za-z_/]+' -->0 regex include\ [A-Z]|def\ [a-z]|\ do$ -->>0 regex \^[\ \t]*end([\ \t]*[;#].*)?$ Ruby script text -+0 regex \^[[:space:]]*require[[:space:]]'[A-Za-z_/]+' -+>0 regex def\ [a-z]|\ do$ -+>>&0 regex \^[[:space:]]*end([[:space:]]+[;#].*)?$ Ruby script text -+!:strength + 30 - !:mime text/x-ruby --0 regex \^[\ \t]*(class|module)[\ \t][A-Z] -+0 regex \^[[:space:]]*(class|module)[[:space:]][A-Z] - >0 regex (modul|includ)e\ [A-Z]|def\ [a-z] -->>0 regex \^[\ \t]*end([\ \t]*[;#].*)?$ Ruby module source text -+>>&0 regex \^[[:space:]]*end([[:space:]]+[;#].*)?$ Ruby script text -+!:strength + 30 -+!:mime text/x-ruby -+# Classes with no modules or defs, beats simple ASCII -+0 regex \^[[:space:]]*(class|module)[[:space:]][A-Z] -+>&0 regex \^[[:space:]]*end([[:space:]]+[;#if].*)?$ Ruby script text -+!:strength + 10 -+!:mime text/x-ruby -+# Looks for function definiton to balance python magic -+# def name (args) -+# end -+0 regex \^[[:space:]]*def\ [a-z]|def\ [[:alpha:]]+::[a-z] -+>&0 regex \^[[:space:]]*end([[:space:]]+[;#].*)?$ Ruby script text -+!:strength + 10 -+!:mime text/x-ruby -+ -+0 regex \^[[:space:]]*require[[:space:]]'[A-Za-z_/]+' Ruby script text -+!:mime text/x-ruby -+0 regex \^[[:space:]]*include\ ([A-Z]+[a-z]*(::))+ Ruby script text - !:mime text/x-ruby --- -2.13.3 - diff --git a/file-5.31.tar.gz.asc b/file-5.31.tar.gz.asc deleted file mode 100644 index 1de7c20..0000000 --- a/file-5.31.tar.gz.asc +++ /dev/null @@ -1,6 +0,0 @@ ------BEGIN PGP SIGNATURE----- - -iEYEABECAAYFAlkkdXQACgkQcREqsWyzOzo0vwCg2YsLRBAmUk7Qukg81uiCwUjp -iggAoJJ3ftx9zysH6PPNCmc2q8tMRlaJ -=Cxli ------END PGP SIGNATURE----- diff --git a/file-5.32.tar.gz.asc b/file-5.32.tar.gz.asc new file mode 100644 index 0000000..5187306 --- /dev/null +++ b/file-5.32.tar.gz.asc @@ -0,0 +1,6 @@ +-----BEGIN PGP SIGNATURE----- + +iEYEABECAAYFAlmqdRAACgkQcREqsWyzOzpNIgCdF72HRFOdlkHZJbFS/l9bd3lf +3I4AoIZXgEDPf6vfVtAnSuWz+hPxDjxb +=oLAQ +-----END PGP SIGNATURE----- diff --git a/file.spec b/file.spec index 21aff1c..d471541 100644 --- a/file.spec +++ b/file.spec @@ -2,8 +2,8 @@ Summary: A utility for determining file types Name: file -Version: 5.31 -Release: 10%{?dist} +Version: 5.32 +Release: 1%{?dist} License: BSD Group: Applications/File Source0: ftp://ftp.astron.com/pub/file/file-%{version}.tar.gz @@ -17,10 +17,6 @@ Patch4: file-5.04-volume_key.patch Patch5: file-5.04-man-return-code.patch # picked from upstream -Patch6: file-5.31-mo-file-recognition.patch -Patch7: file-5.31-awk-perl-recognition.patch -Patch8: file-5.31-gconv-cache-recognition.patch -Patch9: file-5.31-ruby-recognition.patch URL: http://www.darwinsys.com/file/ Requires: file-libs = %{version}-%{release} @@ -186,6 +182,9 @@ cd %{py3dir} %endif %changelog +* Mon Sep 04 2017 Kamil Dudka - 5.32-1 +- update to new version 5.32 + * Sat Aug 19 2017 Zbigniew Jędrzejewski-Szmek - 5.31-10 - Python 2 binary package renamed to python2-file See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3 diff --git a/sources b/sources index db80913..d2bb2af 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (file-5.31.tar.gz) = 0d024787b5b1fdd6469627d2b4081082fa66fff7a1a84ce06a0710db1dad6b9bd395dc2b758ebc733d14b7e9d135fc2fefcb62919fb98bd140b88445bac89651 +SHA512 (file-5.32.tar.gz) = 315343229fa196335389544ee8010e9e80995ef4721938492dedcfb0465dfc45e1feb96f26dfe53cab484fb5d9bac54d2d72917fbfd28a1d998c6ad8c8f9792f