# Contributor: Francesco Colista # Maintainer: Francesco Colista setglobal pkgname = 'py-extras' setglobal _pkgname = 'extras' setglobal pkgver = '1.0.0' setglobal pkgrel = '0' setglobal pkgdesc = '"Useful extra bits for Python - things that shold be in the standard library'" setglobal url = '"https://pypi.python.org/pypi/extras/'" setglobal arch = '"noarch'" setglobal license = '"MIT'" setglobal depends = '"python'" setglobal makedepends = '"python2-dev python3-dev py-setuptools'" setglobal subpackages = ""py2-$(pkgname#py-):_py2 py3-$(pkgname#py-):_py3"" setglobal source = ""https://files.pythonhosted.org/packages/source/$(_pkgname:0:1)/$_pkgname/$_pkgname-$pkgver.tar.gz"" setglobal builddir = ""$srcdir"/$_pkgname-$pkgver" proc check { cd $builddir python2 setup.py check python3 setup.py check } proc build { cd $builddir python2 setup.py build python3 setup.py build } proc package { mkdir -p $pkgdir } proc _py2 { setglobal replaces = $pkgname setglobal depends = $(depends//py-/py2-) ## remove if there are no common Python dependencies _py python2 } proc _py3 { setglobal depends = $(depends//py-/py3-) ## remove if there are no common Python dependencies _py python3 } proc _py { local python="$1" setglobal pkgdesc = ""$pkgdesc (for $python)"" setglobal depends = ""$depends $python"" ## remove if arch isn't noarch setglobal install_if = ""$pkgname=$pkgver-r$pkgrel $python"" cd $builddir $python setup.py install --prefix=/usr --root="$subpkgdir" } setglobal sha512sums = '"510c796628f28db90bb96c7c9ba5fc9b2b950d2968e219efe67f3899bbe7ef68fe5de1494f8fd640f13a1ccd329e7dac9cd38aa965ab1e07c4cd287c04da50fb extras-1.0.0.tar.gz'"