[arch-commits] Commit in python-feedparser/repos (staging-any staging-any/PKGBUILD)
Felix Yan
fyan at archlinux.org
Sat Sep 19 16:53:03 UTC 2015
Date: Saturday, September 19, 2015 @ 18:53:03
Author: fyan
Revision: 246664
archrelease: copy trunk to staging-any
Added:
python-feedparser/repos/staging-any/
python-feedparser/repos/staging-any/PKGBUILD
(from rev 246663, python-feedparser/trunk/PKGBUILD)
----------+
PKGBUILD | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 57 insertions(+)
Copied: python-feedparser/repos/staging-any/PKGBUILD (from rev 246663, python-feedparser/trunk/PKGBUILD)
===================================================================
--- staging-any/PKGBUILD (rev 0)
+++ staging-any/PKGBUILD 2015-09-19 16:53:03 UTC (rev 246664)
@@ -0,0 +1,57 @@
+# $Id$
+# Maintainer: Eric Bélanger <eric at archlinux.org>
+
+pkgbase=python-feedparser
+pkgname=('python2-feedparser' 'python-feedparser' 'python-sgmllib')
+pkgver=5.2.0
+pkgrel=2
+pkgdesc="Parse RSS and Atom feeds in Python"
+arch=('any')
+url="https://github.com/kurtmckee/feedparser/"
+license=('custom')
+makedepends=('python' 'python2' 'libxml2' 'python2-setuptools' 'python-setuptools')
+source=(feedparser-${pkgver}.tar.gz::https://github.com/kurtmckee/feedparser/archive/${pkgver}.tar.gz)
+sha1sums=('9c58e1d2b8ee0dfc1e0bf9c82f0c2a7eba758eec')
+
+prepare() {
+ cp -r feedparser-${pkgver} feedparser-${pkgver}-python2
+ cp -r feedparser-${pkgver} feedparser-${pkgver}-python
+ cp -r feedparser-${pkgver} feedparser-${pkgver}-sgmllib
+
+ (cd feedparser-${pkgver}-python2; sed -i 's#env python$#env python2#' feedparser/feedparsertest.py)
+ (cd feedparser-${pkgver}-python; 2to3 -w feedparser/feedparser.py feedparser/feedparsertest.py)
+}
+
+build() {
+ cd feedparser-${pkgver}-sgmllib
+ python /usr/lib/python3.5/compileall.py feedparser/sgmllib3.py
+}
+
+package_python2-feedparser() {
+ depends=('python2' 'libxml2' )
+ pkgdesc="Parse RSS and Atom feeds in Python2"
+
+ cd "${srcdir}/feedparser-${pkgver}-python2"
+ python2 setup.py install --root="${pkgdir}"
+ install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/license"
+}
+
+package_python-feedparser() {
+ depends=('libxml2' 'python-sgmllib')
+
+ cd "${srcdir}/feedparser-${pkgver}-python"
+ python setup.py install --root="${pkgdir}"
+ install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/license"
+}
+
+package_python-sgmllib() {
+ depends=('python')
+ pkgdesc="Port of sgmllib to Python3"
+ license=('PSF')
+
+ cd "${srcdir}/feedparser-${pkgver}-sgmllib"
+ install -Dm644 feedparser/sgmllib3.py \
+ "${pkgdir}/usr/lib/python3.5/site-packages/sgmllib.py"
+ install -Dm644 feedparser/__pycache__/sgmllib3.cpython-35.pyc \
+ "${pkgdir}/usr/lib/python3.5/site-packages/__pycache__/sgmllib.cpython-35.pyc"
+}
More information about the arch-commits
mailing list