deluge: add patch to fix gettext warning

Close: #23423
This commit is contained in:
Paper 2020-07-06 19:20:06 +02:00 committed by Đoàn Trần Công Danh
parent 350dc76503
commit a698f734ad
2 changed files with 29 additions and 5 deletions

View file

@ -0,0 +1,25 @@
From d6c96d629183e8bab2167ef56457f994017e7c85 Mon Sep 17 00:00:00 2001
From: neeshy <neeshy@tfwno.gf>
Date: Sat, 18 Apr 2020 23:23:51 -0400
Subject: Fix warning related to gettext
---
deluge/i18n/util.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/deluge/i18n/util.py b/deluge/i18n/util.py
index bd002f7a2..90568fc5b 100644
--- a/deluge/i18n/util.py
+++ b/deluge/i18n/util.py
@@ -114,7 +114,7 @@ def setup_translation():
# Workaround for Python 2 unicode gettext (keyword removed in Py3).
kwargs = {} if not deluge.common.PY2 else {'unicode': True}
- gettext.install(I18N_DOMAIN, translations_path, names='ngettext', **kwargs)
+ gettext.install(I18N_DOMAIN, translations_path, names=['ngettext'], **kwargs)
builtins.__dict__['_n'] = builtins.__dict__['ngettext']
libintl = None
--
2.27.0

View file

@ -1,11 +1,11 @@
# Template file for 'deluge'
pkgname=deluge
version=2.0.3
revision=5
revision=6
archs=noarch
build_style=python3-module
pycompile_module="deluge"
hostmakedepends="intltool python3-setuptools"
# TODO package python3-slimit to minify javascript
hostmakedepends="intltool python3-setuptools python3-wheel"
depends="python3-setuptools python3-chardet python3-Twisted python3-Mako
python3-xdg python3-rencode python3-setproctitle libtorrent-rasterbar-python3
python3-Pillow"
@ -15,6 +15,7 @@ license="GPL-3.0-or-later"
homepage="https://deluge-torrent.org/"
distfiles="https://ftp.osuosl.org/pub/deluge/source/2.0/deluge-${version}.tar.xz"
checksum=7e7ae8e6ca2a2bf0d487227cecf81e27332f0b92b567cc2bda38e47d859da891
patch_args="-Np1"
system_accounts="deluge"
deluge_homedir="/var/lib/deluge"
@ -29,7 +30,6 @@ deluge-gtk_package() {
archs=noarch
replaces="deluge<1.3.14_1"
short_desc+=" - GTK+ frontend"
pycompile_module="deluge"
depends="${sourcepkg}-${version}_${revision} python3-gobject"
pkg_install() {
vmove usr/bin/deluge
@ -45,7 +45,6 @@ deluge-web_package() {
archs=noarch
replaces="deluge<1.3.14_1"
short_desc+=" - Web frontend"
pycompile_module="deluge"
depends="${sourcepkg}-${version}_${revision}"
pkg_install() {
vmove usr/bin/deluge-web