Skip to content

cmake >= 3.31 yields deprecation warning (future breakage) #397

@olifre

Description

@olifre

What happened?

A message like:

CMake Deprecation Warning at CMakeLists.txt:1 (cmake_minimum_required):
Compatibility with CMake < 3.10 will be removed from a future version of
CMake.

Update the VERSION argument value. Or, use the ... syntax
to tell CMake that the project requires at least but has been updated
to work with policies introduced by or earlier.

is shown for the following CMakeLists.txt:

tests/cmake/CMakeLists.txt:3.8
example/traits/CMakeLists.txt:3.8
example/conan/CMakeLists.txt:3.8
example/CMakeLists.txt:3.8

As 3.31 was released about a year ago, it is likely that this support will be removed in an approaching CMake release.

The main CMakeLists.txt already specifies:

cmake_minimum_required(VERSION 3.14)

Would it be fine to synchronize this into the other CMakeLists.txt?
If so, I can of course prepare a PR for this.

How To Reproduce?

Compile with CMake >= 3.31.

Version

0.7.1

What OS are you seeing the problem on?

Linux

What compiler are you seeing the problem on?

GCC

Relevant log output

Code of Conduct

  • I agree to follow this project's Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions