paraports

parazyd's aports
git clone https://git.parazyd.org/paraports
Log | Files | Refs | README | LICENSE

APKBUILD (1140B)


      1 # Maintainer: Ivan J. <parazyd@dyne.org>
      2 pkgname=py-pysrt
      3 _pkgname=pysrt
      4 pkgver=1.1.1
      5 pkgrel=0
      6 pkgdesc="Python library used to edit or create SubRip files"
      7 url="https://github.com/byroot/pysrt"
      8 arch="noarch"
      9 license="GPL-3"
     10 _py2_deps="py2-chardet"
     11 _py3_deps="py3-chardet"
     12 makedepends="$_py2_deps $_py3_deps python2-dev python3-dev py-setuptools"
     13 subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3"
     14 source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz"
     15 builddir="$srcdir/$_pkgname-$pkgver"
     16 
     17 build() {
     18 	cd "$builddir"
     19 
     20 	python2 setup.py build || return 1
     21 	python3 setup.py build || return 1
     22 }
     23 
     24 package() {
     25 	mkdir -p "$pkgdir"
     26 }
     27 
     28 _py2() {
     29 	replaces="$pkgname"
     30 	_py python2
     31 }
     32 
     33 _py3() {
     34 	_py python3
     35 }
     36 
     37 _py() {
     38 	local python="$1"
     39 	pkgdesc="$pkgdesc (for $python)"
     40 	depends="$depends $python"
     41 	install_if="$pkgname=$pkgver-r$pkgrel $python"
     42 
     43 	cd "$builddir"
     44 	$python setup.py install --prefix=/usr --root="$subpkgdir"
     45 }
     46 
     47 sha512sums="607f80c1f66702d36b6fa54b293f59c6a28415d812bf54d7210075d1c84a7547ce2776c0809910ed3d79c08a3c595ce74719976d8f2818820a3f4a306ffc1825  pysrt-1.1.1.tar.gz"