[arch-commits] Commit in python-feedparser/trunk (3 files)

Allan McRae allan at archlinux.org
Sat Sep 27 01:41:26 UTC 2008


    Date: Friday, September 26, 2008 @ 21:41:25
  Author: allan
Revision: 13365

upgpkg: python-feedparser 4.1-3

Added:
  python-feedparser/trunk/ChangeLog
  python-feedparser/trunk/feedparser_utf8_decoding.patch
Modified:
  python-feedparser/trunk/PKGBUILD

--------------------------------+
 ChangeLog                      |    3 +++
 PKGBUILD                       |   12 +++++++-----
 feedparser_utf8_decoding.patch |   11 +++++++++++
 3 files changed, 21 insertions(+), 5 deletions(-)

Added: ChangeLog
===================================================================
--- ChangeLog	                        (rev 0)
+++ ChangeLog	2008-09-27 01:41:25 UTC (rev 13365)
@@ -0,0 +1,3 @@
+2008-09-27  Allan McRae <allan at archlinux.org>
+	* python-feedparser 4.1-3
+	* Add patch for UTF8 support
\ No newline at end of file

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2008-09-27 01:39:09 UTC (rev 13364)
+++ PKGBUILD	2008-09-27 01:41:25 UTC (rev 13365)
@@ -3,19 +3,21 @@
 # Contributor: Simo Leone <neotuli at gmail.com>
 
 pkgname=python-feedparser
-_pkgnameorig=feedparser
 pkgver=4.1
-pkgrel=2
+pkgrel=3
 pkgdesc="Parse RSS and Atom feeds in Python"
 arch=('i686' 'x86_64')
 url="http://feedparser.sf.net"
 license=('custom')
 depends=('python' 'libxml2' )
-source=(http://downloads.sourceforge.net/feedparser/${_pkgnameorig}-${pkgver}.zip)
-md5sums=('7ab1140c1e29d4cd52ab20fa7b1f8640')
+source=(http://downloads.sourceforge.net/feedparser/feedparser-${pkgver}.zip
+        feedparser_utf8_decoding.patch)
+md5sums=('7ab1140c1e29d4cd52ab20fa7b1f8640'
+         '1412caa1577260945df5ef0f5efabc62')
 
 build() {
-  cd ${srcdir}/${_pkgnameorig}
+  cd ${srcdir}
+  patch -Np0 -i feedparser_utf8_decoding.patch
   python setup.py build
   python setup.py install --root=${pkgdir}
   install -Dm644 LICENSE ${pkgdir}/usr/share/licenses/${pkgname}/license

Added: feedparser_utf8_decoding.patch
===================================================================
--- feedparser_utf8_decoding.patch	                        (rev 0)
+++ feedparser_utf8_decoding.patch	2008-09-27 01:41:25 UTC (rev 13365)
@@ -0,0 +1,11 @@
+--- /var/lib/python-support/python2.5/feedparser.py	2008-01-23 20:10:27.000000000 +0100
++++ feedparser.py	2008-07-28 11:01:38.000000000 +0200
+@@ -1455,7 +1455,7 @@
+         # thanks to Kevin Marks for this breathtaking hack to deal with (valid) high-bit attribute values in UTF-8 feeds
+         for key, value in attrs:
+             if type(value) != type(u''):
+-                value = unicode(value, self.encoding)
++                value = unicode(value, self.encoding, errors='replace')
+             uattrs.append((unicode(key, self.encoding), value))
+         strattrs = u''.join([u' %s="%s"' % (key, value) for key, value in uattrs]).encode(self.encoding)
+         if tag in self.elements_no_end_tag:




More information about the arch-commits mailing list