From cd79d5486d6394859ce5e104d3963dcff1dc49d2 Mon Sep 17 00:00:00 2001 From: Leo Date: Sat, 7 Sep 2019 12:25:25 -0300 Subject: testing/py3-nmap: drop py2 --- testing/py3-nmap/APKBUILD | 46 ++++++++++++++++------------------------------ 1 file changed, 16 insertions(+), 30 deletions(-) (limited to 'testing/py3-nmap') diff --git a/testing/py3-nmap/APKBUILD b/testing/py3-nmap/APKBUILD index 7fb634fec2..60a7aa9447 100644 --- a/testing/py3-nmap/APKBUILD +++ b/testing/py3-nmap/APKBUILD @@ -1,47 +1,33 @@ # Contributor: Fabian Affolter # Maintainer: Fabian Affolter -pkgname=py-nmap +pkgname=py3-nmap _pkgname=nmap pkgver=0.6.1 -pkgrel=2 -pkgdesc="A Python class to use nmap and access scan results" -url="http://xael.org/norman/python/python-nmap/" +pkgrel=3 +pkgdesc="Python3 class to use nmap and access scan results" +options="!check" # Some tests fail due to missing file +url="http://xael.org/pages/python-nmap-en.html" arch="noarch" license="GPL-3.0-or-later" -makedepends="python2-dev py-setuptools python3-dev" -subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3" +depends="nmap" +makedepends="py3-setuptools" +checkdepends="py3-nose" source="http://xael.org/pages/python-$_pkgname-$pkgver.tar.gz" builddir="$srcdir"/python-$_pkgname-$pkgver -build() { - cd "$builddir" - python2 setup.py build || return 1 - python3 setup.py build || return 1 -} - -package() { - mkdir -p "$pkgdir" -} +replaces="py-nmap" # Backwards compatibility +provides="py-nmap=$pkgver-r$pkgrel" # Backwards compatibility -_py2() { - replaces="$pkgname" - _py python2 +build() { + python3 setup.py build } -_py3() { - _py python3 +check() { + nosetests } -_py() { - local python="$1" - pkgdesc="$pkgdesc (for $python)" - depends="$depends $python" - install_if="$pkgname=$pkgver-r$pkgrel $python" - - cd "$builddir" - $python setup.py install --prefix=/usr --root="$subpkgdir" +package() { + python3 setup.py install --prefix=/usr --root="$pkgdir" } -md5sums="2795bfcbc05cbbbccfcf4df59facaab1 python-nmap-0.6.1.tar.gz" -sha256sums="80ba0eb10a52283a54a633f40b5baa9c2ff08675d6621dd089ead942852f5bd3 python-nmap-0.6.1.tar.gz" sha512sums="8de9ba6d0a4cecce09e82765b8a9ac77fb4368298d5a5f9ce07b7737a90def795f1ad00885fc73ec720bea2a592230e86aaca8cacd884c9299f64ad934bcee18 python-nmap-0.6.1.tar.gz" -- cgit v1.2.3