[arch-commits] Commit in (4 files)

Levente Polyak anthraxx at archlinux.org
Tue Feb 20 09:57:16 UTC 2018


    Date: Tuesday, February 20, 2018 @ 09:57:15
  Author: anthraxx
Revision: 296454

addpkg: python-stopit 1.1.2-1

Added:
  python-stopit/
  python-stopit/repos/
  python-stopit/trunk/
  python-stopit/trunk/PKGBUILD

----------+
 PKGBUILD |   53 +++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 53 insertions(+)

Added: python-stopit/trunk/PKGBUILD
===================================================================
--- python-stopit/trunk/PKGBUILD	                        (rev 0)
+++ python-stopit/trunk/PKGBUILD	2018-02-20 09:57:15 UTC (rev 296454)
@@ -0,0 +1,53 @@
+# Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
+
+pkgbase=python-stopit
+pkgname=('python-stopit' 'python2-stopit')
+_pyname=stopit
+pkgver=1.1.2
+pkgrel=1
+pkgdesc='Library to raise asynchronous exceptions in other thread, control the timeout of blocks or callables'
+url='https://github.com/glenfant/stopit'
+arch=('any')
+license=('GPL3')
+makedepends=('python' 'python-setuptools'
+             'python2' 'python2-setuptools')
+source=(${pkgbase}-${pkgver}.tar.gz::https://github.com/glenfant/${_pyname}/archive/${pkgver}.tar.gz)
+sha512sums=('4b1771a357f35a82128e92d7e91fa3e788271a3d6f1e08bacee69546c7c2fa857104394d8617259235c413b7f1706ccd4ff9ed480af5e1faef1149d1c1e0a0e0')
+
+prepare() {
+  cp -ra ${_pyname}-${pkgver}{,-py2}
+}
+
+build() {
+  (cd ${_pyname}-${pkgver}
+    python setup.py build
+  )
+  (cd ${_pyname}-${pkgver}-py2
+    python2 setup.py build
+  )
+}
+
+check() {
+  (cd ${_pyname}-${pkgver}
+    python setup.py test
+  )
+  (cd ${_pyname}-${pkgver}-py2
+    python2 setup.py test
+  )
+}
+
+package_python-stopit() {
+  depends=('python')
+  cd ${_pyname}-${pkgver}
+  python setup.py install -O1 --root="${pkgdir}" --prefix=/usr --skip-build
+  install -Dm 644 README.rst -t "${pkgdir}/usr/share/doc/${pkgname}"
+}
+
+package_python2-stopit() {
+  depends=('python2')
+  cd ${_pyname}-${pkgver}-py2
+  python2 setup.py install -O1 --root="${pkgdir}" --prefix=/usr --skip-build
+  install -Dm 644 README.rst -t "${pkgdir}/usr/share/doc/${pkgname}"
+}
+
+# vim: ts=2 sw=2 et:



More information about the arch-commits mailing list