Unverified Commit 4a94d992 authored by prspkt's avatar prspkt

community/py-prompt_toolkit: drop python2

parent 235baf4c
# Contributor: Thomas Boerger <thomas@webhippie.de>
# Maintainer: Thomas Boerger <thomas@webhippie.de>
pkgname=py-prompt_toolkit
pkgname=py3-prompt_toolkit
_pkgname=prompt_toolkit
pkgver=2.0.9
pkgrel=1
......@@ -8,47 +8,27 @@ pkgdesc="Library for building powerful interactive command lines in Python"
url="https://pypi.python.org/pypi/prompt_toolkit"
arch="noarch"
license="BSD"
depends="py-six py-wcwidth"
makedepends="python2-dev py-setuptools python3-dev"
subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3"
depends="py3-six py3-wcwidth"
makedepends="py3-setuptools"
source="$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz"
builddir="$srcdir/$_pkgname-$pkgver"
replaces=py-prompt_toolkit # Backwards compatibility
provides=py-prompt_toolkit=$pkgver-r$pkgrel # Backwards compatibility
build() {
cd "$builddir"
python2 setup.py build
python3 setup.py build
}
check() {
cd "$builddir"
python2 setup.py check
python3 setup.py check
}
package() {
mkdir -p "$pkgdir"
}
_py2() {
replaces="$pkgname"
depends="${depends//py-/py2-}"
_py python2
}
_py3() {
depends="${depends//py-/py3-}"
_py python3
}
_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"
python3 setup.py install --prefix=/usr --root="$pkgdir"
}
sha512sums="8fd0f8f2d05ba81dbdd02e2885652dc8d4e756d3cfc57646328c6ebc3e0e38242604cadc72c7f2479850800c8f0e9f555ffab33df3061800f9a99744d857afd3 py-prompt_toolkit-2.0.9.tar.gz"
sha512sums="8fd0f8f2d05ba81dbdd02e2885652dc8d4e756d3cfc57646328c6ebc3e0e38242604cadc72c7f2479850800c8f0e9f555ffab33df3061800f9a99744d857afd3 py3-prompt_toolkit-2.0.9.tar.gz"
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment