From 8f29ba59b301cdc859ccdffeec0f1860869ea338 Mon Sep 17 00:00:00 2001 From: Rex Dieter Date: Nov 21 2012 14:45:36 +0000 Subject: Merge branch 'f18' into f17 --- diff --git a/0001-Fix-Python3-and-Python2-text-handling.patch b/0001-Fix-Python3-and-Python2-text-handling.patch new file mode 100644 index 0000000..ba7662e --- /dev/null +++ b/0001-Fix-Python3-and-Python2-text-handling.patch @@ -0,0 +1,47 @@ +From ba44c32b266c598c764447a8411e9000e7ec7dd9 Mon Sep 17 00:00:00 2001 +From: Luca Beltrame +Date: Mon, 19 Nov 2012 19:35:30 +0100 +Subject: [PATCH] Fix Python3 and Python2 text handling. + +Somehow when refactoring the CMakeLists and fixing the duplicated +definitions, the SIP options for Python 2 and Python 3 got swapped, +causing all sorts of subtle bugs (i18n() failing on Python3, encoding +errors from QString on Python 2). This patch fixes the behavior. + +Thanks to Phil Thompson for finding out the cause. + +This fix will also be forward-ported to master. + +CCMAIL: kde-packager@kde.org +--- + CMakeLists.txt | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index af7a815..56249ff 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -98,16 +98,16 @@ SET(SIP_DISABLE_FEATURES VendorID PyQt_NoPrintRangeBug) + IF (PYTHON_3) + IF(PYQT4_VERSION STRGREATER "040904") + # Disable for newer PyQt +- SET(SIP_EXTRA_OPTIONS -g -x PyKDE_QVector -x Py_v3) ++ set(SIP_EXTRA_OPTIONS -g -x PyKDE_QVector) + ELSE (PYQT4_VERSION STRGREATER "040904") +- SET(SIP_EXTRA_OPTIONS -g -x Py_v3) ++ set(SIP_EXTRA_OPTIONS -g) + ENDIF(PYQT4_VERSION STRGREATER "040904") + ELSE (PYTHON_3) + IF(PYQT4_VERSION STRGREATER "040904") + # Disable for newer PyQt +- SET(SIP_EXTRA_OPTIONS -g -x PyKDE_QVector) ++ set(SIP_EXTRA_OPTIONS -g -x PyKDE_QVector -x Py_v3) + ELSE (PYQT4_VERSION STRGREATER "040904") +- SET(SIP_EXTRA_OPTIONS -g) ++ set(SIP_EXTRA_OPTIONS -g -x Py_v3) + ENDIF(PYQT4_VERSION STRGREATER "040904") + ENDIF (PYTHON_3) + +-- +1.8.0 + diff --git a/pykde4.spec b/pykde4.spec index 66f5e8a..f061dbc 100644 --- a/pykde4.spec +++ b/pykde4.spec @@ -9,7 +9,7 @@ Name: pykde4 Version: 4.9.3 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Python bindings for KDE4 # http://techbase.kde.org/Policies/Licensing_Policy @@ -24,6 +24,8 @@ URL: http://developer.kde.org/language-bindings/ Source0: http://download.kde.org/%{stable}/%{version}/src/%{name}-%{version}.tar.xz ## upstream patches +# fix text handling +Patch100: 0001-Fix-Python3-and-Python2-text-handling.patch # debian patches Patch200: make_pykde4_respect_sip_flags.diff @@ -137,6 +139,7 @@ Provides: python3-PyKDE4-devel%{?_isa} = %{version}-%{release} %prep %setup -q -n pykde4-%{version} +%patch100 -p1 -b .text_handling %patch200 -p1 -b .respect_sip_flags %patch201 -p1 -b .kpythonpluginfactory_slots @@ -255,6 +258,9 @@ rm -rf %{buildroot} %changelog +* Wed Nov 21 2012 Rex Dieter 4.9.3-2 +- upstream patch to fix text handling + * Sat Nov 03 2012 Rex Dieter - 4.9.3-1 - 4.9.3