Qt WebAssembly 6.2 - compiling an app using qmake
Unsolved
Qt for WebAssembly
-
Hello,
I am trying to compile a Qt app for WebAssembly with Qt version 6.2 using CMake.
Quote from CMakeLists.txt :
message("CMAKE_PREFIX_PATH : ${CMAKE_PREFIX_PATH}") find_package(Qt6 REQUIRED COMPONENTS Core Gui Quick )
It fails with this error :
CMAKE_PREFIX_PATH : /Users/myUsername/Qt/6.2.0/wasm_32/lib/cmake;/Users/myUsername/Qt/6.2.0/wasm_32 ... CMake Warning at /usr/local/Cellar/cmake/3.21.3/share/cmake/Modules/CMakeFindDependencyMacro.cmake:47 (find_package): Found package configuration file: /Users/myUsername/Qt/6.2.0/wasm_32/lib/cmake/Qt6Qml/Qt6QmlConfig.cmake but it set Qt6Qml_FOUND to FALSE so package "Qt6Qml" is considered to be NOT FOUND. Reason given by package: The following imported targets are referenced, but are missing: Qt6::qtquicktemplates2plugin Call Stack (most recent call first): /Users/myUsername/Qt/6.2.0/wasm_32/lib/cmake/Qt6/QtPublicDependencyHelpers.cmake:14 (find_dependency) /Users/myUsername/Qt/6.2.0/wasm_32/lib/cmake/Qt6Quick/Qt6QuickDependencies.cmake:91 (_qt_internal_find_dependencies) /Users/myUsername/Qt/6.2.0/wasm_32/lib/cmake/Qt6Quick/Qt6QuickConfig.cmake:40 (include) /Users/myUsername/Qt/6.2.0/wasm_32/lib/cmake/Qt6/Qt6Config.cmake:176 (find_package) CMakeLists.txt:31 (find_package) CMake Warning at /Users/myUsername/Qt/6.2.0/wasm_32/lib/cmake/Qt6/Qt6Config.cmake:176 (find_package): Found package configuration file: /Users/myUsername/Qt/6.2.0/wasm_32/lib/cmake/Qt6Quick/Qt6QuickConfig.cmake but it set Qt6Quick_FOUND to FALSE so package "Qt6Quick" is considered to be NOT FOUND. Reason given by package: Qt6Quick could not be found because dependency Qt6Qml could not be found. Call Stack (most recent call first): CMakeLists.txt:31 (find_package) CMake Error at CMakeLists.txt:31 (find_package): Found package configuration file: /Users/myUsername/Qt/6.2.0/wasm_32/lib/cmake/Qt6/Qt6Config.cmake but it set Qt6_FOUND to FALSE so package "Qt6" is considered to be NOT FOUND. Reason given by package: Failed to find Qt component "Quick". Expected Config file at "/Users/myUsername/Qt/6.2.0/wasm_32/lib/cmake/Qt6Quick/Qt6QuickConfig.cmake" exists -- Configuring incomplete, errors occurred!
Is building for WebAssembly using CMake supported by Qt 6.2?
Side note : building with qmake is working fine.