diff options
Diffstat (limited to 'community/goldendict')
-rw-r--r-- | community/goldendict/PKGBUILD | 18 | ||||
-rw-r--r-- | community/goldendict/fix-wikipedia-images.patch | 26 |
2 files changed, 38 insertions, 6 deletions
diff --git a/community/goldendict/PKGBUILD b/community/goldendict/PKGBUILD index cdf2a4650..d9b7bbd5b 100644 --- a/community/goldendict/PKGBUILD +++ b/community/goldendict/PKGBUILD @@ -1,30 +1,36 @@ -# $Id: PKGBUILD 85453 2013-03-01 19:08:27Z andrea $ +# $Id: PKGBUILD 96817 2013-09-05 20:34:32Z bgyorgy $ # Maintainer: Jaroslav Lichtblau <dragonlord@aur.archlinux.org> # Contributor: m0rph <m0rph.mailbox@gmail.com> pkgname=goldendict pkgver=1.0.1 -pkgrel=6 +pkgrel=7 pkgdesc="Feature-rich dictionary lookup program" arch=('i686' 'x86_64') url="http://goldendict.berlios.de/" license=('GPL3') depends=('hunspell' 'libvorbis' 'libxtst' 'libzip' 'qtwebkit' 'phonon') -makedepends=('patch') provides=('stardict') changelog=$pkgname.changelog source=(http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver-src.tar.bz2 $pkgname-paths.diff - gcc47.patch) + gcc47.patch + fix-wikipedia-images.patch) sha256sums=('b3fb0405a5edb38f02ef881b48c36e46e2eacf641b0caf8d99403f595a4be9a6' '1dacae7b7a7d7c20a22b4595c07dbd65fdad134a0d4cf283312ea3bdb5f42589' - '2e13857d047186e781c3bd9de3cfdf794f4d44e8e28f9d18dda8df50cfe13c6e') + '2e13857d047186e781c3bd9de3cfdf794f4d44e8e28f9d18dda8df50cfe13c6e' + 'ab669d96db0cb750d4c865b123474d655b6caca9242457c044a60f1fee5b7dc7') -build(){ +prepare(){ cd ${srcdir} patch -Np0 -i ${srcdir}/$pkgname-paths.diff patch -p1 -i ${srcdir}/gcc47.patch + patch -Np1 -i ${srcdir}/fix-wikipedia-images.patch +} + +build(){ + cd ${srcdir} qmake-qt4 make diff --git a/community/goldendict/fix-wikipedia-images.patch b/community/goldendict/fix-wikipedia-images.patch new file mode 100644 index 000000000..ea28bcd91 --- /dev/null +++ b/community/goldendict/fix-wikipedia-images.patch @@ -0,0 +1,26 @@ +From 8c056589e989781c6ed5aac7491c802414489ae9 Mon Sep 17 00:00:00 2001 +From: Abs62 <ottomann@yandex.ru> +Date: Sat, 22 Oct 2011 15:52:52 +0400 +Subject: [PATCH] Fix Wikipedia images loading + +--- + mediawiki.cc | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/mediawiki.cc b/mediawiki.cc +index e67fdb3..9fff3dc 100644 +--- a/mediawiki.cc ++++ b/mediawiki.cc +@@ -293,6 +293,9 @@ void MediaWikiArticleRequest::requestFinished( QNetworkReply * r ) + // Replace the href="/foo/bar/Baz" to just href="Baz". + articleString.replace( QRegExp( "<a\\shref=\"/([\\w\\.]*/)*" ), "<a href=\"" ); + ++ // Add "http:" to image source urls ++ articleString.replace( " src=\"//", " src=\"http://" ); ++ + // In those strings, change any underscores to spaces + for( ; ; ) + { +-- +1.8.4 + |