diff options
| author | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2025-10-13 06:35:35 +0300 |
|---|---|---|
| committer | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2025-10-13 06:35:35 +0300 |
| commit | 6523109822ec2ef01aa48f183c10fc26b292a31c (patch) | |
| tree | 1163c6333c77eb6a33aaf3ce9143e46187de5de3 | |
| parent | b597af7cc78af70892c05fd42f70ffdbb1f504b1 (diff) | |
| parent | 5d1e4c73ca4593989444a812b7c0a3251eb6c538 (diff) | |
Merge tag 'v6.5.7-lts-lgpl' into 6.56.5
Qt 6.5.7-lts-lgpl release
Change-Id: I22b33dfd9bdce596e9968d4d55f0a0e908bd4309
49 files changed, 302 insertions, 78 deletions
diff --git a/.cmake.conf b/.cmake.conf index 8b61d211..0ea483ac 100644 --- a/.cmake.conf +++ b/.cmake.conf @@ -1 +1 @@ -set(QT_REPO_MODULE_VERSION "6.5.6") +set(QT_REPO_MODULE_VERSION "6.5.7") diff --git a/dependencies.yaml b/dependencies.yaml index e1f2212f..aa1fa02e 100644 --- a/dependencies.yaml +++ b/dependencies.yaml @@ -1,13 +1,13 @@ dependencies: ../tqtc-qtdeclarative: - ref: ff0a47c8f267e905113b82c53af2742027f0eca6 + ref: 844f9b9b376838bcb44324984876f8bf99d85d38 required: true ../tqtc-qtmultimedia: - ref: 0247b19277274736124239029f4cd9e4cce7a4c6 + ref: 3cc3a6bd7e32fddac5ec2d51fe68b02fb17a7af3 required: true ../tqtc-qtremoteobjects: - ref: 0e53867e7451f452224d02310e3f8d81c9d0057c + ref: a38447683b6fa3ff82212c7ce282805bed1d45cc required: true ../tqtc-qttools: - ref: 786bdcbf8cdc7ba3d4e5a8c15e1ead03c5926967 + ref: cf5106463bd3aeb78a6a51839673b0e4f008fd82 required: false diff --git a/examples/interfaceframework/CMakeLists.txt b/examples/interfaceframework/CMakeLists.txt index 60ca1624..492f607a 100644 --- a/examples/interfaceframework/CMakeLists.txt +++ b/examples/interfaceframework/CMakeLists.txt @@ -1,6 +1,3 @@ -cmake_minimum_required(VERSION 3.16) -project(example LANGUAGES CXX) - if(QT_FEATURE_ifcodegen) add_subdirectory(qface-climate) add_subdirectory(qface-addressbook) diff --git a/examples/interfaceframework/qface-addressbook/CMakeLists.txt b/examples/interfaceframework/qface-addressbook/CMakeLists.txt index 68e1a789..2617d661 100644 --- a/examples/interfaceframework/qface-addressbook/CMakeLists.txt +++ b/examples/interfaceframework/qface-addressbook/CMakeLists.txt @@ -1,6 +1,10 @@ cmake_minimum_required(VERSION 3.16) project(example_if_addressbook LANGUAGES CXX) +find_package(Qt6 REQUIRED COMPONENTS Core) + +qt_standard_project_setup() + add_subdirectory(frontend) add_subdirectory(backend_simulator) add_subdirectory(demo) diff --git a/examples/interfaceframework/qface-climate/CMakeLists.txt b/examples/interfaceframework/qface-climate/CMakeLists.txt index b4bc0201..25b6ecf3 100644 --- a/examples/interfaceframework/qface-climate/CMakeLists.txt +++ b/examples/interfaceframework/qface-climate/CMakeLists.txt @@ -1,6 +1,10 @@ cmake_minimum_required(VERSION 3.16) project(example_if_climate LANGUAGES CXX) +find_package(Qt6 REQUIRED COMPONENTS Core) + +qt_standard_project_setup() + add_subdirectory(frontend) add_subdirectory(backend_simulator) add_subdirectory(demo) diff --git a/examples/interfaceframework/qface-remote/CMakeLists.txt b/examples/interfaceframework/qface-remote/CMakeLists.txt index f2d42380..fdfa5b84 100644 --- a/examples/interfaceframework/qface-remote/CMakeLists.txt +++ b/examples/interfaceframework/qface-remote/CMakeLists.txt @@ -1,6 +1,10 @@ cmake_minimum_required(VERSION 3.16) project(example_if_remote LANGUAGES CXX) +find_package(Qt6 REQUIRED COMPONENTS Core) + +qt_standard_project_setup() + add_subdirectory(frontend) add_subdirectory(backend_qtro) add_subdirectory(server_qtro) diff --git a/examples/interfaceframework/qface-remote/server_qtro/CMakeLists.txt b/examples/interfaceframework/qface-remote/server_qtro/CMakeLists.txt index 98611d92..d05c359e 100644 --- a/examples/interfaceframework/qface-remote/server_qtro/CMakeLists.txt +++ b/examples/interfaceframework/qface-remote/server_qtro/CMakeLists.txt @@ -9,7 +9,7 @@ if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") endif() -set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-remote-server") +set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-remote") find_package(Qt6 REQUIRED COMPONENTS Core InterfaceFramework Qml Quick) diff --git a/examples/interfaceframework/qface-tutorial/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/CMakeLists.txt index aadbffd1..77dc10ae 100644 --- a/examples/interfaceframework/qface-tutorial/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/CMakeLists.txt @@ -1,6 +1,8 @@ cmake_minimum_required(VERSION 3.16) project(qface-tutorial LANGUAGES CXX) +find_package(Qt6 REQUIRED COMPONENTS Core Gui InterfaceFramework) + add_subdirectory(instrument-cluster) add_subdirectory(ch1-basics) add_subdirectory(ch2-enums-structs) diff --git a/examples/interfaceframework/qface-tutorial/ch1-basics/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch1-basics/CMakeLists.txt index beb48aa0..a657012f 100644 --- a/examples/interfaceframework/qface-tutorial/ch1-basics/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch1-basics/CMakeLists.txt @@ -1,5 +1,9 @@ cmake_minimum_required(VERSION 3.16) project(qface-ch1 LANGUAGES CXX) +find_package(Qt6 REQUIRED COMPONENTS Core) + +qt_standard_project_setup() + add_subdirectory(instrument-cluster) add_subdirectory(frontend) diff --git a/examples/interfaceframework/qface-tutorial/ch2-enums-structs/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch2-enums-structs/CMakeLists.txt index d8c351a1..61f2aada 100644 --- a/examples/interfaceframework/qface-tutorial/ch2-enums-structs/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch2-enums-structs/CMakeLists.txt @@ -1,5 +1,9 @@ cmake_minimum_required(VERSION 3.16) project(qface-ch2 LANGUAGES CXX) +find_package(Qt6 REQUIRED COMPONENTS Core) + +qt_standard_project_setup() + add_subdirectory(instrument-cluster) add_subdirectory(frontend) diff --git a/examples/interfaceframework/qface-tutorial/ch3-simulation-backend/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch3-simulation-backend/CMakeLists.txt index fe490c07..9ca159b1 100644 --- a/examples/interfaceframework/qface-tutorial/ch3-simulation-backend/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch3-simulation-backend/CMakeLists.txt @@ -1,6 +1,10 @@ cmake_minimum_required(VERSION 3.16) project(qface-ch3 LANGUAGES CXX) +find_package(Qt6 REQUIRED COMPONENTS Core) + +qt_standard_project_setup() + add_subdirectory(instrument-cluster) add_subdirectory(frontend) add_subdirectory(backend_simulator) diff --git a/examples/interfaceframework/qface-tutorial/ch3-simulation-backend/backend_simulator/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch3-simulation-backend/backend_simulator/CMakeLists.txt index 193d1560..4c57ec82 100644 --- a/examples/interfaceframework/qface-tutorial/ch3-simulation-backend/backend_simulator/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch3-simulation-backend/backend_simulator/CMakeLists.txt @@ -4,7 +4,7 @@ if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") endif() -set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/ch3-simulation-backend") +set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/ch3-simulation-backend/interfaceframework/") find_package(Qt6 REQUIRED COMPONENTS Core Gui InterfaceFramework) diff --git a/examples/interfaceframework/qface-tutorial/ch3-simulation-backend/imports/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch3-simulation-backend/imports/CMakeLists.txt index fbd3c9c0..ef0b5698 100644 --- a/examples/interfaceframework/qface-tutorial/ch3-simulation-backend/imports/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch3-simulation-backend/imports/CMakeLists.txt @@ -1,4 +1,5 @@ set(CMAKE_AUTOMOC ON) +set(CMAKE_INSTALL_RPATH "$ORIGIN/../../../../") if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") @@ -33,7 +34,10 @@ target_link_libraries(ic_ch3_imports PUBLIC ) install(TARGETS ic_ch3_imports - RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" - BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" - LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" +) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${CLUSTER_URI_PATH}/qmldir + DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" ) diff --git a/examples/interfaceframework/qface-tutorial/ch4-simulation-behavior/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch4-simulation-behavior/CMakeLists.txt index 79e37b1f..cfec24fe 100644 --- a/examples/interfaceframework/qface-tutorial/ch4-simulation-behavior/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch4-simulation-behavior/CMakeLists.txt @@ -1,6 +1,10 @@ cmake_minimum_required(VERSION 3.16) project(qface-ch4 LANGUAGES CXX) +find_package(Qt6 REQUIRED COMPONENTS Core) + +qt_standard_project_setup() + add_subdirectory(instrument-cluster) add_subdirectory(frontend) add_subdirectory(backend_simulator) diff --git a/examples/interfaceframework/qface-tutorial/ch4-simulation-behavior/backend_simulator/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch4-simulation-behavior/backend_simulator/CMakeLists.txt index 3dd4b536..ffb34ff9 100644 --- a/examples/interfaceframework/qface-tutorial/ch4-simulation-behavior/backend_simulator/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch4-simulation-behavior/backend_simulator/CMakeLists.txt @@ -4,7 +4,7 @@ if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") endif() -set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/ch4-simulation-behavior") +set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/ch4-simulation-behavior/interfaceframework/") find_package(Qt6 REQUIRED COMPONENTS Core Gui InterfaceFramework) diff --git a/examples/interfaceframework/qface-tutorial/ch4-simulation-behavior/imports/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch4-simulation-behavior/imports/CMakeLists.txt index 9345963c..427de152 100644 --- a/examples/interfaceframework/qface-tutorial/ch4-simulation-behavior/imports/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch4-simulation-behavior/imports/CMakeLists.txt @@ -1,4 +1,5 @@ set(CMAKE_AUTOMOC ON) +set(CMAKE_INSTALL_RPATH "$ORIGIN/../../../../") if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") @@ -33,7 +34,10 @@ target_link_libraries(ic_ch4_imports PUBLIC ) install(TARGETS ic_ch4_imports - RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" - BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" - LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" +) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${CLUSTER_URI_PATH}/qmldir + DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" ) diff --git a/examples/interfaceframework/qface-tutorial/ch5-ipc/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch5-ipc/CMakeLists.txt index b65b7aa3..e729943f 100644 --- a/examples/interfaceframework/qface-tutorial/ch5-ipc/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch5-ipc/CMakeLists.txt @@ -1,6 +1,10 @@ cmake_minimum_required(VERSION 3.16) project(qface-chapter5 LANGUAGES CXX) +find_package(Qt6 REQUIRED COMPONENTS Core) + +qt_standard_project_setup() + add_subdirectory(instrument-cluster) add_subdirectory(frontend) add_subdirectory(backend_simulator) diff --git a/examples/interfaceframework/qface-tutorial/ch5-ipc/backend_qtro/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch5-ipc/backend_qtro/CMakeLists.txt index a0b6b6b9..6a5cdec9 100644 --- a/examples/interfaceframework/qface-tutorial/ch5-ipc/backend_qtro/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch5-ipc/backend_qtro/CMakeLists.txt @@ -6,7 +6,7 @@ if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") endif() -set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter5-ipc") +set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter5-ipc/interfaceframework/") find_package(Qt6 REQUIRED COMPONENTS Core Gui InterfaceFramework) diff --git a/examples/interfaceframework/qface-tutorial/ch5-ipc/backend_simulator/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch5-ipc/backend_simulator/CMakeLists.txt index 99e1dd8f..073402ef 100644 --- a/examples/interfaceframework/qface-tutorial/ch5-ipc/backend_simulator/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch5-ipc/backend_simulator/CMakeLists.txt @@ -4,7 +4,7 @@ if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") endif() -set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter5-ipc") +set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter5-ipc/interfaceframework/") find_package(Qt6 REQUIRED COMPONENTS Core Gui InterfaceFramework) diff --git a/examples/interfaceframework/qface-tutorial/ch5-ipc/imports/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch5-ipc/imports/CMakeLists.txt index f50c4bc4..5f56f186 100644 --- a/examples/interfaceframework/qface-tutorial/ch5-ipc/imports/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch5-ipc/imports/CMakeLists.txt @@ -1,4 +1,5 @@ set(CMAKE_AUTOMOC ON) +set(CMAKE_INSTALL_RPATH "$ORIGIN/../../../../") if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") @@ -33,7 +34,10 @@ target_link_libraries(ic_chapter5_imports PUBLIC ) install(TARGETS ic_chapter5_imports - RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" - BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" - LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" +) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${CLUSTER_URI_PATH}/qmldir + DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" ) diff --git a/examples/interfaceframework/qface-tutorial/ch5-ipc/simulation_server/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch5-ipc/simulation_server/CMakeLists.txt index 4a91f558..6a2eaa4a 100644 --- a/examples/interfaceframework/qface-tutorial/ch5-ipc/simulation_server/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch5-ipc/simulation_server/CMakeLists.txt @@ -6,7 +6,7 @@ if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") endif() -set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter5-ipc/simulation_server") +set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter5-ipc") find_package(Qt6 REQUIRED COMPONENTS Core InterfaceFramework Quick) diff --git a/examples/interfaceframework/qface-tutorial/ch6-own-backend/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch6-own-backend/CMakeLists.txt index 148d6e8c..58b799b8 100644 --- a/examples/interfaceframework/qface-tutorial/ch6-own-backend/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch6-own-backend/CMakeLists.txt @@ -1,6 +1,10 @@ cmake_minimum_required(VERSION 3.16) project(qface-chapter6 LANGUAGES CXX) +find_package(Qt6 REQUIRED COMPONENTS Core) + +qt_standard_project_setup() + add_subdirectory(instrument-cluster) add_subdirectory(frontend) add_subdirectory(backend_simulator) diff --git a/examples/interfaceframework/qface-tutorial/ch6-own-backend/backend_dbus/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch6-own-backend/backend_dbus/CMakeLists.txt index 24811ade..9bcbd8e9 100644 --- a/examples/interfaceframework/qface-tutorial/ch6-own-backend/backend_dbus/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch6-own-backend/backend_dbus/CMakeLists.txt @@ -6,7 +6,7 @@ if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") endif() -set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter6-own-backend") +set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter6-own-backend/interfaceframework/") find_package(Qt6 REQUIRED COMPONENTS Core DBus Gui InterfaceFramework) diff --git a/examples/interfaceframework/qface-tutorial/ch6-own-backend/backend_simulator/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch6-own-backend/backend_simulator/CMakeLists.txt index 24f37bdb..ec4d1d87 100644 --- a/examples/interfaceframework/qface-tutorial/ch6-own-backend/backend_simulator/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch6-own-backend/backend_simulator/CMakeLists.txt @@ -4,7 +4,7 @@ if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") endif() -set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter6-own-backend") +set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter6-own-backend/interfaceframework/") find_package(Qt6 REQUIRED COMPONENTS Core Gui InterfaceFramework) diff --git a/examples/interfaceframework/qface-tutorial/ch6-own-backend/frontend/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch6-own-backend/frontend/CMakeLists.txt index 9c043134..93c88060 100644 --- a/examples/interfaceframework/qface-tutorial/ch6-own-backend/frontend/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch6-own-backend/frontend/CMakeLists.txt @@ -1,5 +1,3 @@ -cmake_minimum_required(VERSION 3.16) -project(QtIfInstrumentCluster LANGUAGES CXX) set(CMAKE_AUTOMOC ON) diff --git a/examples/interfaceframework/qface-tutorial/ch6-own-backend/imports/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch6-own-backend/imports/CMakeLists.txt index 29f93519..0a074226 100644 --- a/examples/interfaceframework/qface-tutorial/ch6-own-backend/imports/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch6-own-backend/imports/CMakeLists.txt @@ -1,4 +1,5 @@ set(CMAKE_AUTOMOC ON) +set(CMAKE_INSTALL_RPATH "$ORIGIN/../../../../") if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") @@ -33,7 +34,10 @@ target_link_libraries(ic_chapter6_imports PUBLIC ) install(TARGETS ic_chapter6_imports - RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" - BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" - LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" +) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${CLUSTER_URI_PATH}/qmldir + DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" ) diff --git a/examples/interfaceframework/qface-tutorial/ch7-own-template/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch7-own-template/CMakeLists.txt index 4123a5a0..7f201751 100644 --- a/examples/interfaceframework/qface-tutorial/ch7-own-template/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch7-own-template/CMakeLists.txt @@ -1,6 +1,10 @@ cmake_minimum_required(VERSION 3.16) project(qface-chapter7 LANGUAGES CXX) +find_package(Qt6 REQUIRED COMPONENTS Core) + +qt_standard_project_setup() + add_subdirectory(instrument-cluster) add_subdirectory(frontend) add_subdirectory(backend_simulator) diff --git a/examples/interfaceframework/qface-tutorial/ch7-own-template/backend_dbus/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch7-own-template/backend_dbus/CMakeLists.txt index 480f4902..e96d3b3e 100644 --- a/examples/interfaceframework/qface-tutorial/ch7-own-template/backend_dbus/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch7-own-template/backend_dbus/CMakeLists.txt @@ -6,7 +6,7 @@ if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") endif() -set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter7-own-template") +set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter7-own-template/interfaceframework/") find_package(Qt6 REQUIRED COMPONENTS Core DBus Gui InterfaceFramework) diff --git a/examples/interfaceframework/qface-tutorial/ch7-own-template/backend_simulator/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch7-own-template/backend_simulator/CMakeLists.txt index 730c8767..924ce63a 100644 --- a/examples/interfaceframework/qface-tutorial/ch7-own-template/backend_simulator/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch7-own-template/backend_simulator/CMakeLists.txt @@ -4,7 +4,7 @@ if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") endif() -set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter7-own-template") +set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/interfaceframework/qface-tutorial/chapter7-own-template/interfaceframework/") find_package(Qt6 REQUIRED COMPONENTS Core Gui InterfaceFramework) diff --git a/examples/interfaceframework/qface-tutorial/ch7-own-template/imports/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/ch7-own-template/imports/CMakeLists.txt index 9e4f397b..a833ed5b 100644 --- a/examples/interfaceframework/qface-tutorial/ch7-own-template/imports/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/ch7-own-template/imports/CMakeLists.txt @@ -1,4 +1,5 @@ set(CMAKE_AUTOMOC ON) +set(CMAKE_INSTALL_RPATH "$ORIGIN/../../../../") if(NOT DEFINED INSTALL_EXAMPLESDIR) set(INSTALL_EXAMPLESDIR "examples") @@ -33,7 +34,10 @@ target_link_libraries(ic_chapter7_imports PUBLIC ) install(TARGETS ic_chapter7_imports - RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" - BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" - LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" +) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${CLUSTER_URI_PATH}/qmldir + DESTINATION "${INSTALL_EXAMPLEDIR}/${CLUSTER_URI_PATH}" ) diff --git a/examples/interfaceframework/qface-tutorial/instrument-cluster/CMakeLists.txt b/examples/interfaceframework/qface-tutorial/instrument-cluster/CMakeLists.txt index 0fb07825..4d259e18 100644 --- a/examples/interfaceframework/qface-tutorial/instrument-cluster/CMakeLists.txt +++ b/examples/interfaceframework/qface-tutorial/instrument-cluster/CMakeLists.txt @@ -1,6 +1,10 @@ cmake_minimum_required(VERSION 3.16) project(instrument-cluster LANGUAGES CXX) +find_package(Qt6 REQUIRED COMPONENTS Core) + +qt_standard_project_setup() + set(CMAKE_AUTOMOC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) diff --git a/src/3rdparty/qface b/src/3rdparty/qface -Subproject 2459064b0ca85c5fb19cc2a83cc2110be6da4a0 +Subproject c3f6a42e899c1bc1cc3d5343e6151d09d91eea6 diff --git a/src/interfaceframework/CMakeLists.txt b/src/interfaceframework/CMakeLists.txt index 9c23b7af..b90f4a71 100644 --- a/src/interfaceframework/CMakeLists.txt +++ b/src/interfaceframework/CMakeLists.txt @@ -8,6 +8,8 @@ qt_internal_add_qml_module(InterfaceFramework PAST_MAJOR_VERSIONS 1 CLASS_NAME QtInterfaceFrameworkPlugin PLUGIN_TYPES interfaceframework + DEPENDENCIES + QtQuick/auto SOURCES qifabstractfeature.cpp qifabstractfeature.h qifabstractfeature_p.h qifabstractfeaturelistmodel.cpp qifabstractfeaturelistmodel.h qifabstractfeaturelistmodel_p.h @@ -49,6 +51,12 @@ qt_internal_add_qml_module(InterfaceFramework Qt6InterfaceFrameworkMacros.cmake ) +qt_internal_extend_target(InterfaceFramework CONDITION TARGET Qt::QmlModels + PUBLIC_LIBRARIES + Qt::QmlModels +) + + # When the system-qface is used we need to save the location of the used Python3 interpreter in # the module pri file, in order to use from qmake if(QT_FEATURE_system_qface) diff --git a/src/interfaceframework/Qt6InterfaceFrameworkMacros.cmake b/src/interfaceframework/Qt6InterfaceFrameworkMacros.cmake index 45f431a8..f2c8c1c3 100644 --- a/src/interfaceframework/Qt6InterfaceFrameworkMacros.cmake +++ b/src/interfaceframework/Qt6InterfaceFrameworkMacros.cmake @@ -314,16 +314,9 @@ function(qt6_ifcodegen_generate) endif() # Show qface and annotations in IDE - # If the generate function is called directly ${generator_target} is not defined and we will - # fallback to the IDL base name - set(IDE_PREFIX ${generator_target}) - if (NOT IDE_PREFIX) - set(IDE_PREFIX ${IFCODEGEN_BASE_NAME}) - endif() - if (NOT TARGET ${IDE_PREFIX}_qface_files) - add_custom_target(${IDE_PREFIX}_qface_files SOURCES - ${IDE_FILES} - ) + if (TARGET ${generator_target}) + source_group("Ifcodegen Files" FILES ${IDE_FILES}) + target_sources(${generator_target} PRIVATE ${IDE_FILES}) endif() set_property(DIRECTORY APPEND PROPERTY CMAKE_CONFIGURE_DEPENDS ${GEN_DEPENDENCIES}) diff --git a/src/interfaceframework/doc/src/ifcodegen/cmake-macros.qdoc b/src/interfaceframework/doc/src/ifcodegen/cmake-macros.qdoc index a3c1840b..5a11eb02 100644 --- a/src/interfaceframework/doc/src/ifcodegen/cmake-macros.qdoc +++ b/src/interfaceframework/doc/src/ifcodegen/cmake-macros.qdoc @@ -20,7 +20,7 @@ find_package(Qt6 REQUIRED COMPONENTS InterfaceFramework) \ingroup cmake-commands-qtinterfaceframework \title qt_set_ifcodegen_variable -\target qt6_set_ifcodegen_variable +\keyword qt6_set_ifcodegen_variable \summary {Sets the variable to the given value within an ifcodegen template.} @@ -48,7 +48,7 @@ are exported to the current scope when using \ingroup cmake-commands-qtinterfaceframework \title qt_ifcodegen_generate -\target qt6_ifcodegen_generate +\keyword qt6_ifcodegen_generate \summary {Generates files from a qface IDL file.} @@ -115,7 +115,7 @@ For more details on the generator's command line arguments, see \l {Use the Gene \ingroup cmake-commands-qtinterfaceframework \title qt_ifcodegen_extend_target -\target qt6_ifcodegen_extend_target +\keyword qt6_ifcodegen_extend_target \summary {Extends a target with files generated from a qface IDL file.} @@ -167,7 +167,7 @@ For more details on the generator's command line arguments, see \l {Use the Gene \ingroup cmake-commands-qtinterfaceframework \title qt_ifcodegen_import_variables -\target qt6_ifcodegen_import_variables +\keyword qt6_ifcodegen_import_variables \summary {Generates files from a qface IDL file and provides variables for use within CMake.} diff --git a/src/interfaceframework/qifabstractfeature.cpp b/src/interfaceframework/qifabstractfeature.cpp index d5d072ad..45d9b516 100644 --- a/src/interfaceframework/qifabstractfeature.cpp +++ b/src/interfaceframework/qifabstractfeature.cpp @@ -428,6 +428,7 @@ QIfAbstractFeature::DiscoveryResult QIfAbstractFeature::discoveryResult() const /*! \qmlproperty string AbstractFeature::configurationId \brief Holds the id to determine which configuration this feature belongs to. + \since 6.5 Once the id has been set, it is possible to change certain values using the \l InterfaceFrameworkConfiguration API. @@ -441,6 +442,7 @@ QIfAbstractFeature::DiscoveryResult QIfAbstractFeature::discoveryResult() const /*! \property QIfAbstractFeature::configurationId \brief Holds the id to determine which configuration this feature belongs to. + \since 6.5 Once the id has been set, it is possible to change certain values using the \l QIfConfiguration API. @@ -476,6 +478,7 @@ void QIfAbstractFeature::setConfigurationId(const QString &configurationId) /*! \qmlproperty list<string> AbstractFeature::preferredBackends \brief Holds a list of wildcards to load the preferred backend during auto discovery. + \since 6.5 The auto discovery mechanism will automatically search for backends which provide a matching interface for this feature implementation. See \l startAutoDiscovery() for more information. @@ -494,6 +497,7 @@ void QIfAbstractFeature::setConfigurationId(const QString &configurationId) /*! \property QIfAbstractFeature::preferredBackends \brief Holds a list of wildcards to load the preferred backend during auto discovery. + \since 6.5 The auto discovery mechanism will automatically search for backends which provide a matching interface for this feature implementation. See \l startAutoDiscovery() for more information. diff --git a/src/interfaceframework/qifabstractfeaturelistmodel.cpp b/src/interfaceframework/qifabstractfeaturelistmodel.cpp index 861e0d5f..f6470924 100644 --- a/src/interfaceframework/qifabstractfeaturelistmodel.cpp +++ b/src/interfaceframework/qifabstractfeaturelistmodel.cpp @@ -346,6 +346,7 @@ QString QIfAbstractFeatureListModel::errorMessage() const /*! \qmlproperty string AbstractFeatureListModel::configurationId \brief Holds the id to determine which configuration this feature belongs to. + \since 6.5 Once the id has been set, it is possible to change certain values using the \l InterfaceFrameworkConfiguration API. @@ -359,6 +360,7 @@ QString QIfAbstractFeatureListModel::errorMessage() const /*! \property QIfAbstractFeatureListModel::configurationId \brief Holds the id to determine which configuration this feature belongs to. + \since 6.5 Once the id has been set, it is possible to change certain values using the \l QIfConfiguration API. @@ -377,6 +379,7 @@ QString QIfAbstractFeatureListModel::configurationId() const /*! \qmlproperty list<string> AbstractFeatureListModel::preferredBackends \brief Holds a list of wildcards to load the preferred backend during auto discovery. + \since 6.5 The auto discovery mechanism will automatically search for backends which provide a matching interface for this feature implementation. See \l startAutoDiscovery() for more information. @@ -395,6 +398,7 @@ QString QIfAbstractFeatureListModel::configurationId() const /*! \property QIfAbstractFeatureListModel::preferredBackends \brief Holds a list of wildcards to load the preferred backend during auto discovery. + \since 6.5 The auto discovery mechanism will automatically search for backends which provide a matching interface for this feature implementation. See \l startAutoDiscovery() for more information. diff --git a/src/interfaceframework/qifserviceinterface.cpp b/src/interfaceframework/qifserviceinterface.cpp index f2dc1d9c..31fa9fe3 100644 --- a/src/interfaceframework/qifserviceinterface.cpp +++ b/src/interfaceframework/qifserviceinterface.cpp @@ -39,16 +39,30 @@ QIfServiceInterface::~QIfServiceInterface() { } +/*! + Returns the unique ID for the service object instance. + \since 6.5 +*/ QString QIfServiceInterface::id() const { return QString(); } +/*! + Returns the configuration ID for the service object instance. + \since 6.5 + + \sa QIfConfiguration +*/ QString QIfServiceInterface::configurationId() const { return QString(); } +/*! + Updates the service settings with the given \a settings. + \since 6.5 +*/ void QIfServiceInterface::updateServiceSettings(const QVariantMap &settings) { Q_UNUSED(settings); diff --git a/src/interfaceframework/qifserviceobject.cpp b/src/interfaceframework/qifserviceobject.cpp index 8898520d..576c09e9 100644 --- a/src/interfaceframework/qifserviceobject.cpp +++ b/src/interfaceframework/qifserviceobject.cpp @@ -22,7 +22,18 @@ QT_BEGIN_NAMESPACE \sa QIfAbstractFeature */ +/*! + \qmltype ServiceObject + \instantiates QIfServiceObject + \inqmlmodule QtInterfaceFramework + + \brief Provides the connection point to a Backend Service. + ServiceObject provides you with a list of interfaces that the Backend implements. + + From QML the object is mainly used to assign it manually to a AbstractFeature derived object or + to update the service settings. +*/ /*! Constructor. @@ -36,6 +47,12 @@ QIfServiceObject::QIfServiceObject(QObject *parent) } /*! + \qmlproperty string ServiceObject::id + \brief A unique ID for the service object instance. + + Holds the unique ID of the service object +*/ +/*! \property QIfServiceObject::id \brief A unique ID for the service object instance. @@ -44,6 +61,33 @@ QIfServiceObject::QIfServiceObject(QObject *parent) */ /*! + \qmlproperty string ServiceObject::configurationId + \brief Holds the id to determine which configuration this service object belongs to. + \since 6.5 + + Once the id has been set, it is possible to change certain values using the + \l InterfaceFrameworkConfiguration API. + + \note Values set in the matching \l InterfaceFrameworkConfiguration can override the initial + values set during the component creation. + + \sa InterfaceFrameworkConfiguration +*/ +/*! + \property QIfServiceObject::configurationId + \brief Holds the id to determine which configuration this service object belongs to. + \since 6.5 + + Once the id has been set, it is possible to change certain values using the + \l QIfConfiguration API. + + \note Values set in the matching \l QIfConfiguration can override the initial values + set during the component creation. + + \sa QIfConfiguration +*/ + +/*! The id() function can be overloaded to modify how the unique ID is generated, for use by this service object. @@ -58,6 +102,24 @@ QString QIfServiceObject::id() const return m_id; } +/*! + \qmlproperty variant ServiceObject::serviceSettings + \brief The settings for the service object instance. + \since 6.5 + + The serviceSettings property contains a map of settings for the service object instance. + + \sa {Backend specific configuration option} +*/ +/*! + \property QIfServiceObject::serviceSettings + \brief The settings for the service object instance. + \since 6.5 + + The serviceSettings property contains a map of settings for the service object instance. + + \sa {Backend specific configuration option} +*/ const QVariantMap &QIfServiceObject::serviceSettings() const { return m_serviceSettings; diff --git a/src/interfaceframework/qifserviceobject.h b/src/interfaceframework/qifserviceobject.h index f401064e..57389ca3 100644 --- a/src/interfaceframework/qifserviceobject.h +++ b/src/interfaceframework/qifserviceobject.h @@ -15,6 +15,8 @@ QT_BEGIN_NAMESPACE class Q_QTINTERFACEFRAMEWORK_EXPORT QIfServiceObject : public QObject, public QIfServiceInterface { Q_OBJECT + QML_NAMED_ELEMENT(ServiceObject) + QML_UNCREATABLE("ServiceObject needs to be created by IfServiceManager") Q_INTERFACES(QIfServiceInterface) Q_PROPERTY(QString id READ id CONSTANT) @@ -37,6 +39,16 @@ private: QVariantMap m_serviceSettings; }; +namespace qtif_private { + class ServiceObjectListRegistration + { + Q_GADGET + QML_FOREIGN(QList<QIfServiceObject *>) + QML_ANONYMOUS + QML_SEQUENTIAL_CONTAINER(QIfServiceObject *) + }; +} + QT_END_NAMESPACE #endif // QIFSERVICEOBJECT_H diff --git a/src/interfaceframework/qifsimulationproxy.h b/src/interfaceframework/qifsimulationproxy.h index 46964eb5..a04b7d18 100644 --- a/src/interfaceframework/qifsimulationproxy.h +++ b/src/interfaceframework/qifsimulationproxy.h @@ -17,7 +17,8 @@ QT_BEGIN_NAMESPACE Q_DECLARE_LOGGING_CATEGORY(qLcIfSimulationEngine) -Q_QTINTERFACEFRAMEWORK_EXPORT Q_DECLARE_LOGGING_CATEGORY(qLcIfRecGuard) +Q_DECLARE_EXPORTED_LOGGING_CATEGORY(qLcIfRecGuard, + Q_QTINTERFACEFRAMEWORK_EXPORT) class QIfSimulationEngine; diff --git a/src/tools/ifcodegen/CMakeLists.txt b/src/tools/ifcodegen/CMakeLists.txt index f897f717..0ef282eb 100644 --- a/src/tools/ifcodegen/CMakeLists.txt +++ b/src/tools/ifcodegen/CMakeLists.txt @@ -101,7 +101,7 @@ if(QT_FEATURE_python3_virtualenv AND NOT QT_FEATURE_system_qface) add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/.stamp-generator-verified ${CMAKE_CURRENT_BINARY_DIR}/.stamp-cmake-rerun - COMMAND ${VIRTUALENV_PYTHON} ${CMAKE_CURRENT_SOURCE_DIR}/verify_generator.py + COMMAND ${CMAKE_COMMAND} -E env IFGENERATOR_CONFIG=${CMAKE_CURRENT_BINARY_DIR}/.config ${VIRTUALENV_PYTHON} ${CMAKE_CURRENT_SOURCE_DIR}/generate.py --selfcheck COMMAND ${CMAKE_COMMAND} -E touch .stamp-generator-verified COMMAND ${CMAKE_COMMAND} -E touch .stamp-cmake-rerun DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/.stamp-deploy_virtualenv diff --git a/src/tools/ifcodegen/generate.py b/src/tools/ifcodegen/generate.py index ad032438..3681a710 100755 --- a/src/tools/ifcodegen/generate.py +++ b/src/tools/ifcodegen/generate.py @@ -10,7 +10,8 @@ import sys import fnmatch import click import logging.config -from path import Path +import tempfile +from pathlib import Path from qface.generator import FileSystem, Generator from qface.watch import monitor @@ -21,7 +22,7 @@ import generator.global_functions as global_functions from generator.filters import register_filters from generator.rule_generator import CustomRuleGenerator -here = Path(__file__).dirname() +here = Path(__file__).parent log = logging.getLogger(__file__) @@ -161,6 +162,86 @@ def run(template_search_paths, template, moduleConfig, annotations, imports, src exit(1) +def self_check(ctx, param, value): + if not value or ctx.resilient_parsing: + return + click.echo('Running self check') + + try: + # Parse the .config file and throw an error in case it doesn't exist or it is invalid + builtin_config.parse(here) + + tmpDir = tempfile.TemporaryDirectory() + tmp = Path(tmpDir.name) + with open(tmp / "test.qface", 'w') as file: + # Write content to the file + file.write(""" + module org.selftest 1.0 + + interface Echo { + string stringProperty + bool boolProperty + TestEnum enumProperty + TestStruct structProperty + string echo(string msg); + } + + enum TestEnum { + value1, + value2 + } + + struct TestStruct { + int testInt + string testString + } + """) + + with open(tmp / "selfcheck.yaml", 'w') as file: + # Write content to the file + file.write(""" + test: + module: + documents: + - "{{srcBase|lower}}": "module.tpl" + interface: + documents: + - 'tst_{{interface|lower}}': 'interface.tpl' + """) + + os.mkdir(tmp / "selfcheck") + with open(tmp / "selfcheck/module.tpl", 'w') as file: + # Write content to the file + file.write(""" + {{module.name}} + """) + + with open(tmp / "selfcheck/interface.tpl", 'w') as file: + # Write content to the file + file.write(""" + {{interface.name}} + """) + + run([tmp], 'selfcheck', {"module": "org.selftest", "force": True}, [], [], [tmp / "test.qface"], tmp) + click.echo('Self check finished successfully.') + except Exception as e: + raise SystemExit(""" + Self check failed! + + This might be caused by a too recent python version or + too recent python packages. + If this happens when building the qtinterfaceframework, + you can try installing older python packages by + running configure again with the following option: + + -DQT_USE_MINIMAL_QFACE_PACKAGES=TRUE + + The python error was: + + {} + """.format(e)) + ctx.exit() + @click.command() @click.option('--reload/--no-reload', default=False, help= 'Specifies whether the generator should keep track of the changes in the IDL file and update ' @@ -186,6 +267,9 @@ def run(template_search_paths, template, moduleConfig, annotations, imports, src 'scanned recursively for QFace files. The QFace files found are then used to resolve ' 'the information required when importing a module; this is similar to how C++ include ' 'paths work.') +@click.option('--selfcheck', is_flag=True, default=False, callback=self_check, expose_value=False, is_eager=True, help= + 'Runs a self check using a builtin qface file and template to verify that the generator is ' + 'working correctly. ') @click.argument('src', nargs=-1, type=click.Path(exists=True)) @click.argument('dst', nargs=1, type=click.Path(exists=True)) @@ -210,6 +294,5 @@ def app(src, dst, template_search_paths, template, reload, module, force, annota } run(template_search_paths, template, moduleConfig, annotations, imports, src, dst) - if __name__ == '__main__': app() diff --git a/src/tools/ifcodegen/generator/rule_generator.py b/src/tools/ifcodegen/generator/rule_generator.py index f611056d..6b8904ef 100644 --- a/src/tools/ifcodegen/generator/rule_generator.py +++ b/src/tools/ifcodegen/generator/rule_generator.py @@ -7,7 +7,7 @@ import click import logging.config import sys import yaml -from path import Path +from pathlib import Path from qface.utils import load_filters from qface.generator import RuleGenerator diff --git a/src/tools/ifcodegen/templates/backend_qtro/CMakeLists.txt.tpl b/src/tools/ifcodegen/templates/backend_qtro/CMakeLists.txt.tpl index 34a55b5c..f1708049 100644 --- a/src/tools/ifcodegen/templates/backend_qtro/CMakeLists.txt.tpl +++ b/src/tools/ifcodegen/templates/backend_qtro/CMakeLists.txt.tpl @@ -45,5 +45,6 @@ if (TARGET ${CURRENT_TARGET}) target_include_directories(${CURRENT_TARGET} PRIVATE $<BUILD_INTERFACE:${CMAKE_CURRENT_LIST_DIR}> + $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}> ) endif() diff --git a/src/tools/ifcodegen/templates/frontend/struct.h.tpl b/src/tools/ifcodegen/templates/frontend/struct.h.tpl index fff7ba6a..1000f33c 100644 --- a/src/tools/ifcodegen/templates/frontend/struct.h.tpl +++ b/src/tools/ifcodegen/templates/frontend/struct.h.tpl @@ -35,8 +35,8 @@ class {{class}}Private; class {{exportsymbol}} {{class}} : public QIfStandardItem { Q_GADGET - QML_ELEMENT - QML_ANONYMOUS + QML_VALUE_TYPE({{class|lower_first}}) + QML_STRUCTURED_VALUE {% for field in struct.fields %} {{qtif.property(field, notify=false)}} {% endfor %} diff --git a/src/tools/ifcodegen/templates/server_qtro/CMakeLists.txt.tpl b/src/tools/ifcodegen/templates/server_qtro/CMakeLists.txt.tpl index 18b7f5b8..0a1ef29c 100644 --- a/src/tools/ifcodegen/templates/server_qtro/CMakeLists.txt.tpl +++ b/src/tools/ifcodegen/templates/server_qtro/CMakeLists.txt.tpl @@ -37,6 +37,7 @@ if (TARGET ${CURRENT_TARGET}) target_include_directories(${CURRENT_TARGET} PRIVATE $<BUILD_INTERFACE:${CMAKE_CURRENT_LIST_DIR}> + $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}> ) target_link_libraries(${CURRENT_TARGET} PRIVATE diff --git a/src/tools/ifcodegen/templates/server_qtro_simulator/CMakeLists.txt.tpl b/src/tools/ifcodegen/templates/server_qtro_simulator/CMakeLists.txt.tpl index 8718f5cf..282b6a12 100644 --- a/src/tools/ifcodegen/templates/server_qtro_simulator/CMakeLists.txt.tpl +++ b/src/tools/ifcodegen/templates/server_qtro_simulator/CMakeLists.txt.tpl @@ -53,6 +53,7 @@ if (TARGET ${CURRENT_TARGET}) target_include_directories(${CURRENT_TARGET} PRIVATE $<BUILD_INTERFACE:${CMAKE_CURRENT_LIST_DIR}> + $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}> ) target_link_libraries(${CURRENT_TARGET} PRIVATE diff --git a/src/tools/ifcodegen/verify_generator.py b/src/tools/ifcodegen/verify_generator.py deleted file mode 100755 index 0585d68c..00000000 --- a/src/tools/ifcodegen/verify_generator.py +++ /dev/null @@ -1,21 +0,0 @@ -#!/usr/bin/env python3 -# Copyright (C) 2022 The Qt Company Ltd. -# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 - -try: - import generate -except Exception as e: - raise SystemExit(""" - Verifying the generator failed! - - This might be caused by a too recent python version or - too recent python packages. You can try installing older - python packages by running configure again with the the - following option: - - -DQT_USE_MINIMAL_QFACE_PACKAGES=TRUE - - The python error was: - - {} - """.format(e)) |
