[arch-commits] Commit in python-lxml/repos (staging-x86_64 staging-x86_64/PKGBUILD)

Felix Yan fyan at archlinux.org
Sat Sep 19 10:50:22 UTC 2015


    Date: Saturday, September 19, 2015 @ 12:50:22
  Author: fyan
Revision: 246603

archrelease: copy trunk to staging-x86_64

Added:
  python-lxml/repos/staging-x86_64/
  python-lxml/repos/staging-x86_64/PKGBUILD
    (from rev 246602, python-lxml/trunk/PKGBUILD)

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

Copied: python-lxml/repos/staging-x86_64/PKGBUILD (from rev 246602, python-lxml/trunk/PKGBUILD)
===================================================================
--- staging-x86_64/PKGBUILD	                        (rev 0)
+++ staging-x86_64/PKGBUILD	2015-09-19 10:50:22 UTC (rev 246603)
@@ -0,0 +1,90 @@
+# $Id$
+# Maintainer: Angel Velasquez <angvp at archlinux.org>
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgbase=python-lxml
+pkgname=('python-lxml' 'python2-lxml' 'python-lxml-docs')
+pkgver=3.4.4
+pkgrel=2
+arch=('i686' 'x86_64')
+license=('BSD' 'custom')
+url="http://lxml.de/"
+makedepends=('libxslt' 'python-cssselect' 'python2-cssselect')
+source=(http://pypi.python.org/packages/source/l/lxml/lxml-${pkgver}.tar.gz{,.asc})
+md5sums=('a9a65972afc173ec7a39c585f4eea69c'
+         'SKIP')
+validpgpkeys=('1737D5FB8DACC53CA96A77AB0D3D536908D3A01E')  # Stefan Behnel
+
+prepare() {
+  cp -a lxml-$pkgver{,-py2}
+}
+
+build() {
+  cd lxml-$pkgver
+  python setup.py build
+
+  cd ../lxml-$pkgver-py2
+  python2 setup.py build
+}
+
+check() {
+  # Setting LANG to workaround encoding issue
+  # TODO: Find a sane way to skip inplace build
+
+  cd lxml-$pkgver
+  LANG=en_US.UTF-8 make PYTHON=python test
+  # PYTHONPATH="$PWD/build/lib.linux-$CARCH-3.4:$PYTHONPATH" python test.py -p -v
+
+  cd ../lxml-$pkgver-py2
+  LANG=en_US.UTF-8 make PYTHON=python2 test
+  # PYTHONPATH="$PWD/build/lib.linux-$CARCH-2.7:$PYTHONPATH" python2 test.py -p -v
+}
+
+package_python2-lxml() {
+  pkgdesc="Python2 binding for the libxml2 and libxslt libraries"
+  depends=('python2' 'libxslt')
+  optdepends=('python2-beautifulsoup3: support for parsing not well formed HTML'
+              'python-lxml-docs: offline docs')
+
+  cd lxml-$pkgver-py2
+  python2 setup.py install --root="${pkgdir}" --skip-build --optimize=1
+ 
+  install -Dm644 LICENSES.txt \
+    "${pkgdir}"/usr/share/licenses/$pkgname/LICENSE
+  install -Dm644 doc/licenses/BSD.txt \
+    "${pkgdir}"/usr/share/licenses/$pkgname/BSD.txt
+  install -Dm644 doc/licenses/elementtree.txt \
+    "${pkgdir}"/usr/share/licenses/$pkgname/elementtree.txt
+}
+
+package_python-lxml() {
+  pkgdesc="Python3 binding for the libxml2 and libxslt libraries"
+  depends=('python' 'libxslt')
+  optdepends=('python-lxml-docs: offline docs')
+
+  cd lxml-$pkgver
+  python setup.py install --root="${pkgdir}" --skip-build --optimize=1
+  
+  install -Dm644 LICENSES.txt \
+    "${pkgdir}"/usr/share/licenses/$pkgname/LICENSE
+  install -Dm644 doc/licenses/BSD.txt \
+    "${pkgdir}"/usr/share/licenses/$pkgname/BSD.txt
+  install -Dm644 doc/licenses/elementtree.txt \
+    "${pkgdir}"/usr/share/licenses/$pkgname/elementtree.txt
+}
+
+package_python-lxml-docs() {
+  pkgdesc="Python binding for the libxml2 and libxslt libraries (docs)"
+  options=('docs')
+
+  cd lxml-$pkgver
+  install -d "${pkgdir}"/usr/share/doc/${pkgbase}
+  cp -r doc/html "${pkgdir}"/usr/share/doc/${pkgbase}
+
+  install -Dm644 LICENSES.txt \
+    "${pkgdir}"/usr/share/licenses/$pkgname/LICENSE
+  install -Dm644 doc/licenses/BSD.txt \
+    "${pkgdir}"/usr/share/licenses/$pkgname/BSD.txt
+  install -Dm644 doc/licenses/elementtree.txt \
+    "${pkgdir}"/usr/share/licenses/$pkgname/elementtree.txt
+}



More information about the arch-commits mailing list