From e455d995be989cbdfef2bcd54fd7057a9b036b52 Mon Sep 17 00:00:00 2001 From: Alexandru Croitor Date: Tue, 7 Nov 2017 16:14:11 +0100 Subject: Make standalone installations relocatable This is achieved by registering a qt.conf file with a Prefix pointing to a directory relative to the loaded PySide2 module (e.g. QtCore). Thus Qt does not crash due to not finding platform plugins. Because this change would affect tests, which are ran before the PySide package is installed, a new environment variable called PYSIDE_DISABLE_INTERNAL_QT_CONF is introduced. This variable disables the registration of the internal qt.conf file, thus it will not point to a not yet created location, which will allow tests to run as before. Change-Id: I5a96037adfafe1f08ea57535aa4a2a0d1660dfaf Task-number: PYSIDE-558 Reviewed-by: Friedemann Kleint Reviewed-by: Christian Tismer --- .../PySide2/QtCore/typesystem_core_common.xml | 8 +- sources/pyside2/libpyside/CMakeLists.txt | 7 ++ sources/pyside2/libpyside/pyside.cpp | 130 ++++++++++++++++++++- sources/pyside2/libpyside/pyside.h | 13 +++ sources/pyside2/tests/CMakeLists.txt | 2 +- 5 files changed, 155 insertions(+), 5 deletions(-) (limited to 'sources') diff --git a/sources/pyside2/PySide2/QtCore/typesystem_core_common.xml b/sources/pyside2/PySide2/QtCore/typesystem_core_common.xml index 951d943ee..65f68882d 100644 --- a/sources/pyside2/PySide2/QtCore/typesystem_core_common.xml +++ b/sources/pyside2/PySide2/QtCore/typesystem_core_common.xml @@ -74,6 +74,10 @@ + + #include <pyside.h> + +