From bcfba5765f3a0ceef29f9d6c5980bcd9363c2050 Mon Sep 17 00:00:00 2001 From: yopito Date: Mon, 30 Dec 2019 08:20:59 +0100 Subject: [PATCH] python3-pyside2: update to 5.14.0 w/ Qt 5.13.2 support, fix update detection fix #18353 --- common/shlibs | 2 +- .../patches/no-python-arch-suffix.patch | 26 +++++++++++++++++++ ...5.13-support-core-qmessagelogcontext.patch | 16 ++++++++++++ srcpkgs/python3-pyside2/template | 26 +++++++++---------- srcpkgs/python3-pyside2/update | 3 +++ 5 files changed, 58 insertions(+), 15 deletions(-) create mode 100644 srcpkgs/python3-pyside2/patches/no-python-arch-suffix.patch create mode 100644 srcpkgs/python3-pyside2/patches/qt-5.13-support-core-qmessagelogcontext.patch create mode 100644 srcpkgs/python3-pyside2/update diff --git a/common/shlibs b/common/shlibs index 7fdca711b8f..60f082055a3 100644 --- a/common/shlibs +++ b/common/shlibs @@ -1623,7 +1623,7 @@ libshiboken-python3.6.so.1.2 libshiboken-python3-1.2.2_4 libshiboken2.so.5.14 libshiboken2-5.14.0_1 libpyside-python2.7.so.1.2 libpyside-python-1.2.2_2 libpyside-python3.6.so.1.2 libpyside-python3-1.2.2_6 -libpyside2.so.5.11 libpyside2-python3-5.11.2_1 +libpyside2.so.5.14 libpyside2-python3-5.14.0_1 libupsclient.so.4 libnetwork-ups-tools-2.7.2_1 libnutclient.so.0 libnetwork-ups-tools-2.7.2_1 libnutscan.so.1 libnetwork-ups-tools-2.7.3_3 diff --git a/srcpkgs/python3-pyside2/patches/no-python-arch-suffix.patch b/srcpkgs/python3-pyside2/patches/no-python-arch-suffix.patch new file mode 100644 index 00000000000..67a52d3efa0 --- /dev/null +++ b/srcpkgs/python3-pyside2/patches/no-python-arch-suffix.patch @@ -0,0 +1,26 @@ +As for shiboken2 package, makes file naming consistent across architectures for +so libs and cmake files: removes intermediate suffix like ".cpython-36m-x86_64-linux-gnu". +Avoid overwriting the "real" cmake file with the generic wrapper's one (same +name in such a case) + +--- sources/pyside2/libpyside/CMakeLists.txt.ORIG ++++ sources/pyside2/libpyside/CMakeLists.txt +@@ -177,8 +177,6 @@ + PATH_VARS PYSIDE_PYTHONPATH PYSIDE_TYPESYSTEMS PYSIDE_GLUE + ) + +-configure_file("${CMAKE_CURRENT_SOURCE_DIR}/PySide2Config.cmake.in" +- "${CMAKE_CURRENT_BINARY_DIR}/PySide2Config.cmake" @ONLY) + configure_file("${CMAKE_CURRENT_SOURCE_DIR}/PySide2ConfigVersion.cmake.in" + "${CMAKE_CURRENT_BINARY_DIR}/PySide2ConfigVersion.cmake" @ONLY) + +@@ -195,9 +193,6 @@ + install(FILES "${CMAKE_CURRENT_BINARY_DIR}/pyside2${pyside2_SUFFIX}.pc" + DESTINATION "${LIB_INSTALL_DIR}/pkgconfig") + +-install(FILES "${CMAKE_CURRENT_BINARY_DIR}/PySide2Config.cmake" +- DESTINATION "${LIB_INSTALL_DIR}/cmake/PySide2-${BINDING_API_VERSION}") +- + install(FILES "${CMAKE_CURRENT_BINARY_DIR}/install/PySide2Config${SHIBOKEN_PYTHON_CONFIG_SUFFIX}.cmake" + DESTINATION "${LIB_INSTALL_DIR}/cmake/PySide2-${BINDING_API_VERSION}") + diff --git a/srcpkgs/python3-pyside2/patches/qt-5.13-support-core-qmessagelogcontext.patch b/srcpkgs/python3-pyside2/patches/qt-5.13-support-core-qmessagelogcontext.patch new file mode 100644 index 00000000000..96644b596bf --- /dev/null +++ b/srcpkgs/python3-pyside2/patches/qt-5.13-support-core-qmessagelogcontext.patch @@ -0,0 +1,16 @@ +Revert to Qt 5.13 support +source: https://codereview.qt-project.org/c/pyside/pyside-setup/+/272581 + +--- sources/pyside2/PySide2/QtCore/typesystem_core_common.xml.ORIG ++++ sources/pyside2/PySide2/QtCore/typesystem_core_common.xml +@@ -2830,7 +2830,9 @@ + + + +- ++ ++ ++ + + + diff --git a/srcpkgs/python3-pyside2/template b/srcpkgs/python3-pyside2/template index 2f96763bbff..26a6bb82d47 100644 --- a/srcpkgs/python3-pyside2/template +++ b/srcpkgs/python3-pyside2/template @@ -1,12 +1,13 @@ # Template file for 'python3-pyside2' +# XXX CAUTION patched to support Qt 5.13.2 and *NOT* Qt 5.14 +# warning: python3-pyside2 is supposed to be aligned with Qt version pkgname=python3-pyside2 -version=5.11.2 -revision=3 -_pkgname="pyside-setup-everywhere-src-${version}" +version=5.14.0 +revision=1 +_pkgname="pyside-setup-opensource-src-${version}" wrksrc="$_pkgname" -configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr - -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTS=OFF" -pycompile_module="PySide2" +configure_args="-DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release + -DBUILD_TESTS=OFF -DPYTHON_EXECUTABLE=/usr/bin/python" hostmakedepends="cmake" makedepends="python3-devel libshiboken2-devel qt5-devel qt5-multimedia-devel qt5-tools-devel qt5-plugin-mysql qt5-plugin-odbc @@ -14,18 +15,14 @@ makedepends="python3-devel libshiboken2-devel qt5-devel qt5-xmlpatterns-devel qt5-location-devel qt5-declarative-devel qt5-scxml-devel qt5-script-devel qt5-sensors-devel qt5-speech-devel qt5-charts-devel qt5-svg-devel qt5-datavis3d-devel qt5-webchannel-devel qt5-webengine-devel - qt5-websockets-devel qt5-3d-devel qt5-gamepad-devel" + qt5-websockets-devel qt5-3d-devel qt5-gamepad-devel qt5-remoteobjects-devel" +depends="python3-shiboken2" short_desc="Python3 bindings for the Qt5 toolkit" maintainer="yopito " license="LGPL-3.0-or-later" homepage="https://wiki.qt.io/Qt_for_Python" distfiles="https://download.qt.io/official_releases/QtForPython/pyside2/PySide2-${version}-src/${_pkgname}.tar.xz" -checksum=18f572f1f832e476083d30fccabab167450f2a8cbe5cd9c6e6e4fa078ccb86c2 - -pre_build() { - # Fix inconsistent naming of .so and .cmake files - sed -i "/get_python_extension_suffix()/d" sources/pyside2/CMakeLists.txt -} +checksum=8c2ad1901a99165ed7bac8f522ee351ae3ebadd580024248f5a1db52e4a94b30 do_build() { [ ! -d build ] && mkdir build @@ -41,7 +38,8 @@ do_install() { } libpyside2-python3-devel_package() { - depends="libpyside2-python3-${version}_${revision}" + depends="${sourcepkg}-${version}_${revision} + libpyside2-python3-${version}_${revision}" short_desc+=" - shared library (development files)" pkg_install() { vmove usr/include diff --git a/srcpkgs/python3-pyside2/update b/srcpkgs/python3-pyside2/update new file mode 100644 index 00000000000..1c0e6e5fef6 --- /dev/null +++ b/srcpkgs/python3-pyside2/update @@ -0,0 +1,3 @@ +pkgname=pyside-setup-opensource-src +vdprefix=PySide2- +vdsuffix=-src