omni cfc162889d testing/binwalk: upgrade to 2.4.1 & switch to gpep517
- enable tests
- update url to that of the source repo
2024-05-01 09:31:33 +00:00

37 lines
1.0 KiB
Plaintext

# Contributor: Francesco Colista <fcolista@alpinelinux.org>
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=binwalk
pkgver=2.4.1
pkgrel=0
pkgdesc="Fast, easy to use tool for analyzing and extracting firmware images"
url="https://github.com/OSPG/binwalk/"
arch="noarch"
license="MIT"
depends="py3-pycryptodome python3"
makedepends="py3-gpep517 py3-setuptools py3-wheel"
checkdepends="py3-pytest"
subpackages="$pkgname-pyc"
source="$pkgname-$pkgver.tar.gz::https://github.com/OSPG/binwalk/archive/refs/tags/v$pkgver.tar.gz"
# secfixes:
# 2.3.4-r0:
# - CVE-2022-4510
build() {
gpep517 build-wheel --wheel-dir .dist --output-fd 3 3>&1 >&2
}
check() {
python3 -m venv --clear --without-pip --system-site-packages .testenv
.testenv/bin/python3 -m installer .dist/*.whl
.testenv/bin/python3 -m pytest
}
package() {
python3 -m installer -d "$pkgdir" .dist/*.whl
}
sha512sums="
f83d0ca09a39033944ce16345b7c2c8f3051a20f80315e4c797221df4e6844c7c89c0a49053d739156e2654b482d6ef93f0814fa588daab031dbeaed1423e6f2 binwalk-2.4.1.tar.gz
"