[gentoo-commits] repo/gentoo:master commit in: app-misc/binwalk/files/

2024-03-05 Thread Petr Vaněk
commit: 6f49f061d0dbde70ef35f2398eb5e4d25d149eb3
Author: Michael Mair-Keimberger  levelnine  at>
AuthorDate: Mon Mar  4 18:17:17 2024 +
Commit: Petr Vaněk  gentoo  org>
CommitDate: Tue Mar  5 09:17:01 2024 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6f49f061

app-misc/binwalk: remove unused patch(es)

Signed-off-by: Michael Mair-Keimberger  levelnine.at>
Signed-off-by: Petr Vaněk  gentoo.org>

 app-misc/binwalk/files/2.3.3-tests.patch   | 12 
 .../binwalk-2.2.0-disable-test-coverage.patch  | 14 -
 .../binwalk/files/binwalk-2.3.3-syntax-fix.patch   | 36 --
 3 files changed, 62 deletions(-)

diff --git a/app-misc/binwalk/files/2.3.3-tests.patch 
b/app-misc/binwalk/files/2.3.3-tests.patch
deleted file mode 100644
index dd4f876c..
--- a/app-misc/binwalk/files/2.3.3-tests.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-reverted:
 b/testing/tests/test_firmware_zip.py
-+++ a/testing/tests/test_firmware_zip.py
-@@ -10,6 +10,8 @@
- '''
- expected_results = [
-   [0, 'Zip archive data, at least v1.0 to extract, name: 
dir655_revB_FW_203NA/'],
-+  [51, 'Zip archive data, at least v2.0 to extract, compressed size: 
6395868, uncompressed size: 6422554, name: 
dir655_revB_FW_203NA/DIR655B1_FW203NAB02.bin'],
-+  [6395993, 'Zip archive data, at least v2.0 to extract, compressed size: 
14243, uncompressed size: 61440, name: 
dir655_revB_FW_203NA/dir655_revB_release_notes_203NA.doc'],
-   [6410581, 'End of Zip archive, footer length: 22'],
- 
- ]

diff --git a/app-misc/binwalk/files/binwalk-2.2.0-disable-test-coverage.patch 
b/app-misc/binwalk/files/binwalk-2.2.0-disable-test-coverage.patch
deleted file mode 100644
index 5dd322ba6036..
--- a/app-misc/binwalk/files/binwalk-2.2.0-disable-test-coverage.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Avoid having to pull in dev-python/coverage test dep since we don't care about
-coverage.
-
 binwalk-2.2.0/setup.py
-+++ binwalk-2.2.0/setup.py
-@@ -303,7 +303,7 @@
- os.chdir(testing_directory)
- 
- # Run the tests
--retval = nose.core.run(argv=['--exe','--with-coverage'])
-+retval = nose.core.run(argv=['--exe'])
- 
- sys.stdout.write("\n")
- 

diff --git a/app-misc/binwalk/files/binwalk-2.3.3-syntax-fix.patch 
b/app-misc/binwalk/files/binwalk-2.3.3-syntax-fix.patch
deleted file mode 100644
index 5edd530b2293..
--- a/app-misc/binwalk/files/binwalk-2.3.3-syntax-fix.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-https://github.com/ReFirmLabs/binwalk/pull/585
-
-From bce53d1bb57c2e6dccf718147ebe9472779b7903 Mon Sep 17 00:00:00 2001
-From: Cameron Katri 
-Date: Mon, 3 Jan 2022 15:20:39 -0500
-Subject: [PATCH] Fix SyntaxWarning message
-
-/usr/lib/python3/dist-packages/binwalk/modules/extractor.py:969: 
SyntaxWarning: "is" with a literal. Did you mean "=="?
-  if child_pid is 0:
-/usr/lib/python3/dist-packages/binwalk/modules/extractor.py:984: 
SyntaxWarning: "is" with a literal. Did you mean "=="?
-  if child_pid is 0:
 a/src/binwalk/modules/extractor.py
-+++ b/src/binwalk/modules/extractor.py
-@@ -966,7 +966,7 @@ def shell_call(self, command):
- 
- # Fork a child process
- child_pid = os.fork()
--if child_pid is 0:
-+if child_pid == 0:
- # Switch to the run-as user privileges, if one has been set
- if self.runas_uid is not None and self.runas_gid is not None:
- os.setgid(self.runas_uid)
-@@ -981,10 +981,10 @@ def shell_call(self, command):
- rval = subprocess.call(shlex.split(command), stdout=tmp, 
stderr=tmp)
- 
- # A true child process should exit with the subprocess exit value
--if child_pid is 0:
-+if child_pid == 0:
- sys.exit(rval)
- # If no os.fork() happened, just return the subprocess exit value
--elif child_pid is None:
-+elif child_pid == None:
- return rval
- # Else, os.fork() happened and we're the parent. Wait and return the 
child's exit value.
- else:
-



[gentoo-commits] repo/gentoo:master commit in: app-misc/binwalk/files/, app-misc/binwalk/

2019-11-18 Thread Tim Harder
commit: 217216968ea8944a215c6e7248fc90c5715fab9e
Author: Tim Harder  gentoo  org>
AuthorDate: Mon Nov 18 22:51:18 2019 +
Commit: Tim Harder  gentoo  org>
CommitDate: Mon Nov 18 22:54:38 2019 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=21721696

app-misc/binwalk: version bump to 2.2.0

Signed-off-by: Tim Harder  gentoo.org>

 app-misc/binwalk/Manifest |  1 +
 .../{binwalk-.ebuild => binwalk-2.2.0.ebuild} | 19 ---
 app-misc/binwalk/binwalk-.ebuild  | 19 ---
 .../files/binwalk-2.2.0-disable-test-coverage.patch   | 14 ++
 4 files changed, 39 insertions(+), 14 deletions(-)

diff --git a/app-misc/binwalk/Manifest b/app-misc/binwalk/Manifest
index 63cb9359ca2..4b66b45413d 100644
--- a/app-misc/binwalk/Manifest
+++ b/app-misc/binwalk/Manifest
@@ -1 +1,2 @@
 DIST binwalk-2.1.1.tar.gz 263977 BLAKE2B 
8fd5f20dcdb22a6528131fbebc1454cc496079bfeafa63ddb0679c7c7b5d5c29d81dccd4f52e8f6f7d8881d9e672d691c2b2ef367f2bf3180ffbb4ad22dca021
 SHA512 
373e276a4d6ec845952f1091f85f953d3b0d52d561d9b74a54000ebdef85d13cafc997a4f8f76f25842db8b76fdcd1e602d4d81792a3ea01c9dea6c6ed5c2168
+DIST binwalk-2.2.0.tar.gz 39594514 BLAKE2B 
899a919647258759f16c2e59766b0db68d1a78edf0f5c3755c2a987695199a1851deed2820e6323d82d8af85d294a6f1fcafb655e5d2257d49b673ddae49da67
 SHA512 
5f3ed31c0b5f9ca3057f86e82787a73b06f9f73747b51dd72130a78e4d69cf43a0207bffc495d177e97811de5bf835b3d0507f314b7a0c960eddf6d1efe0f0f9

diff --git a/app-misc/binwalk/binwalk-.ebuild 
b/app-misc/binwalk/binwalk-2.2.0.ebuild
similarity index 70%
copy from app-misc/binwalk/binwalk-.ebuild
copy to app-misc/binwalk/binwalk-2.2.0.ebuild
index 650ee2faadf..cd3986d6346 100644
--- a/app-misc/binwalk/binwalk-.ebuild
+++ b/app-misc/binwalk/binwalk-2.2.0.ebuild
@@ -1,8 +1,8 @@
 # Copyright 1999-2019 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=6
-PYTHON_COMPAT=( python{2_7,3_5,3_6} )
+EAPI=7
+PYTHON_COMPAT=( python{2_7,3_5,3_6,3_7,3_8} )
 
 inherit distutils-r1
 
@@ -19,12 +19,17 @@ HOMEPAGE="https://github.com/ReFirmLabs/binwalk;
 
 LICENSE="MIT"
 SLOT="0"
-IUSE="graph"
+IUSE="test"
+RESTRICT="!test? ( test )"
 
-RDEPEND="
-   $(python_gen_cond_dep 'dev-python/backports-lzma[${PYTHON_USEDEP}]' 
python2_7)
-   graph? ( dev-python/pyqtgraph[opengl,${PYTHON_USEDEP}] )
-"
+RDEPEND="$(python_gen_cond_dep 'dev-python/backports-lzma[${PYTHON_USEDEP}]' 
python2_7)"
+BDEPEND="test? ( dev-python/nose[${PYTHON_USEDEP}] )"
+
+PATCHES=( "${FILESDIR}"/${PN}-2.2.0-disable-test-coverage.patch )
+
+python_test() {
+   esetup.py test
+}
 
 python_install_all() {
local DOCS=( API.md INSTALL.md README.md )

diff --git a/app-misc/binwalk/binwalk-.ebuild 
b/app-misc/binwalk/binwalk-.ebuild
index 650ee2faadf..cd3986d6346 100644
--- a/app-misc/binwalk/binwalk-.ebuild
+++ b/app-misc/binwalk/binwalk-.ebuild
@@ -1,8 +1,8 @@
 # Copyright 1999-2019 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=6
-PYTHON_COMPAT=( python{2_7,3_5,3_6} )
+EAPI=7
+PYTHON_COMPAT=( python{2_7,3_5,3_6,3_7,3_8} )
 
 inherit distutils-r1
 
@@ -19,12 +19,17 @@ HOMEPAGE="https://github.com/ReFirmLabs/binwalk;
 
 LICENSE="MIT"
 SLOT="0"
-IUSE="graph"
+IUSE="test"
+RESTRICT="!test? ( test )"
 
-RDEPEND="
-   $(python_gen_cond_dep 'dev-python/backports-lzma[${PYTHON_USEDEP}]' 
python2_7)
-   graph? ( dev-python/pyqtgraph[opengl,${PYTHON_USEDEP}] )
-"
+RDEPEND="$(python_gen_cond_dep 'dev-python/backports-lzma[${PYTHON_USEDEP}]' 
python2_7)"
+BDEPEND="test? ( dev-python/nose[${PYTHON_USEDEP}] )"
+
+PATCHES=( "${FILESDIR}"/${PN}-2.2.0-disable-test-coverage.patch )
+
+python_test() {
+   esetup.py test
+}
 
 python_install_all() {
local DOCS=( API.md INSTALL.md README.md )

diff --git a/app-misc/binwalk/files/binwalk-2.2.0-disable-test-coverage.patch 
b/app-misc/binwalk/files/binwalk-2.2.0-disable-test-coverage.patch
new file mode 100644
index 000..5dd322ba603
--- /dev/null
+++ b/app-misc/binwalk/files/binwalk-2.2.0-disable-test-coverage.patch
@@ -0,0 +1,14 @@
+Avoid having to pull in dev-python/coverage test dep since we don't care about
+coverage.
+
+--- binwalk-2.2.0/setup.py
 binwalk-2.2.0/setup.py
+@@ -303,7 +303,7 @@
+ os.chdir(testing_directory)
+ 
+ # Run the tests
+-retval = nose.core.run(argv=['--exe','--with-coverage'])
++retval = nose.core.run(argv=['--exe'])
+ 
+ sys.stdout.write("\n")
+