CMakeLists.txt error
-
Hi,
I don't know if this is covered in another post .... just too many to search through.
When my compiler does the parsing of CMakeLists.txt it gets this error on this lineCMakelists.txt file line::
find_package(Qt${QT_VERSION_MAJOR} COMPONENTS Widgets REQUIRED)On this line it gets the following error::
/extDrv1TB/Qt/projects/test1/CMakeLists.txt:15: error: Found package configuration file: /extDrv1TB/Qt/6.2.1/gcc_64/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 "Widgets". Expected Config file at "/extDrv1TB/Qt/6.2.1/gcc_64/lib/cmake/Qt6Widgets/Qt6WidgetsConfig.cmake" existsThe file "Qt6WidgetsConfig.cmake clearly exists in that directory?? How can it not find it, the permissions are ok as well?
Please help here.
Regards
Frik Brits -
Hi,
I don't know if this is covered in another post .... just too many to search through.
When my compiler does the parsing of CMakeLists.txt it gets this error on this lineCMakelists.txt file line::
find_package(Qt${QT_VERSION_MAJOR} COMPONENTS Widgets REQUIRED)On this line it gets the following error::
/extDrv1TB/Qt/projects/test1/CMakeLists.txt:15: error: Found package configuration file: /extDrv1TB/Qt/6.2.1/gcc_64/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 "Widgets". Expected Config file at "/extDrv1TB/Qt/6.2.1/gcc_64/lib/cmake/Qt6Widgets/Qt6WidgetsConfig.cmake" existsThe file "Qt6WidgetsConfig.cmake clearly exists in that directory?? How can it not find it, the permissions are ok as well?
Please help here.
Regards
Frik Brits@britsfp said in CMakeLists.txt error:
When my compiler does the parsing of CMakeLists.txt
It's not compiler, it's
cmake
.it gets this error on this line
CMakelists.txt file line::
find_package(Qt${QT_VERSION_MAJOR} COMPONENTS Widgets REQUIRED)The line is correct. But is it located below
project()
call? It has to.If not that - maybe your Qt installation is broken? Try reinstalling.