[arch-commits] Commit in (4 files)

Bruno Pagani archange at archlinux.org
Fri Feb 21 01:22:44 UTC 2020


    Date: Friday, February 21, 2020 @ 01:22:43
  Author: archange
Revision: 577474

Initial addition of python-pyscreenshot to [community]

checkdepends of python-pyvirtualdisplay

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

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

Added: python-pyscreenshot/trunk/PKGBUILD
===================================================================
--- python-pyscreenshot/trunk/PKGBUILD	                        (rev 0)
+++ python-pyscreenshot/trunk/PKGBUILD	2020-02-21 01:22:43 UTC (rev 577474)
@@ -0,0 +1,42 @@
+# Maintainer: Bruno Pagani <archange at archlinux.org>
+
+_pkg=pyscreenshot
+pkgname=python-${_pkg}
+pkgver=1.0
+pkgrel=1
+pkgdesc="Copy the contents of the screen to a PIL or Pillow image memory"
+arch=(any)
+url="https://github.com/ponty/pyscreenshot"
+license=(BSD)
+depends=(python-easyprocess python-entrypoint2)
+makedepends=(python-setuptools)
+checkdepends=(
+    python-nose python-pyvirtualdisplay python-pillow python-pygame
+    python-path.py python-xlib
+    python-gobject python-pyqt5 python-qtpy pyside2
+    xorg-server-xvfb xorg-xdpyinfo gnome-screenshot scrot imagemagick
+)
+#PyPi tarball does not have tests
+#source=(https://files.pythonhosted.org/packages/source/${_pkg::1}/${_pkg}/${_pkg}-${pkgver}.tar.gz)
+source=(${url}/archive/${pkgver}/${pkgname}-${pkgver}.tar.gz)
+sha256sums=('b1ccae937486cb304d5b3039e2b48d728df7ba67642b1a522b598e622936cfad')
+
+build() {
+  cd ${_pkg}-${pkgver}
+  python setup.py build
+}
+
+check() {
+  cd ${_pkg}-${pkgver}/tests/
+  export PYTHONPATH="../build/lib/" 
+  python -m pyscreenshot.check.versions
+  python -m pyscreenshot.check.speedtest --virtual-display
+  xvfb-run -s "-br -screen 0 400x500x24" \
+    nosetests -vv test_scrot.py test_imagemagick.py test_def.py test_pygdk3.py test_pyqt5.py test_qtpy.py test_pyside2.py easy
+}
+
+package() {
+  cd ${_pkg}-${pkgver}
+  python setup.py install --prefix=/usr --root="${pkgdir}" --skip-build --optimize=1
+  install -Dm644 LICENSE.txt -t "${pkgdir}"/usr/share/licenses/${pkgname}
+}



More information about the arch-commits mailing list