aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside2/libpyside/pyside.h
diff options
context:
space:
mode:
authorAlexandru Croitor <alexandru.croitor@qt.io>2017-11-07 16:14:11 +0100
committerAlexandru Croitor <alexandru.croitor@qt.io>2017-11-15 15:47:09 +0000
commite455d995be989cbdfef2bcd54fd7057a9b036b52 (patch)
tree38a2865cb44350696d60fd15cd5b46a9278d17d9 /sources/pyside2/libpyside/pyside.h
parent49fb9494ba6589cacda3c9e76fc354650a9fd87e (diff)
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 <Friedemann.Kleint@qt.io> Reviewed-by: Christian Tismer <tismer@stackless.com>
Diffstat (limited to 'sources/pyside2/libpyside/pyside.h')
-rw-r--r--sources/pyside2/libpyside/pyside.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/sources/pyside2/libpyside/pyside.h b/sources/pyside2/libpyside/pyside.h
index 3619e2875..becb92208 100644
--- a/sources/pyside2/libpyside/pyside.h
+++ b/sources/pyside2/libpyside/pyside.h
@@ -150,6 +150,19 @@ PYSIDE_API QuickRegisterItemFunction getQuickRegisterItemFunction();
PYSIDE_API void setQuickRegisterItemFunction(QuickRegisterItemFunction function);
#endif // PYSIDE_QML_SUPPORT
+/**
+ * Given A PyObject repesenting ASCII or Unicode data, returns an equivalent QString.
+ */
+PYSIDE_API QString pyStringToQString(PyObject *str);
+
+/**
+ * Registers a dynamic "qt.conf" file with the Qt resource system.
+ *
+ * This is used in a standalone build, to inform QLibraryInfo of the Qt prefix (where Qt libraries
+ * are installed) so that plugins can be successfully loaded.
+ */
+PYSIDE_API bool registerInternalQtConf();
+
} //namespace PySide