app-misc/binwalk: version bump to 2.2.0
authorTim Harder <radhermit@gentoo.org>
Mon, 18 Nov 2019 22:51:18 +0000 (15:51 -0700)
committerTim Harder <radhermit@gentoo.org>
Mon, 18 Nov 2019 22:54:38 +0000 (15:54 -0700)
Signed-off-by: Tim Harder <radhermit@gentoo.org>
app-misc/binwalk/Manifest
app-misc/binwalk/binwalk-2.2.0.ebuild [new file with mode: 0644]
app-misc/binwalk/binwalk-9999.ebuild
app-misc/binwalk/files/binwalk-2.2.0-disable-test-coverage.patch [new file with mode: 0644]

index 63cb9359ca2ef643c9879bab2636d3722fbe9b6f..4b66b45413d1ed93eae0fc4de0372c965602890c 100644 (file)
@@ -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-2.2.0.ebuild b/app-misc/binwalk/binwalk-2.2.0.ebuild
new file mode 100644 (file)
index 0000000..cd3986d
--- /dev/null
@@ -0,0 +1,44 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+PYTHON_COMPAT=( python{2_7,3_5,3_6,3_7,3_8} )
+
+inherit distutils-r1
+
+if [[ ${PV} == "9999" ]] ; then
+       EGIT_REPO_URI="https://github.com/ReFirmLabs/binwalk.git"
+       inherit git-r3
+else
+       SRC_URI="https://github.com/ReFirmLabs/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+       KEYWORDS="~amd64 ~x86 ~x64-macos"
+fi
+
+DESCRIPTION="A tool for identifying files embedded inside firmware images"
+HOMEPAGE="https://github.com/ReFirmLabs/binwalk"
+
+LICENSE="MIT"
+SLOT="0"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+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 )
+       distutils-r1_python_install_all
+}
+
+pkg_postinst() {
+       if [[ -z ${REPLACING_VERSIONS} ]]; then
+               elog "binwalk has many optional dependencies to automatically"
+               elog "extract/decompress data, see INSTALL.md for more details."
+       fi
+}
index 650ee2faadf944165709326af02ba980566d1744..cd3986d63469bbd5245812f00298e85e98b4a58d 100644 (file)
@@ -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 (file)
index 0000000..5dd322b
--- /dev/null
@@ -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")