Qt6Gui could not be found
Solved
General and Desktop
-
Hi,
it is a fresh QtCreator installation on Kubuntu 23.10. I guess that I need to set up some environment variables, but I am not sure what and where./home/.../Qt/6.6.1/gcc_64/lib/cmake/Qt6Gui/Qt6GuiConfig.cmake but it set Qt6Gui_FOUND to FALSE so package "Qt6Gui" is considered to be NOT FOUND. Reason given by package: Qt6Gui could not be found because dependency WrapOpenGL could not be found. Configuring with --debug-find-pkg=WrapOpenGL might reveal details why the package was not found. Configuring with -DQT_DEBUG_FIND_PACKAGE=ON will print the values of some of the path variables that find_package uses to try and find the package. Stos wywołań: /home/.../test/CMakeLists.txt:9 (find_package) /home/.../Programy/Qt/6.6.1/gcc_64/lib/cmake/Qt6/Qt6Config.cmake:156 (find_package) /home/.../Programy/Qt/6.6.1/gcc_64/lib/cmake/Qt6Quick/Qt6QuickConfig.cmake:40 (include) /home/.../Programy/Qt/6.6.1/gcc_64/lib/cmake/Qt6Quick/Qt6QuickDependencies.cmake:39 (_qt_internal_find_qt_dependencies) /home/.../Programy/Qt/6.6.1/gcc_64/lib/cmake/Qt6/QtPublicDependencyHelpers.cmake:111 (find_dependency) /home/.../Programy/Qt/Tools/CMake/share/cmake-3.27/Modules/CMakeFindDependencyMacro.cmake:76 (find_package)
-
@Rocky-Plantchair are you including OpenGL in your project?
For that matter, do you have OpenGL installed?
-
@Rocky-Plantchair I took a closer look at the documentation (should have done this before posting) -- evidently, Qt wants you to use the Qt GUI module instead.
Does your CMakeLists.txt file have entries like these?
find_package(Qt6 REQUIRED COMPONENTS Gui) target_link_libraries(mytarget PRIVATE Qt6::Gui)
-
@Rocky-Plantchair glad to hear it. You might want to mark your topic as solved.
-