Dear QGIS Developers, I am currently trying to create a C++ plugin for QGIS using CMake on Windows, but I’m facing issues during the build process.
When I configure my project with CMake, I receive the following error: > Could not find a package configuration file provided by "QGIS" with any of the following names: > QGISConfig.cmake > qgis-config.cmake > > Add the installation prefix of "QGIS" to CMAKE_PREFIX_PATH or set "QGIS_DIR" to a directory containing one of the above files. > If "QGIS" provides a separate development package or SDK, be sure it has been installed. I have installed QGIS 3.44.2 through the OSGeo4W Advanced Install option, and I’ve made sure to select and install the following packages: - qgis - qgis-deps - qgis-common - qgis-devel Since my plugin uses Qt, I’ve also installed: - qt5-devel - qt5-libs - qt5-tools - qt5-libs-symbols Despite this, I’m unable to locate the `QGISConfig.cmake` or `qgis-config.cmake` file in the installation directories (checked under `C:\OSGeo4W\apps\qgis\lib\cmake` and other subfolders). Additionally, while these packages were installed via OSGeo4W, I also noticed that **CMake itself is not available or detected in the environment**, even though it’s listed as an installable component. Could you please guide me on how to properly set up the build environment for a C++ QGIS plugin, and how to make CMake recognize the QGIS development files? If there is a specific way to enable or locate the `QGISConfig.cmake` file within the OSGeo4W setup, I would really appreciate your advice. Thank you very much for your time and assistance. Best regards, Mutukula Chaitanya Kumar Hyderabad, India
_______________________________________________ QGIS-Developer mailing list [email protected] List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
