* [ptxdist] [PATCH 1/3] python3-shiboken: new package
@ 2018-01-31 11:16 Bastian Stender
2018-01-31 11:16 ` [ptxdist] [PATCH 2/3] host-python3-shiboken: " Bastian Stender
2018-01-31 11:16 ` [ptxdist] [PATCH 3/3] python3-pyside: " Bastian Stender
0 siblings, 2 replies; 3+ messages in thread
From: Bastian Stender @ 2018-01-31 11:16 UTC (permalink / raw)
To: ptxdist; +Cc: Robin van der Gracht
From: Robin van der Gracht <robin@protonic.nl>
The patches directory patches/shiboken-1.2.2 is ready and compile-time
tested with python2 and python3. Because we could not really test
shiboken 1.2.2 (python2), we did not do a version bump for it.
Signed-off-by: Robin van der Gracht <robin@protonic.nl>
---
...-specifying-the-preferred-Python2-version.patch | 19 +++++
...-specifying-the-preferred-Python3-version.patch | 47 +++++++++++
patches/shiboken-1.2.2/series | 5 ++
rules/python3-shiboken.in | 13 ++++
rules/python3-shiboken.make | 90 ++++++++++++++++++++++
5 files changed, 174 insertions(+)
create mode 100644 patches/shiboken-1.2.2/0001-cmake-allow-specifying-the-preferred-Python2-version.patch
create mode 100644 patches/shiboken-1.2.2/0002-cmake-allow-specifying-the-preferred-Python3-version.patch
create mode 100644 patches/shiboken-1.2.2/series
create mode 100644 rules/python3-shiboken.in
create mode 100644 rules/python3-shiboken.make
diff --git a/patches/shiboken-1.2.2/0001-cmake-allow-specifying-the-preferred-Python2-version.patch b/patches/shiboken-1.2.2/0001-cmake-allow-specifying-the-preferred-Python2-version.patch
new file mode 100644
index 000000000..2a7dd2232
--- /dev/null
+++ b/patches/shiboken-1.2.2/0001-cmake-allow-specifying-the-preferred-Python2-version.patch
@@ -0,0 +1,19 @@
+From: Michael Olbrich <m.olbrich@pengutronix.de>
+Date: Thu, 15 Mar 2012 08:55:26 +0100
+Subject: [PATCH] cmake: allow specifying the preferred Python2 version
+
+Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
+---
+ cmake/Modules/FindPythonInterpWithDebug.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/cmake/Modules/FindPythonInterpWithDebug.cmake b/cmake/Modules/FindPythonInterpWithDebug.cmake
+index 7722d956917e..06c5aff02580 100644
+--- a/cmake/Modules/FindPythonInterpWithDebug.cmake
++++ b/cmake/Modules/FindPythonInterpWithDebug.cmake
+@@ -1,4 +1,4 @@
+-find_program(PYTHON_EXECUTABLE NAMES python2.7 python2.6 python2.5)
++find_program(PYTHON_EXECUTABLE NAMES ${Python_PREFERRED_VERSION} python2.7 python2.6 python2.5)
+
+ if (NOT PYTHON_EXECUTABLE)
+ find_package(PythonInterp REQUIRED)
diff --git a/patches/shiboken-1.2.2/0002-cmake-allow-specifying-the-preferred-Python3-version.patch b/patches/shiboken-1.2.2/0002-cmake-allow-specifying-the-preferred-Python3-version.patch
new file mode 100644
index 000000000..2d985e42d
--- /dev/null
+++ b/patches/shiboken-1.2.2/0002-cmake-allow-specifying-the-preferred-Python3-version.patch
@@ -0,0 +1,47 @@
+From: Bastian Stender <bst@pengutronix.de>
+Date: Fri, 26 Jan 2018 14:27:23 +0100
+Subject: [PATCH] cmake: allow specifying the preferred Python3 version
+
+Signed-off-by: Bastian Stender <bst@pengutronix.de>
+---
+ cmake/Modules/FindPython3Interp.cmake | 4 ++--
+ cmake/Modules/FindPython3Libs.cmake | 4 +++-
+ 2 files changed, 5 insertions(+), 3 deletions(-)
+
+diff --git a/cmake/Modules/FindPython3Interp.cmake b/cmake/Modules/FindPython3Interp.cmake
+index 373982e210a3..ad38c6697bc8 100644
+--- a/cmake/Modules/FindPython3Interp.cmake
++++ b/cmake/Modules/FindPython3Interp.cmake
+@@ -20,7 +20,7 @@
+ # License text for the above reference.)
+
+ FIND_PROGRAM(PYTHON3_EXECUTABLE
+- NAMES python3.2mu python3.2m python3.2u python3.2 python3.1 python3.0 python3
++ NAMES ${Python3_PREFERRED_VERSION} python3.2mu python3.2m python3.2u python3.2 python3.1 python3.0 python3
+ PATHS
+ [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\3.2\\InstallPath]
+ [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\3.1\\InstallPath]
+@@ -28,7 +28,7 @@ FIND_PROGRAM(PYTHON3_EXECUTABLE
+ )
+
+ FIND_PROGRAM(PYTHON3_DBG_EXECUTABLE
+- NAMES python3.2dmu python3.2dm python3.2du python3.2d python3.1-dbg python3.0-dbg python3-dbg
++ NAMES ${Python3_PREFERRED_VERSION} python3.2dmu python3.2dm python3.2du python3.2d python3.1-dbg python3.0-dbg python3-dbg
+ PATHS
+ [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\3.2\\InstallPath]
+ [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\3.1\\InstallPath]
+diff --git a/cmake/Modules/FindPython3Libs.cmake b/cmake/Modules/FindPython3Libs.cmake
+index 20a82ba07d59..e1789438a4b9 100644
+--- a/cmake/Modules/FindPython3Libs.cmake
++++ b/cmake/Modules/FindPython3Libs.cmake
+@@ -27,7 +27,9 @@ INCLUDE(CMakeFindFrameworks)
+ # Search for the python framework on Apple.
+ # CMAKE_FIND_FRAMEWORKS(Python)
+
+-FOREACH(_CURRENT_VERSION 3.4 3.3 3.2 3.1 3.0)
++STRING(REPLACE "python" "" Python3_PREFERRED_VERSION_NUMBER ${Python3_PREFERRED_VERSION})
++
++FOREACH(_CURRENT_VERSION ${Python3_PREFERRED_VERSION_NUMBER} 3.4 3.3 3.2 3.1 3.0)
+ IF(_CURRENT_VERSION GREATER 3.1)
+ SET(_32FLAGS "m" "u" "mu" "dm" "du" "dmu" "")
+ ELSE()
diff --git a/patches/shiboken-1.2.2/series b/patches/shiboken-1.2.2/series
new file mode 100644
index 000000000..35630db2b
--- /dev/null
+++ b/patches/shiboken-1.2.2/series
@@ -0,0 +1,5 @@
+# generated by git-ptx-patches
+#tag:base --start-number 1
+0001-cmake-allow-specifying-the-preferred-Python2-version.patch
+0002-cmake-allow-specifying-the-preferred-Python3-version.patch
+# 51481bffa6f992fb0f955bd13139b6db - git-ptx-patches magic
diff --git a/rules/python3-shiboken.in b/rules/python3-shiboken.in
new file mode 100644
index 000000000..ccdcf17fc
--- /dev/null
+++ b/rules/python3-shiboken.in
@@ -0,0 +1,13 @@
+## SECTION=qt
+
+config PYTHON3_SHIBOKEN
+ tristate
+ prompt "python3-shiboken"
+ select HOST_CMAKE
+ select HOST_PYTHON3_SHIBOKEN
+ select LIBXML2
+ select LIBXSLT
+ select PYTHON3
+ select QT4
+ help
+ Shiboken generates bindings for C++ libraries using CPython source code.
diff --git a/rules/python3-shiboken.make b/rules/python3-shiboken.make
new file mode 100644
index 000000000..ffbbdfba8
--- /dev/null
+++ b/rules/python3-shiboken.make
@@ -0,0 +1,90 @@
+# -*-makefile-*-
+#
+# Copyright (C) 2016 by Robin van der Gracht <robin@protonic.nl>
+#
+# See CREDITS for details about who has contributed to this project.
+#
+# For further information about the PTXdist project and license conditions
+# see the README file.
+#
+
+#
+# We provide this package
+#
+PACKAGES-$(PTXCONF_PYTHON3_SHIBOKEN) += python3-shiboken
+
+#
+# Paths and names
+#
+PYTHON3_SHIBOKEN_VERSION := 1.2.2
+PYTHON3_SHIBOKEN_MD5 := 9f5bee9d414ce51be07ff7a20054a48d
+PYTHON3_SHIBOKEN := shiboken-$(PYTHON3_SHIBOKEN_VERSION)
+PYTHON3_SHIBOKEN_SUFFIX := tar.bz2
+PYTHON3_SHIBOKEN_URL := https://download.qt.io/official_releases/pyside/shiboken-$(PYTHON3_SHIBOKEN_VERSION).$(PYTHON3_SHIBOKEN_SUFFIX)
+PYTHON3_SHIBOKEN_SOURCE := $(SRCDIR)/$(PYTHON3_SHIBOKEN).$(PYTHON3_SHIBOKEN_SUFFIX)
+PYTHON3_SHIBOKEN_DIR := $(BUILDDIR)/$(PYTHON3_SHIBOKEN)
+PYTHON3_SHIBOKEN_LICENSE := GPL-2.0
+
+# ----------------------------------------------------------------------------
+# Prepare
+# ----------------------------------------------------------------------------
+
+#
+# cmake
+#
+PYTHON3_SHIBOKEN_CONF_TOOL := cmake
+PYTHON3_SHIBOKEN_CONF_OPT = \
+ $(CROSS_CMAKE_USR) \
+ -DBUILD_TESTS:BOOL=OFF \
+ -DUSE_PYTHON3:BOOL=ON \
+ -DPython3_PREFERRED_VERSION=python$(PYTHON3_MAJORMINOR)
+
+PYTHON3_SHIBOKEN_MAKE_OPT := -C libshiboken
+PYTHON3_SHIBOKEN_INSTALL_OPT := -C libshiboken install
+
+# ----------------------------------------------------------------------------
+# Install
+# ----------------------------------------------------------------------------
+
+$(STATEDIR)/python3-shiboken.install:
+ @$(call targetinfo)
+ @$(call world/install, PYTHON3_SHIBOKEN)
+ @cd $(PYTHON3_SHIBOKEN_DIR)-build && $(MAKE) -C data install DESTDIR='$(PYTHON3_SHIBOKEN_PKGDIR)'
+ @sed -i -e 's,"$(SYSROOT)/usr,"SYSROOT/usr,g' \
+ -e 's,"$(PTXCONF_SYSROOT_CROSS),"SYSROOT_CROSS,g' \
+ $(PYTHON3_SHIBOKEN_PKGDIR)/usr/lib/cmake/Shiboken-$(PYTHON3_SHIBOKEN_VERSION)/ShibokenConfig.cpython*.cmake
+ @$(call touch)
+
+$(STATEDIR)/python3-shiboken.install.post:
+ @$(call targetinfo)
+ @$(call world/install.post, PYTHON3_SHIBOKEN)
+ @sed -i -e 's,(/usr,($(SYSROOT)/usr,g' \
+ '$(SYSROOT)/usr/lib/cmake/Shiboken-$(PYTHON3_SHIBOKEN_VERSION)/ShibokenConfig.cmake'
+ @sed -i -e 's,"SYSROOT_CROSS,"$(PTXCONF_SYSROOT_CROSS),g' \
+ -e 's,"SYSROOT/usr,"$(SYSROOT)/usr,g' \
+ -e 's,"/usr/bin,"$(PTXCONF_SYSROOT_HOST)/bin,g' \
+ -e 's,"/usr,"$(SYSROOT)/usr,g' \
+ $(SYSROOT)/usr/lib/cmake/Shiboken-$(PYTHON3_SHIBOKEN_VERSION)/ShibokenConfig.cpython*.cmake
+ @$(call touch)
+
+# ----------------------------------------------------------------------------
+# Target-Install
+# ----------------------------------------------------------------------------
+
+$(STATEDIR)/python3-shiboken.targetinstall:
+ @$(call targetinfo)
+
+ @$(call install_init, python3-shiboken)
+ @$(call install_fixup, python3-shiboken, PRIORITY, optional)
+ @$(call install_fixup, python3-shiboken, SECTION, base)
+ @$(call install_fixup, python3-shiboken, AUTHOR, "Robin van der Gracht <robin@protonic.nl>")
+ @$(call install_fixup, python3-shiboken, DESCRIPTION, missing)
+
+ @$(call install_lib, python3-shiboken, 0, 0, 0644, \
+ libshiboken.cpython-*)
+
+ @$(call install_finish, python3-shiboken)
+
+ @$(call touch)
+
+# vim: syntax=make
--
2.15.1
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 3+ messages in thread
* [ptxdist] [PATCH 2/3] host-python3-shiboken: new package
2018-01-31 11:16 [ptxdist] [PATCH 1/3] python3-shiboken: new package Bastian Stender
@ 2018-01-31 11:16 ` Bastian Stender
2018-01-31 11:16 ` [ptxdist] [PATCH 3/3] python3-pyside: " Bastian Stender
1 sibling, 0 replies; 3+ messages in thread
From: Bastian Stender @ 2018-01-31 11:16 UTC (permalink / raw)
To: ptxdist; +Cc: Robin van der Gracht
From: Robin van der Gracht <robin@protonic.nl>
Depends on "python3-shiboken: new package", because we assume a
patched shiboken 1.2.2.
Signed-off-by: Robin van der Gracht <robin@protonic.nl>
---
rules/host-python3-shiboken.in | 9 +++++++
rules/host-python3-shiboken.make | 55 ++++++++++++++++++++++++++++++++++++++++
2 files changed, 64 insertions(+)
create mode 100644 rules/host-python3-shiboken.in
create mode 100644 rules/host-python3-shiboken.make
diff --git a/rules/host-python3-shiboken.in b/rules/host-python3-shiboken.in
new file mode 100644
index 000000000..351121547
--- /dev/null
+++ b/rules/host-python3-shiboken.in
@@ -0,0 +1,9 @@
+## SECTION=hosttools_noprompt
+
+config HOST_PYTHON3_SHIBOKEN
+ tristate
+ default ALLYES
+ select HOST_APIEXTRACTOR
+ select HOST_GENERATORRUNNER
+ select HOST_CMAKE
+ select HOST_PYTHON3
diff --git a/rules/host-python3-shiboken.make b/rules/host-python3-shiboken.make
new file mode 100644
index 000000000..6363c1157
--- /dev/null
+++ b/rules/host-python3-shiboken.make
@@ -0,0 +1,55 @@
+# -*-makefile-*-
+#
+# Copyright (C) 2016 by Robin van der Gracht <robin@protonic.nl>
+#
+# See CREDITS for details about who has contributed to this project.
+#
+# For further information about the PTXdist project and license conditions
+# see the README file.
+#
+
+#
+# We provide this package
+#
+HOST_PACKAGES-$(PTXCONF_HOST_PYTHON3_SHIBOKEN) += host-python3-shiboken
+
+#
+# Paths and names
+#
+
+# ----------------------------------------------------------------------------
+# Prepare
+# ----------------------------------------------------------------------------
+
+#
+# cmake
+#
+HOST_PYTHON3_SHIBOKEN_CONF_TOOL := cmake
+HOST_PYTHON3_SHIBOKEN_CONF_OPT = \
+ $(HOST_CMAKE_OPT) \
+ -DBUILD_TESTS:BOOL=OFF \
+ -DDISABLE_DOCSTRINGS:BOOL=ON \
+ -DUSE_PYTHON3:BOOL=ON \
+ -DPython3_PREFERRED_VERSION=python$(PYTHON3_MAJORMINOR)
+
+# ----------------------------------------------------------------------------
+# Install
+# ----------------------------------------------------------------------------
+
+$(STATEDIR)/host-python3-shiboken.install:
+ @$(call targetinfo)
+ @$(call world/install, HOST_PYTHON3_SHIBOKEN)
+ @sed -i -e 's,"$(PTXCONF_SYSROOT_HOST),",g' \
+ $(HOST_PYTHON3_SHIBOKEN_PKGDIR)/lib/cmake/Shiboken-$(PYTHON3_SHIBOKEN_VERSION)/ShibokenConfig.cpython-*.cmake
+ @$(call touch)
+
+$(STATEDIR)/host-python3-shiboken.install.post:
+ @$(call targetinfo)
+ @$(call world/install.post, HOST_PYTHON3_SHIBOKEN)
+ @sed -i -e 's,(/,($(PTXCONF_SYSROOT_HOST)/,g' \
+ '$(PTXCONF_SYSROOT_HOST)/lib/cmake/Shiboken-$(PYTHON3_SHIBOKEN_VERSION)/ShibokenConfig.cmake'
+ @sed -i -e 's,"/,"$(PTXCONF_SYSROOT_HOST)/,g' \
+ $(HOST_PYTHON3_SHIBOKEN_PKGDIR)/lib/cmake/Shiboken-$(PYTHON3_SHIBOKEN_VERSION)/ShibokenConfig.cpython-*.cmake
+ @$(call touch)
+
+# vim: syntax=make
--
2.15.1
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 3+ messages in thread
* [ptxdist] [PATCH 3/3] python3-pyside: new package
2018-01-31 11:16 [ptxdist] [PATCH 1/3] python3-shiboken: new package Bastian Stender
2018-01-31 11:16 ` [ptxdist] [PATCH 2/3] host-python3-shiboken: " Bastian Stender
@ 2018-01-31 11:16 ` Bastian Stender
1 sibling, 0 replies; 3+ messages in thread
From: Bastian Stender @ 2018-01-31 11:16 UTC (permalink / raw)
To: ptxdist; +Cc: Robin van der Gracht
From: Robin van der Gracht <robin@protonic.nl>
The patches directory patches/pyside-qt4.8+1.2.2 is ready and
compile-time tested with python2 and python3. Because we could not
really test pyside qt4.8+1.2.2 (python2), we did not do a version bump
for it.
Signed-off-by: Robin van der Gracht <robin@protonic.nl>
---
...ccessibleevent_wrapper.cpp-if-accessible-.patch | 37 +++++++
.../0002-add-include-iostream.patch | 23 ++++
.../pyside-qt4.8+1.2.2/0003-add-qws-support.patch | 116 +++++++++++++++++++++
patches/pyside-qt4.8+1.2.2/series | 6 ++
rules/python3-pyside.in | 11 ++
rules/python3-pyside.make | 64 ++++++++++++
6 files changed, 257 insertions(+)
create mode 100644 patches/pyside-qt4.8+1.2.2/0001-only-add-qaccessibleevent_wrapper.cpp-if-accessible-.patch
create mode 100644 patches/pyside-qt4.8+1.2.2/0002-add-include-iostream.patch
create mode 100644 patches/pyside-qt4.8+1.2.2/0003-add-qws-support.patch
create mode 100644 patches/pyside-qt4.8+1.2.2/series
create mode 100644 rules/python3-pyside.in
create mode 100644 rules/python3-pyside.make
diff --git a/patches/pyside-qt4.8+1.2.2/0001-only-add-qaccessibleevent_wrapper.cpp-if-accessible-.patch b/patches/pyside-qt4.8+1.2.2/0001-only-add-qaccessibleevent_wrapper.cpp-if-accessible-.patch
new file mode 100644
index 000000000..d3575867c
--- /dev/null
+++ b/patches/pyside-qt4.8+1.2.2/0001-only-add-qaccessibleevent_wrapper.cpp-if-accessible-.patch
@@ -0,0 +1,37 @@
+From: Michael Olbrich <m.olbrich@pengutronix.de>
+Date: Wed, 26 Jan 2011 01:20:31 +0100
+Subject: [PATCH] only add qaccessibleevent_wrapper.cpp if accessible is
+ enabled
+
+Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
+---
+ PySide/QtGui/CMakeLists.txt | 9 ++++++++-
+ 1 file changed, 8 insertions(+), 1 deletion(-)
+
+diff --git a/PySide/QtGui/CMakeLists.txt b/PySide/QtGui/CMakeLists.txt
+index 6e147067f8aa..94d4787d57ff 100644
+--- a/PySide/QtGui/CMakeLists.txt
++++ b/PySide/QtGui/CMakeLists.txt
+@@ -86,6 +86,13 @@ check_qt_class(QtGui QMacStyle QtGui_OPTIONAL_SRC QtGui_DROPPED
+
+ qt4_wrap_cpp(QPYTEXTOBJECT_MOC "${pyside_SOURCE_DIR}/qpytextobject.h")
+
++if (QT_QCONFIG MATCHES "accessibility")
++set(QtGui_accessible_SRC
++${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qaccessibleevent_wrapper.cpp)
++else()
++set(QtGui_accessible_SRC )
++endif ()
++
+ set(QtGui_SRC
+ ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qabstractbutton_wrapper.cpp
+ ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qabstractgraphicsshapeitem_wrapper.cpp
+@@ -98,7 +105,7 @@ ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qabstractspinbox_wrapper.cpp
+ ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qabstracttextdocumentlayout_paintcontext_wrapper.cpp
+ ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qabstracttextdocumentlayout_selection_wrapper.cpp
+ ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qabstracttextdocumentlayout_wrapper.cpp
+-${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qaccessibleevent_wrapper.cpp
++${QtGui_accessible_SRC}
+ ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qactionevent_wrapper.cpp
+ ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qactiongroup_wrapper.cpp
+ ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qaction_wrapper.cpp
diff --git a/patches/pyside-qt4.8+1.2.2/0002-add-include-iostream.patch b/patches/pyside-qt4.8+1.2.2/0002-add-include-iostream.patch
new file mode 100644
index 000000000..48c6b6b1b
--- /dev/null
+++ b/patches/pyside-qt4.8+1.2.2/0002-add-include-iostream.patch
@@ -0,0 +1,23 @@
+From: Michael Olbrich <m.olbrich@pengutronix.de>
+Date: Fri, 28 Jan 2011 16:03:10 +0100
+Subject: [PATCH] add "#include <iostream>"
+
+Without it std::copy() is undefined when Qt is build without stl.
+
+Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
+---
+ libpyside/dynamicqmetaobject.cpp | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/libpyside/dynamicqmetaobject.cpp b/libpyside/dynamicqmetaobject.cpp
+index e88e3dfdfcec..a2db462a0104 100644
+--- a/libpyside/dynamicqmetaobject.cpp
++++ b/libpyside/dynamicqmetaobject.cpp
+@@ -35,6 +35,7 @@
+ #include <QLinkedList>
+ #include <QObject>
+ #include <cstring>
++#include <iostream>
+ #include <QDebug>
+ #include <QMetaMethod>
+ #include <shiboken.h>
diff --git a/patches/pyside-qt4.8+1.2.2/0003-add-qws-support.patch b/patches/pyside-qt4.8+1.2.2/0003-add-qws-support.patch
new file mode 100644
index 000000000..ee13ed6e3
--- /dev/null
+++ b/patches/pyside-qt4.8+1.2.2/0003-add-qws-support.patch
@@ -0,0 +1,116 @@
+From: Michael Olbrich <m.olbrich@pengutronix.de>
+Date: Mon, 20 Jun 2011 21:42:41 +0200
+Subject: [PATCH] add qws support
+
+based on a patch from OpenEmbedded:
+http://cgit.openembedded.net/cgit.cgi/openembedded/tree/recipes/pyside/python-pyside-embedded/support-qws.patch
+
+Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
+---
+ CMakeLists.txt | 4 ++++
+ PySide/QtCore/typesystem_core_qws.xml | 26 ++++++++++++++++++++++++++
+ PySide/QtGui/typesystem_gui_common.xml | 2 ++
+ PySide/QtGui/typesystem_gui_qws.xml | 26 ++++++++++++++++++++++++++
+ 4 files changed, 58 insertions(+)
+ create mode 100644 PySide/QtCore/typesystem_core_qws.xml
+ create mode 100644 PySide/QtGui/typesystem_gui_qws.xml
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 9e0e3d07e2e3..0e7d85025376 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -88,6 +88,7 @@ set(ENABLE_X11 "0")
+ set(ENABLE_MAC "0")
+ set(ENABLE_WIN "0")
+ set(ENABLE_SIMULATOR "0")
++set(ENABLE_QWS "0")
+ if(Q_WS_X11)
+ set(ENABLE_X11 "1")
+ if(Q_WS_MAEMO_5)
+@@ -104,6 +105,9 @@ elseif(Q_WS_WIN)
+ elseif(Q_WS_SIMULATOR)
+ set(ENABLE_SIMULATOR "1")
+ set(AUTO_OS "simulator")
++elseif(Q_WS_QWS)
++ set(ENABLE_QWS "1")
++ set(AUTO_OS "qws")
+ else()
+ message(FATAL_ERROR "OS not supported")
+ endif()
+diff --git a/PySide/QtCore/typesystem_core_qws.xml b/PySide/QtCore/typesystem_core_qws.xml
+new file mode 100644
+index 000000000000..eba223c73097
+--- /dev/null
++++ b/PySide/QtCore/typesystem_core_qws.xml
+@@ -0,0 +1,26 @@
++<?xml version="1.0"?>
++<!--
++ This file is part of PySide project.
++ Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies).
++ Contact: PySide team <contact@pyside.org>
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Lesser General Public
++ License as published by the Free Software Foundation; either
++ version 2.1 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Lesser General Public License for more details.
++
++ You should have received a copy of the GNU Lesser General Public
++ License along with this library; if not, write to the Free Software
++ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
++-->
++<typesystem package="PySide.QtCore">
++ <primitive-type name="Qt::HANDLE" target-lang-api-name="PyLong">
++ <!-- FIXME APIExtractor or shiboken do not support multiple includes by primitive type -->
++ <include file-name="QTextDocument" location="global"/>
++ </primitive-type>
++</typesystem>
+diff --git a/PySide/QtGui/typesystem_gui_common.xml b/PySide/QtGui/typesystem_gui_common.xml
+index 711d7cc3a352..e7d00eac6df8 100644
+--- a/PySide/QtGui/typesystem_gui_common.xml
++++ b/PySide/QtGui/typesystem_gui_common.xml
+@@ -5635,6 +5635,8 @@
+ <modify-function signature="QApplication(int&,char**,bool,int)" remove="all"/>
+ <modify-function signature="QApplication(int&,char**,QApplication::Type,int)" remove="all"/>
+ <!-- ### -->
++ <!-- QWS: FIXME: really fix this -->
++ <modify-function signature="setArgs(int,char**)" remove="all"/>
+
+ <!-- ownership control transfer to qApp -->
+ <modify-function signature="setStyle(QStyle*)">
+diff --git a/PySide/QtGui/typesystem_gui_qws.xml b/PySide/QtGui/typesystem_gui_qws.xml
+new file mode 100644
+index 000000000000..d4a4793ad496
+--- /dev/null
++++ b/PySide/QtGui/typesystem_gui_qws.xml
+@@ -0,0 +1,26 @@
++<?xml version="1.0"?>
++<!--
++ This file is part of PySide project.
++ Copyright (C) 2009-2010 Nokia Corporation and/or its subsidiary(-ies).
++ Contact: PySide team <contact@pyside.org>
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Lesser General Public
++ License as published by the Free Software Foundation; either
++ version 2.1 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Lesser General Public License for more details.
++
++ You should have received a copy of the GNU Lesser General Public
++ License along with this library; if not, write to the Free Software
++ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
++-->
++<typesystem package="PySide.QtGui">
++ <value-type name="QCursor">
++ <!-- Does not exist on QWS -->
++ <modify-function signature="QCursor(Qt::HANDLE)" remove="all"/>
++ </value-type>
++</typesystem>
diff --git a/patches/pyside-qt4.8+1.2.2/series b/patches/pyside-qt4.8+1.2.2/series
new file mode 100644
index 000000000..cce9c351b
--- /dev/null
+++ b/patches/pyside-qt4.8+1.2.2/series
@@ -0,0 +1,6 @@
+# generated by git-ptx-patches
+#tag:base --start-number 1
+0001-only-add-qaccessibleevent_wrapper.cpp-if-accessible-.patch
+0002-add-include-iostream.patch
+0003-add-qws-support.patch
+# edb0310fe7e30ecdc0404f3b02598af7 - git-ptx-patches magic
diff --git a/rules/python3-pyside.in b/rules/python3-pyside.in
new file mode 100644
index 000000000..cb8db5a1a
--- /dev/null
+++ b/rules/python3-pyside.in
@@ -0,0 +1,11 @@
+## SECTION=qt
+
+config PYTHON3_PYSIDE
+ tristate
+ prompt "python3-pyside-qt4"
+ select QT4
+ select PYTHON3_SHIBOKEN
+ select HOST_CMAKE
+ help
+ PySide provides Python bindings for the Qt cross-platform
+ application and UI framework.
diff --git a/rules/python3-pyside.make b/rules/python3-pyside.make
new file mode 100644
index 000000000..5d4bdddfb
--- /dev/null
+++ b/rules/python3-pyside.make
@@ -0,0 +1,64 @@
+# -*-makefile-*-
+#
+# Copyright (C) 2016 by Robin van der Gracht <robin@protonic.nl>
+#
+# See CREDITS for details about who has contributed to this project.
+#
+# For further information about the PTXdist project and license conditions
+# see the README file.
+#
+
+#
+# We provide this package
+#
+PACKAGES-$(PTXCONF_PYTHON3_PYSIDE) += python3-pyside
+
+#
+# Paths and names
+#
+PYTHON3_PYSIDE_VERSION := 4.8+1.2.2
+PYTHON3_PYSIDE_MD5 := 1969c2ff90eefaa4b200d234059d2287
+PYTHON3_PYSIDE := pyside-qt$(PYTHON3_PYSIDE_VERSION)
+PYTHON3_PYSIDE_SUFFIX := tar.bz2
+PYTHON3_PYSIDE_URL := http://download.qt-project.org/official_releases/pyside/$(PYTHON3_PYSIDE).$(PYTHON3_PYSIDE_SUFFIX)
+PYTHON3_PYSIDE_SOURCE := $(SRCDIR)/$(PYTHON3_PYSIDE).$(PYTHON3_PYSIDE_SUFFIX)
+PYTHON3_PYSIDE_DIR := $(BUILDDIR)/$(PYTHON3_PYSIDE)
+PYTHON3_PYSIDE_LICENSE := LGPL-2.1
+
+# ----------------------------------------------------------------------------
+# Prepare
+# ----------------------------------------------------------------------------
+
+#
+# cmake
+#
+PYSIDE_CONF_TOOL := cmake
+PYSIDE_CONF_ENV := PATH=$(CROSS_PATH)
+PYSIDE_CONF_OPT = \
+ $(CROSS_CMAKE_USR) \
+ -DUSE_PYTHON3:BOOL=ON
+
+# ----------------------------------------------------------------------------
+# Target-Install
+# ----------------------------------------------------------------------------
+
+$(STATEDIR)/python3-pyside.targetinstall:
+ @$(call targetinfo)
+
+ @$(call install_init, python3-pyside)
+ @$(call install_fixup, python3-pyside, PRIORITY, optional)
+ @$(call install_fixup, python3-pyside, SECTION, base)
+ @$(call install_fixup, python3-pyside, AUTHOR, "Robin van der Gracht <robin@protonic.nl>")
+ @$(call install_fixup, python3-pyside, DESCRIPTION, missing)
+
+ @$(call install_lib, python3-pyside, 0, 0, 0644, \
+ libpyside.cpython-*)
+ @$(call install_tree, python3-pyside, 0, 0, \
+ $(PYTHON3_PYSIDE_PKGDIR)/usr/lib/python$(PYTHON3_MAJORMINOR)/site-packages/PySide, \
+ /usr/lib/python$(PYTHON3_MAJORMINOR)/site-packages/PySide)
+
+ @$(call install_finish, python3-pyside)
+
+ @$(call touch)
+
+# vim: syntax=make
--
2.15.1
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-01-31 11:16 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-31 11:16 [ptxdist] [PATCH 1/3] python3-shiboken: new package Bastian Stender
2018-01-31 11:16 ` [ptxdist] [PATCH 2/3] host-python3-shiboken: " Bastian Stender
2018-01-31 11:16 ` [ptxdist] [PATCH 3/3] python3-pyside: " Bastian Stender
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox