CMake package configuration version check is too strict
sergiud opened this issue · comments
While updating from argparse 3.0 to 3.1 I encountered the following problem:
CMake Error at CMakeLists.txt:11 (find_package):
Could not find a configuration file for package "argparse" that is
compatible with requested version "3.0.0".
The following configuration files were considered but not accepted:
/usr/lib/cmake/argparse/argparseConfig.cmake, version: 3.1.0
/lib/cmake/argparse/argparseConfig.cmake, version: 3.1.0
Is it intentional that minor versions are considered incompatible between each other? If not, this code
Lines 57 to 60 in 68fd027
should be updated to use either AnyNewerVersion
or SameMajorVersion
instead of ExactVersion
as the COMPATIBILITY
argument.
Is it intentional that minor versions are considered incompatible between each other?
No, this is not intentional. Agreed, should be fixed.