Version: unspecified (using Devel) OS: Linux This is related to http://public.kitware.com/Bug/view.php?id=12352, it seems then specify QT_MIN_VERSION without setting the corresponding version in find_package, only Qt4_FIND_VERSION is set by cmake, while Qt4_FIND_VERSION_MAJOR/_MINOR/_PATCH are null(at least this is true with cmake 2.8.5). Then req_qt_major_vers and friends are set to null before FindQt4 check the version number, causing error messages like this: CMake Error at /usr/local/kde4/share/apps/cmake/modules/FindQt4.cmake:517 (MESSAGE): Invalid Qt version string given: "4.5.0", major version 4 is required, e.g. "4.0.1" The problem manifest itself when the program try to have optional kde support, e.g. try to find Qt first then find KDE, if the program only check qt or check kde the bug does not affect them. Reproducible: Didn't try Steps to Reproduce: Run cmake with the following CMakeLists.txt: cmake_minimum_required(VERSION 2.6.2 FATAL_ERROR) set(QT_MIN_VERSION "4.5.0") find_package(Qt4 REQUIRED) find_package(KDE4) Actual Results: Get error message: CMake Error at /usr/local/kde4/share/apps/cmake/modules/FindQt4.cmake:517 (MESSAGE): Invalid Qt version string given: "4.5.0", major version 4 is required, e.g. "4.0.1" Expected Results: CMake finishes without an error.
Thank you for the bug report. As this report hasn't seen any changes in 5 years or more, we ask if you can please confirm that the issue still persists. If this bug is no longer persisting or relevant please change the status to resolved.