Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorShyamnath Premnadh <shyamnath.premnadh@qt.io>2023-04-18 15:08:52 +0200
committerShyamnath Premnadh <Shyamnath.Premnadh@qt.io>2023-04-18 18:16:30 +0200
commit076e16f42cdb7dfe8573625b0538bec02e0eeebc (patch)
tree9a7a596476ca9ef2ceece5fd3aceef771f3d2d13
parenta6c176fe8a48b8d5f5b7ffaa50b1bc8ab53321f2 (diff)
Tooling: Add qmlcachegen
Pick-to: 6.5 Change-Id: I21ae563efb9488083289c7deb6435ae7e9405049 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
-rw-r--r--build_scripts/__init__.py3
-rw-r--r--build_scripts/wheel_files.py2
-rw-r--r--sources/pyside-tools/CMakeLists.txt1
-rw-r--r--sources/pyside-tools/pyside_tool.py4
-rw-r--r--sources/pyside6/doc/gettingstarted/package_details.rst2
5 files changed, 11 insertions, 1 deletions
diff --git a/build_scripts/__init__.py b/build_scripts/__init__.py
index 6ab4c90c8..c99affd0e 100644
--- a/build_scripts/__init__.py
+++ b/build_scripts/__init__.py
@@ -29,7 +29,8 @@ PYSIDE_LINUX_BIN_TOOLS = PYSIDE_UNIX_BIN_TOOLS + PYSIDE_UNIX_BUNDLED_TOOLS
PYSIDE_UNIX_LIBEXEC_TOOLS = ["uic",
"rcc",
"qmltyperegistrar",
- "qmlimportscanner"]
+ "qmlimportscanner",
+ "qmlcachegen"]
# all Qt tools are in 'bin' folder in Windows
PYSIDE_WINDOWS_BIN_TOOLS = PYSIDE_UNIX_LIBEXEC_TOOLS + PYSIDE_LINUX_BIN_TOOLS
diff --git a/build_scripts/wheel_files.py b/build_scripts/wheel_files.py
index cbcdbb678..e5bc63688 100644
--- a/build_scripts/wheel_files.py
+++ b/build_scripts/wheel_files.py
@@ -504,11 +504,13 @@ def module_QtQml() -> ModuleData:
data.extra_files.append("qml/jsroot.qmltypes")
data.extra_files.append("qmlimportscanner.exe")
data.extra_files.append("qmltyperegistrar.exe")
+ data.extra_files.append("qmlcachegen.exe")
else:
data.extra_files.append("Qt/qml/builtins.qmltypes")
data.extra_files.append("Qt/qml/jsroot.qmltypes")
data.extra_files.append("Qt/libexec/qmlimportscanner")
data.extra_files.append("Qt/libexec/qmltyperegistrar")
+ data.extra_files.append("Qt/libexec/qmlcachegen")
data.qtlib.extend(_qtlib)
data.include.extend(_include)
diff --git a/sources/pyside-tools/CMakeLists.txt b/sources/pyside-tools/CMakeLists.txt
index b6f7808e3..795ff669b 100644
--- a/sources/pyside-tools/CMakeLists.txt
+++ b/sources/pyside-tools/CMakeLists.txt
@@ -38,6 +38,7 @@ else()
"${LIBEXEC_PATH}/rcc${CMAKE_EXECUTABLE_SUFFIX}"
"${LIBEXEC_PATH}/qmltyperegistrar${CMAKE_EXECUTABLE_SUFFIX}"
"${LIBEXEC_PATH}/qmlimportscanner${CMAKE_EXECUTABLE_SUFFIX}"
+ "${LIBEXEC_PATH}/qmlcachegen${CMAKE_EXECUTABLE_SUFFIX}"
"${TOOLS_PATH}/lrelease${CMAKE_EXECUTABLE_SUFFIX}"
"${TOOLS_PATH}/lupdate${CMAKE_EXECUTABLE_SUFFIX}"
"${TOOLS_PATH}/qmllint${CMAKE_EXECUTABLE_SUFFIX}"
diff --git a/sources/pyside-tools/pyside_tool.py b/sources/pyside-tools/pyside_tool.py
index cbb2e98f1..615132de6 100644
--- a/sources/pyside-tools/pyside_tool.py
+++ b/sources/pyside-tools/pyside_tool.py
@@ -100,6 +100,10 @@ def qmlimportscanner():
qt_tool_wrapper("qmlimportscanner", sys.argv[1:], True)
+def qmlcachegen():
+ qt_tool_wrapper("qmlcachegen", sys.argv[1:], True)
+
+
def qmllint():
qt_tool_wrapper("qmllint", sys.argv[1:])
diff --git a/sources/pyside6/doc/gettingstarted/package_details.rst b/sources/pyside6/doc/gettingstarted/package_details.rst
index ebc657781..74395b504 100644
--- a/sources/pyside6/doc/gettingstarted/package_details.rst
+++ b/sources/pyside6/doc/gettingstarted/package_details.rst
@@ -110,6 +110,8 @@ QML Development
relevant macros.
* ``pyside6-qmlimportscanner``, to identify the QML modules imported from a
project/QML files and dump the result as a JSON array.
+* ``pyside6-qmlcachegen``, to compile QML to bytecode at compile time for bundling inside the
+ binary.
Translations
~~~~~~~~~~~~