summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTiziano Müller <dev-zero@gentoo.org>2012-06-19 06:10:22 +0000
committerTiziano Müller <dev-zero@gentoo.org>2012-06-19 06:10:22 +0000
commitf19a7b15804f5d1109626996e8ca4ffca73d4a28 (patch)
tree2b3ebaf8c4f2295bc9872def062cfcbc2f9fc5fa /net-wireless/blueman
parentmarked x86 per bug 414733 (diff)
downloadhistorical-f19a7b15804f5d1109626996e8ca4ffca73d4a28.tar.gz
historical-f19a7b15804f5d1109626996e8ca4ffca73d4a28.tar.bz2
historical-f19a7b15804f5d1109626996e8ca4ffca73d4a28.zip
Fix segfault with non-UTF-8 locale (bug #414871).
Package-Manager: portage-2.1.10.65/cvs/Linux x86_64
Diffstat (limited to 'net-wireless/blueman')
-rw-r--r--net-wireless/blueman/ChangeLog8
-rw-r--r--net-wireless/blueman/Manifest10
-rw-r--r--net-wireless/blueman/blueman-1.23-r1.ebuild97
-rw-r--r--net-wireless/blueman/files/blueman-1.23-set-codeset-for-gettext-to-UTF-8-always.patch266
4 files changed, 376 insertions, 5 deletions
diff --git a/net-wireless/blueman/ChangeLog b/net-wireless/blueman/ChangeLog
index 0bb7bae6e0d0..aef1ae0e7b31 100644
--- a/net-wireless/blueman/ChangeLog
+++ b/net-wireless/blueman/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for net-wireless/blueman
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-wireless/blueman/ChangeLog,v 1.13 2012/06/13 08:31:27 dev-zero Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-wireless/blueman/ChangeLog,v 1.14 2012/06/19 06:10:22 dev-zero Exp $
+
+*blueman-1.23-r1 (19 Jun 2012)
+
+ 19 Jun 2012; Tiziano Müller <dev-zero@gentoo.org> +blueman-1.23-r1.ebuild,
+ +files/blueman-1.23-set-codeset-for-gettext-to-UTF-8-always.patch:
+ Fix segfault with non-UTF-8 locale (bug #414871).
*blueman-1.23 (13 Jun 2012)
diff --git a/net-wireless/blueman/Manifest b/net-wireless/blueman/Manifest
index 3795dc7b13b1..530aea0d7380 100644
--- a/net-wireless/blueman/Manifest
+++ b/net-wireless/blueman/Manifest
@@ -3,16 +3,18 @@ Hash: SHA1
AUX blueman-1.23-fix-broken-status-icon.patch 1174 RMD160 d17b01c21587cd5f9c83dbee7e24f49fe49d450e SHA1 1e343aa5cf0a6f01434660a0f3053b7092ebcebf SHA256 b6fe3d426d90e2d212a005aaa7bae2f800bb69df407aa90058f7b1029ba7c296
AUX blueman-1.23-plugins-conf-file.patch 988 RMD160 cc08d1ef91eaf9e2a60c41ba23e28e62d248a51d SHA1 f8879e8c74d52e629d6de91d7969b9a7be4e56da SHA256 58132546cf913af396d189503e7e3aee53d6e626486343757169b6f0ec34d913
+AUX blueman-1.23-set-codeset-for-gettext-to-UTF-8-always.patch 9343 RMD160 9a31aca526d34fba7aae140edc61bd46f1470bbe SHA1 76b59e6ed1ac062ee319987521569d80eadfa356 SHA256 6d2cd72f41fc054f023dfeb894bb4049441fc01e6e0f936120603021c305bbcc
DIST blueman-1.21.tar.gz 1086099 RMD160 d13479615d11a4848d5629ca541b2f8f995befec SHA1 ec513e1a1c7bc99dd695baf7b934e38e7ea86cd6 SHA256 86200dab50b1595c9a9537586c07de90ccfa084b954bb74f3e8732cc000fe3af
DIST blueman-1.23.tar.gz 1223094 RMD160 8e6d181e9f41b5b0bb99b3299a0d81f6c765e988 SHA1 3a6bb994e399c56d297abc84aae2ddcdfd459858 SHA256 50b261bcdc2e99e176c7c194825da1259500aaacaccb92714d97af0209a4f011
EBUILD blueman-1.21-r1.ebuild 2096 RMD160 1e159023c86005c6965d8ad803d6aef535d8c292 SHA1 bae51e7527505ea0abff55dd27f377e9bd88bbbd SHA256 102d7467189e55e8878b7d4f01d7d79a3971122d27b3afc9db309aa51fd3cfaa
+EBUILD blueman-1.23-r1.ebuild 2371 RMD160 3bd6a6fbe5cc25f9323bbcc46478b1c7e24f5bc1 SHA1 b1cc1850dc6fa8750e9fdd0cd925ce8894e7069e SHA256 46f2b35a650a44dba1327312dcc0e8f9c8b1954b72e83684423c2768f1e55f77
EBUILD blueman-1.23.ebuild 2299 RMD160 447fa3bba1c839cc4e3563d933f658bdfb748878 SHA1 c5bad9f5e8f0fcffc7f34815727b0c252508b570 SHA256 0c657a9c249d8dde3f4ff4c36678607e5e12580cd5007a3aba343ab77e0b60cc
-MISC ChangeLog 2812 RMD160 be1fa80e8d2b14cef6d62446e2db11485827b935 SHA1 3617925315cd13be1eda524c55f96adf043e46bb SHA256 a7d0cdecace3aae3bf63a1f6215d5991c38897251bd120d349a07f0b80992c44
+MISC ChangeLog 3044 RMD160 1519294fe432e3d5395a64174b6bfb12a28dff2f SHA1 94868c79c73de6ddc35a77ed50d943465a359dfd SHA256 5c7fd217a6cab807f91dc418ede5b5b5ca23b46fe99bc218da8add21dd2fae93
MISC metadata.xml 546 RMD160 a34c912242b54be23d9386e3fa532388c8b2c7dd SHA1 c018ca31d0ae013d41b39b5f1b68c5a10fcf3913 SHA256 4008067dce9d94b43ef71f0f39b1d41113ac96a30305fd6b9bfb6970cee99029
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.19 (GNU/Linux)
-iEYEARECAAYFAk/YT+kACgkQGwVqY66cHjBQVwCfeZrSVbEyfBPeCZu+38s71H67
-OpQAnjGcR+nKNQWIq2J0igHkjdTM5tcv
-=d+eS
+iEYEARECAAYFAk/gF9cACgkQGwVqY66cHjAIqgCfRDI5KMkFgwzh283XVKMcorbm
+epoAnieKGpnuyLyrvI12bkIRiUBETVHR
+=mOif
-----END PGP SIGNATURE-----
diff --git a/net-wireless/blueman/blueman-1.23-r1.ebuild b/net-wireless/blueman/blueman-1.23-r1.ebuild
new file mode 100644
index 000000000000..2a869272a475
--- /dev/null
+++ b/net-wireless/blueman/blueman-1.23-r1.ebuild
@@ -0,0 +1,97 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-wireless/blueman/blueman-1.23-r1.ebuild,v 1.1 2012/06/19 06:10:22 dev-zero Exp $
+
+EAPI="4"
+
+PYTHON_DEPEND="2"
+
+inherit eutils python gnome2-utils
+
+DESCRIPTION="GTK+ Bluetooth Manager, designed to be simple and intuitive for everyday bluetooth tasks."
+HOMEPAGE="http://blueman-project.org/"
+SRC_URI="http://download.tuxfamily.org/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86"
+IUSE="gconf sendto network nls policykit pulseaudio"
+
+CDEPEND="dev-libs/glib:2
+ >=x11-libs/gtk+-2.12:2
+ x11-libs/startup-notification
+ dev-python/pygobject:2
+ >=net-wireless/bluez-4.21"
+DEPEND="${CDEPEND}
+ nls? ( dev-util/intltool sys-devel/gettext )
+ virtual/pkgconfig
+ >=dev-python/pyrex-0.9.8"
+RDEPEND="${CDEPEND}
+ >=app-mobilephone/obex-data-server-0.4.4
+ sys-apps/dbus
+ dev-python/pygtk
+ dev-python/notify-python
+ dev-python/dbus-python
+ x11-themes/hicolor-icon-theme
+ gconf? ( dev-python/gconf-python )
+ sendto? ( gnome-base/nautilus )
+ network? ( || ( net-dns/dnsmasq
+ =net-misc/dhcp-3*
+ >=net-misc/networkmanager-0.8 ) )
+ policykit? ( sys-auth/polkit )
+ pulseaudio? ( media-sound/pulseaudio )"
+
+pkg_setup() {
+ python_set_active_version 2
+ python_pkg_setup
+}
+
+src_prepare() {
+ # disable pyc compiling
+ ln -sf $(type -P true) py-compile
+
+ sed -i \
+ -e '/^Encoding/d' \
+ data/blueman-manager.desktop.in || die "sed failed"
+
+ epatch \
+ "${FILESDIR}/${P}-plugins-conf-file.patch" \
+ "${FILESDIR}/${P}-fix-broken-status-icon.patch" \
+ "${FILESDIR}/${P}-set-codeset-for-gettext-to-UTF-8-always.patch"
+}
+
+src_configure() {
+ econf \
+ --disable-static \
+ $(use_enable policykit polkit) \
+ $(use_enable sendto) \
+ --disable-hal \
+ $(use_enable nls)
+}
+
+src_install() {
+ default
+
+ rm "${D}"/$(python_get_sitedir)/*.la
+ use sendto && rm "${D}"/usr/lib*/nautilus-sendto/plugins/*.la
+
+ use gconf || rm "${D}"/$(python_get_sitedir)/${PN}/plugins/config/Gconf.py
+ use policykit || rm -rf "${D}"/usr/share/polkit-1
+ use pulseaudio || rm "${D}"/$(python_get_sitedir)/${PN}/{main/Pulse*.py,plugins/applet/Pulse*.py}
+
+ python_need_rebuild
+}
+
+pkg_preinst() {
+ gnome2_icon_savelist
+}
+
+pkg_postinst() {
+ python_mod_optimize ${PN}
+ gnome2_icon_cache_update
+}
+
+pkg_postrm() {
+ python_mod_cleanup ${PN}
+ gnome2_icon_cache_update
+}
diff --git a/net-wireless/blueman/files/blueman-1.23-set-codeset-for-gettext-to-UTF-8-always.patch b/net-wireless/blueman/files/blueman-1.23-set-codeset-for-gettext-to-UTF-8-always.patch
new file mode 100644
index 000000000000..a7df10db506e
--- /dev/null
+++ b/net-wireless/blueman/files/blueman-1.23-set-codeset-for-gettext-to-UTF-8-always.patch
@@ -0,0 +1,266 @@
+From f585aea768ad98440d4967894aa9213cea6e6f14 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Tiziano=20M=C3=BCller?= <tm@dev-zero.ch>
+Date: Tue, 19 Jun 2012 08:03:47 +0200
+Subject: [PATCH] Set codeset for gettext to UTF-8 always
+
+This fixes a segfault in g_markup_escape_text when loading the UI files
+with a non-UTF-8 locale since GTK+ expects all strings (including translation)
+to be in UTF-8.
+---
+ apps/blueman-adapters | 2 ++
+ apps/blueman-assistant | 2 ++
+ apps/blueman-manager | 2 ++
+ apps/blueman-sendto | 2 ++
+ apps/blueman-services | 2 ++
+ blueman/gui/GsmSettings.py | 2 ++
+ blueman/gui/applet/PluginDialog.py | 2 ++
+ blueman/main/applet/BluezAgent.py | 2 ++
+ blueman/plugins/applet/NetUsage.py | 2 ++
+ blueman/plugins/services/Audio.py | 2 ++
+ blueman/plugins/services/Network.py | 2 ++
+ blueman/plugins/services/Transfer.py | 2 ++
+ 12 files changed, 24 insertions(+), 0 deletions(-)
+
+diff --git a/apps/blueman-adapters b/apps/blueman-adapters
+index 6adc642..51325ad 100755
+--- a/apps/blueman-adapters
++++ b/apps/blueman-adapters
+@@ -26,6 +26,7 @@ import gobject
+ import pango
+ import os.path
+ import sys
++from locale import bind_textdomain_codeset
+
+ #support running uninstalled
+ _dirname = os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))
+@@ -47,6 +48,7 @@ class BluemanAdapters:
+
+ builder = gtk.Builder()
+ builder.set_translation_domain("blueman")
++ bind_textdomain_codeset("blueman", "UTF-8")
+ builder.add_from_file(UI_PATH +"/adapters.ui")
+ self.dialog = builder.get_object("dialog")
+
+diff --git a/apps/blueman-assistant b/apps/blueman-assistant
+index 32d8bd8..c30f663 100755
+--- a/apps/blueman-assistant
++++ b/apps/blueman-assistant
+@@ -35,6 +35,7 @@ import gtk
+ import random
+ import dbus.glib
+ from optparse import OptionParser
++from locale import bind_textdomain_codeset
+
+ #support running uninstalled
+ _dirname = os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))
+@@ -74,6 +75,7 @@ class Assistant(Agent):
+
+ self.Builder = gtk.Builder()
+ self.Builder.set_translation_domain("blueman")
++ bind_textdomain_codeset("blueman", "UTF-8")
+ self.Builder.add_from_file(UI_PATH +"/assistant.ui")
+ self.assistant = self.Builder.get_object("assistant")
+ self.assistant.set_title(_("Bluetooth Assistant"))
+diff --git a/apps/blueman-manager b/apps/blueman-manager
+index e4a04e3..3aeb80f 100755
+--- a/apps/blueman-manager
++++ b/apps/blueman-manager
+@@ -25,6 +25,7 @@ import sys
+ import gtk
+ import dbus, dbus.glib
+ import gobject
++from locale import bind_textdomain_codeset
+
+ #support running uninstalled
+ _dirname = os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))
+@@ -56,6 +57,7 @@ class Blueman:
+
+ self.Builder = gtk.Builder()
+ self.Builder.set_translation_domain("blueman")
++ bind_textdomain_codeset("blueman", "UTF-8")
+ self.Builder.add_from_file(UI_PATH +"/manager-main.ui")
+
+ self.window = self.Builder.get_object("window")
+diff --git a/apps/blueman-sendto b/apps/blueman-sendto
+index 72fcfa9..f8c082a 100755
+--- a/apps/blueman-sendto
++++ b/apps/blueman-sendto
+@@ -33,6 +33,7 @@ from optparse import OptionParser
+ import gettext
+ import urllib
+ import time
++from locale import bind_textdomain_codeset
+
+ from blueman.bluez.Adapter import Adapter
+ from blueman.main.Device import Device
+@@ -56,6 +57,7 @@ class Sender(gobject.GObject):
+ gobject.GObject.__init__(self)
+ self.Builder = gtk.Builder()
+ self.Builder.set_translation_domain("blueman")
++ bind_textdomain_codeset("blueman", "UTF-8")
+ self.Builder.add_from_file(UI_PATH +"/send-dialog.ui")
+ self.window = self.Builder.get_object("window")
+
+diff --git a/apps/blueman-services b/apps/blueman-services
+index d6d4545..2c15f03 100755
+--- a/apps/blueman-services
++++ b/apps/blueman-services
+@@ -8,6 +8,7 @@ if os.path.exists(os.path.join(_dirname,"ChangeLog")):
+ sys.path.insert(0, _dirname)
+
+ import gtk
++from locale import bind_textdomain_codeset
+ from blueman.gui.GenericList import GenericList
+
+ from blueman.Functions import *
+@@ -25,6 +26,7 @@ class BluemanServices:
+
+ self.Builder = gtk.Builder()
+ self.Builder.set_translation_domain("blueman")
++ bind_textdomain_codeset("blueman", "UTF-8")
+ self.Builder.add_from_file(UI_PATH +"/services.ui")
+
+ self.Config = Config()
+diff --git a/blueman/gui/GsmSettings.py b/blueman/gui/GsmSettings.py
+index 2e845ec..b4e1059 100644
+--- a/blueman/gui/GsmSettings.py
++++ b/blueman/gui/GsmSettings.py
+@@ -20,6 +20,7 @@ from blueman.main.Config import Config
+ from blueman.Functions import *
+ from blueman.Constants import *
+ import gtk
++from locale import bind_textdomain_codeset
+
+ class GsmSettings(gtk.Dialog):
+ def __init__(self, bd_address):
+@@ -29,6 +30,7 @@ class GsmSettings(gtk.Dialog):
+
+ self.Builder = gtk.Builder()
+ self.Builder.set_translation_domain("blueman")
++ bind_textdomain_codeset("blueman", "UTF-8")
+ self.Builder.add_from_file(UI_PATH +"/gsm-settings.ui")
+
+ vbox = self.Builder.get_object("vbox1")
+diff --git a/blueman/gui/applet/PluginDialog.py b/blueman/gui/applet/PluginDialog.py
+index 1d8cbec..299aa32 100644
+--- a/blueman/gui/applet/PluginDialog.py
++++ b/blueman/gui/applet/PluginDialog.py
+@@ -23,6 +23,7 @@ from blueman.Functions import *
+
+ from blueman.gui.GenericList import GenericList
+ import weakref
++from locale import bind_textdomain_codeset
+
+ class SettingsWidget(gtk.VBox):
+ def __init__(self, inst):
+@@ -118,6 +119,7 @@ class PluginDialog(gtk.Dialog):
+
+ self.Builder = gtk.Builder()
+ self.Builder.set_translation_domain("blueman")
++ bind_textdomain_codeset("blueman", "UTF-8")
+ self.Builder.add_from_file(UI_PATH +"/applet-plugins-widget.ui")
+
+ self.set_title(_("Plugins"))
+diff --git a/blueman/main/applet/BluezAgent.py b/blueman/main/applet/BluezAgent.py
+index 9c7f93e..377f84b 100644
+--- a/blueman/main/applet/BluezAgent.py
++++ b/blueman/main/applet/BluezAgent.py
+@@ -24,6 +24,7 @@ from blueman.Functions import get_icon, dprint
+ import gtk
+ import gobject
+ import cgi
++from locale import bind_textdomain_codeset
+ import blueman.bluez as Bluez
+ from blueman.Sdp import *
+ from blueman.Constants import *
+@@ -65,6 +66,7 @@ class CommonAgent(gobject.GObject, Agent):
+ builder = gtk.Builder()
+ builder.add_from_file(UI_PATH +"/applet-passkey.ui")
+ builder.set_translation_domain("blueman")
++ bind_textdomain_codeset("blueman", "UTF-8")
+ dialog = builder.get_object("dialog")
+
+ dialog.props.icon_name = "blueman"
+diff --git a/blueman/plugins/applet/NetUsage.py b/blueman/plugins/applet/NetUsage.py
+index 0cf15e8..bcebb44 100644
+--- a/blueman/plugins/applet/NetUsage.py
++++ b/blueman/plugins/applet/NetUsage.py
+@@ -33,6 +33,7 @@ import dbus
+ import time
+ import datetime
+ import gettext
++from locale import bind_textdomain_codeset
+
+ class MonitorBase(gobject.GObject):
+ __gsignals__ = {
+@@ -146,6 +147,7 @@ class Dialog:
+ builder = gtk.Builder()
+ builder.add_from_file(UI_PATH + "/net-usage.ui")
+ builder.set_translation_domain("blueman")
++ bind_textdomain_codeset("blueman", "UTF-8")
+
+ self.dialog = builder.get_object("dialog")
+ self.dialog.connect("response", self.on_response)
+diff --git a/blueman/plugins/services/Audio.py b/blueman/plugins/services/Audio.py
+index a725923..6a67fb0 100644
+--- a/blueman/plugins/services/Audio.py
++++ b/blueman/plugins/services/Audio.py
+@@ -19,6 +19,7 @@
+
+ import gtk
+ import dbus
++from locale import bind_textdomain_codeset
+ from blueman.Constants import *
+ from blueman.plugins.ServicePlugin import ServicePlugin
+
+@@ -35,6 +36,7 @@ class Audio(ServicePlugin):
+
+ self.Builder = gtk.Builder()
+ self.Builder.set_translation_domain("blueman")
++ bind_textdomain_codeset("blueman", "UTF-8")
+ self.Builder.add_from_file(UI_PATH +"/services-audio.ui")
+ self.widget = self.Builder.get_object("audio")
+
+diff --git a/blueman/plugins/services/Network.py b/blueman/plugins/services/Network.py
+index d7b9f45..fc8a8f4 100644
+--- a/blueman/plugins/services/Network.py
++++ b/blueman/plugins/services/Network.py
+@@ -18,6 +18,7 @@
+ #
+
+ import gtk
++from locale import bind_textdomain_codeset
+ from blueman.Constants import *
+ from blueman.Functions import have, dprint, mask_ip4_address
+ from blueman.Lib import get_net_interfaces, get_net_address, get_net_netmask
+@@ -36,6 +37,7 @@ class Network(ServicePlugin):
+
+ self.Builder = gtk.Builder()
+ self.Builder.set_translation_domain("blueman")
++ bind_textdomain_codeset("blueman", "UTF-8")
+ self.Builder.add_from_file(UI_PATH +"/services-network.ui")
+ self.widget = self.Builder.get_object("network")
+
+diff --git a/blueman/plugins/services/Transfer.py b/blueman/plugins/services/Transfer.py
+index d8ba6be..5dd44f0 100644
+--- a/blueman/plugins/services/Transfer.py
++++ b/blueman/plugins/services/Transfer.py
+@@ -18,6 +18,7 @@
+ #
+
+ import gtk
++from locale import bind_textdomain_codeset
+ from blueman.Constants import *
+ from blueman.plugins.ServicePlugin import ServicePlugin
+
+@@ -32,6 +33,7 @@ class Transfer(ServicePlugin):
+
+ self.Builder = gtk.Builder()
+ self.Builder.set_translation_domain("blueman")
++ bind_textdomain_codeset("blueman", "UTF-8")
+ self.Builder.add_from_file(UI_PATH +"/services-transfer.ui")
+ self.widget = self.Builder.get_object("transfer")
+
+--
+1.7.8.6
+