Date: Wednesday, March 2, 2011 @ 13:53:47 Author: angvp Revision: 111973
upgpkg: sonata 1.6.2.1-3 Adding patch for cyrillic languages Added: sonata/trunk/sonata-cyr-input-fix.diff Modified: sonata/trunk/PKGBUILD ---------------------------+ PKGBUILD | 14 ++++++++------ sonata-cyr-input-fix.diff | 18 ++++++++++++++++++ 2 files changed, 26 insertions(+), 6 deletions(-) Modified: PKGBUILD =================================================================== --- PKGBUILD 2011-03-02 18:33:23 UTC (rev 111972) +++ PKGBUILD 2011-03-02 18:53:47 UTC (rev 111973) @@ -1,10 +1,10 @@ # $Id$ -# Maintainer: Alexander Fehr <pizzapunk gmail com> +# Maintainer: Angel Velasquez <[email protected]> # Contributor: William Rea <[email protected]> pkgname=sonata pkgver=1.6.2.1 -pkgrel=2 +pkgrel=3 pkgdesc="Elegant GTK+ music client for MPD" arch=('i686' 'x86_64') url="http://sonata.berlios.de/" @@ -14,11 +14,13 @@ 'tagpy: Metadata editing support' 'zsi: Lyrics fetching support' 'dbus-python: Various extra functionality (e.g. multimedia keys support)') -source=(http://download.berlios.de/${pkgname}/${pkgname}-$pkgver.tar.gz) -md5sums=('0b912325e7175abad3bf6c0edc071e05') +source=(http://download.berlios.de/${pkgname}/${pkgname}-$pkgver.tar.gz + sonata-cyr-input-fix.diff) +md5sums=('0b912325e7175abad3bf6c0edc071e05' + 'f98eba5dd7535307a89e141dc468c478') build() { cd "$srcdir/${pkgname}-$pkgver" - - python2 setup.py install --prefix=/usr --root="$pkgdir" || return 1 + patch -Np1 -i $srcdir/sonata-cyr-input-fix.diff # FS#23023 + python2 setup.py install --prefix=/usr --root="$pkgdir" } Added: sonata-cyr-input-fix.diff =================================================================== --- sonata-cyr-input-fix.diff (rev 0) +++ sonata-cyr-input-fix.diff 2011-03-02 18:53:47 UTC (rev 111973) @@ -0,0 +1,18 @@ +diff --git a/sonata/misc.py b/sonata/misc.py +index c5e2dcf..f3e7b82 100644 +--- a/sonata/misc.py ++++ b/sonata/misc.py +@@ -222,7 +222,12 @@ def setlocale(): + locale.setlocale(locale.LC_ALL, "") + # XXX this makes python-mpd correctly return lowercase + # keys for, e.g., playlistinfo() with a turkish locale: +- locale.setlocale(locale.LC_CTYPE, "C") ++ # (and breaks playlist search with russian), ++ # so, added check for turkish here. ++ turkish = ('tr_TR',) ++ locale, encoding = locale.getlocale() ++ if locale in turkish: ++ locale.setlocale(locale.LC_CTYPE, "C") + except: + print "Failed to set locale" + sys.exit(1)
