Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt for WebAssembly
  4. Qt WebAssembly 6.2 - compiling an app using qmake
QtWS25 Last Chance

Qt WebAssembly 6.2 - compiling an app using qmake

Scheduled Pinned Locked Moved Unsolved Qt for WebAssembly
1 Posts 1 Posters 365 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    just_a_developer
    wrote on last edited by
    #1

    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.

    1 Reply Last reply
    1

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved