maplibre-native-qt icon indicating copy to clipboard operation
maplibre-native-qt copied to clipboard

Build library for ios on macos with Qt 6.8.1

Open jptcarreira opened this issue 11 months ago • 1 comments

Cmake failed to find component "Gui" from Qt6 This occurs trying to run cmake pointing CMAKE_PREFIX_PATH=~/Qt/6.8.1/ios

This easaly reproduced runing the cmake command cmake ../../maplibre-native-qt -G "Ninja Multi-Config"
-DCMAKE_CONFIGURATION_TYPES="Release;Debug"
-DCMAKE_C_COMPILER_LAUNCHER="ccache"
-DCMAKE_CXX_COMPILER_LAUNCHER="ccache"
-DCMAKE_DEFAULT_CONFIGS="all"
-DCMAKE_INSTALL_PREFIX="../install"
-DCMAKE_OSX_ARCHITECTURES="arm64;x86_64"
-DCMAKE_OSX_DEPLOYMENT_TARGET="14.0" -DCMAKE_PREFIX_PATH=~/Qt/6.8.1/ios --debug-find-pkg=Qt6Gui

Platform information (please complete the following information):

  • OS: macos x86_64 build maplibreqt for iOS
  • Qt version Qt 6.8.1

The output log is: CMake Debug Log at /Users/jcarreira/Qt/6.8.1/ios/lib/cmake/Qt6/Qt6Config.cmake:181 (find_package): /Users/jcarreira/Qt/6.8.1/ios/lib/cmake/Qt6Gui/Qt6GuiConfig.cmake

Call Stack (most recent call first): CMakeLists.txt:59 (find_package)

CMake Error at CMakeLists.txt:59 (find_package): Found package configuration file:

/Users/jcarreira/Qt/6.8.1/ios/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 required Qt component "Gui".

Expected Config file at "/Users/jcarreira/Qt/6.8.1/ios/lib/cmake/Qt6Gui/Qt6GuiConfig.cmake" exists

Configuring with --debug-find-pkg=Qt6Gui might reveal details why the package was not found.

jptcarreira avatar Dec 07 '24 23:12 jptcarreira

Sorry for taking such a long time to get back to you. Did you find a solution in the meantime? The issue is very puzzling as the CI can build with Qt 6.8 fine. Do you use a custom build of Qt?

ntadej avatar Apr 26 '25 08:04 ntadej

Closing this one for now. Please reopen if the issue is still present.

ntadej avatar Aug 14 '25 19:08 ntadej