diff --git a/playground/CoffeeMachine/CMakeLists.txt b/playground/CoffeeMachine/CMakeLists.txt index 5b357f04a12af50bbd55cb93802b13eecb427bf4..960e6e43a31ccb6930b5a6d167190e1cecc2d30e 100644 --- a/playground/CoffeeMachine/CMakeLists.txt +++ b/playground/CoffeeMachine/CMakeLists.txt @@ -15,7 +15,7 @@ qt_add_qml_module(CoffeeMachine QML_FILES main.qml ) -set(QT_QML_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/qml) +## set(QT_QML_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/qml) add_subdirectory(CoffeeMachineQml) add_subdirectory(imports/CoffeeMachineImport) @@ -25,6 +25,6 @@ target_link_libraries(CoffeeMachine PRIVATE Qt${QT_VERSION_MAJOR}::Gui Qt${QT_VERSION_MAJOR}::Quick Qt${QT_VERSION_MAJOR}::Qml -## CoffeeMachineQml -## CoffeeMachineImport + CoffeeMachineQml + CoffeeMachineImport ) diff --git a/playground/CoffeeMachine/CoffeeMachineQml/CMakeLists.txt b/playground/CoffeeMachine/CoffeeMachineQml/CMakeLists.txt index d00282d9b9a71a1d5b017901563127711a21fd80..decb6e883a69a0d015f2db4355c60e6d9f521207 100644 --- a/playground/CoffeeMachine/CoffeeMachineQml/CMakeLists.txt +++ b/playground/CoffeeMachine/CoffeeMachineQml/CMakeLists.txt @@ -1,7 +1,8 @@ +qt_add_library(CoffeeMachineQml STATIC) qt6_add_qml_module(CoffeeMachineQml URI "CoffeeMachineQml" VERSION 1.0 - PLUGIN_TARGET CoffeeMachineQml + NO_PLUGIN QML_FILES ApplicationFlowForm.ui.qml ApplicationFlow.qml diff --git a/playground/CoffeeMachine/imports/CoffeeMachineImport/CMakeLists.txt b/playground/CoffeeMachine/imports/CoffeeMachineImport/CMakeLists.txt index fd33f0add6f84f6da2887b5164499b06e4c437c7..ecf028a748038fbb0b2ce40fc189895d009928ad 100644 --- a/playground/CoffeeMachine/imports/CoffeeMachineImport/CMakeLists.txt +++ b/playground/CoffeeMachine/imports/CoffeeMachineImport/CMakeLists.txt @@ -1,3 +1,4 @@ +qt_add_library(CoffeeMachineImport STATIC) set_source_files_properties(Constants.qml PROPERTIES QT_QML_SINGLETON_TYPE true @@ -6,7 +7,8 @@ set_source_files_properties(Constants.qml qt6_add_qml_module(CoffeeMachineImport URI "CoffeeMachineImport" VERSION 1.0 - PLUGIN_TARGET CoffeeMachineImport +## PLUGIN_TARGET CoffeeMachineImport + NO_PLUGIN QML_FILES Constants.qml RESOURCES diff --git a/playground/CoffeeMachine/main.cpp b/playground/CoffeeMachine/main.cpp index dc2a9852e8cec9787ecba12bb7bb4d59c2393862..34ef1397edd6290667720c0accb65c999eb06fb1 100644 --- a/playground/CoffeeMachine/main.cpp +++ b/playground/CoffeeMachine/main.cpp @@ -29,6 +29,9 @@ #include <QGuiApplication> #include <QQmlApplicationEngine> +#include <QtQml/qqmlextensionplugin.h> +//Q_IMPORT_QML_PLUGIN(CoffeeMachineQml) +//Q_IMPORT_QML_PLUGIN(CoffeeMachineImport) //does not link int main(int argc, char *argv[]) {