aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside2/PySide2/CMakeLists.txt
diff options
context:
space:
mode:
authorChristian Tismer <tismer@stackless.com>2017-10-19 11:27:13 +0200
committerChristian Tismer <tismer@stackless.com>2017-11-14 09:39:59 +0000
commitb825eec459a3d5dcddf14061d578ef89e6ad5ee4 (patch)
tree1d01b860a1134fffb31ab0029a4251c939460a4f /sources/pyside2/PySide2/CMakeLists.txt
parentfa1c97fc2a7f25fe178b0c180b56f78ac00bc4c9 (diff)
Update and complete the signature module
There is now an external typing module for Python 2.7 and Python 3.6 from Guido (PSF license again) that makes the differences between both versions vanish. Also, when generating interface files, some types did not show correctly, and the constant "0" is wrong in almost all cases. Values in signatures looked often bad since they have no nice __repr__, and it was almost impossible to create correct .pyi files. Now, these instances are created as wrapped string types with a nice __repr__. A call of these objects creates the real constant. This way, also objects can be rendered which are dependent from the existence of other objects (i.E. QPixMap). This patch improves the usability of the signature module. We can now generate source code or .pyi files without modifications. Task-number: PYSIDE-510 Change-Id: I55490d76a29fc6c0e4f821c0c77d5e5d1e28976e Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'sources/pyside2/PySide2/CMakeLists.txt')
-rw-r--r--sources/pyside2/PySide2/CMakeLists.txt4
1 files changed, 3 insertions, 1 deletions
diff --git a/sources/pyside2/PySide2/CMakeLists.txt b/sources/pyside2/PySide2/CMakeLists.txt
index 601c43ed6..53c4216fa 100644
--- a/sources/pyside2/PySide2/CMakeLists.txt
+++ b/sources/pyside2/PySide2/CMakeLists.txt
@@ -23,11 +23,13 @@ configure_file("${CMAKE_CURRENT_SOURCE_DIR}/support/signature/parser.py"
if (PYTHON_VERSION_MAJOR EQUAL 3)
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/support/signature/inspect.py"
"${CMAKE_CURRENT_BINARY_DIR}/support/signature/inspect.py" COPYONLY)
- configure_file("${CMAKE_CURRENT_SOURCE_DIR}/support/signature/typing.py"
+ configure_file("${CMAKE_CURRENT_SOURCE_DIR}/support/signature/typing36.py"
"${CMAKE_CURRENT_BINARY_DIR}/support/signature/typing.py" COPYONLY)
else()
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/support/signature/backport_inspect.py"
"${CMAKE_CURRENT_BINARY_DIR}/support/signature/backport_inspect.py" COPYONLY)
+ configure_file("${CMAKE_CURRENT_SOURCE_DIR}/support/signature/typing27.py"
+ "${CMAKE_CURRENT_BINARY_DIR}/support/signature/typing.py" COPYONLY)
endif()
# Add the collected includes to the global include