CMAKE_HOST_SYSTEM_VERSION

From Get docs
Cmake/docs/3.21/variable/cmake host system version


CMAKE_HOST_SYSTEM_VERSION

The OS version CMake is running on.

A numeric version string for the system. On systems that support uname, this variable is set to the output of uname -r. On other systems this is set to major-minor version numbers.

© 2000–2021 Kitware, Inc. and Contributors
Licensed under the BSD 3-clause License.
https://cmake.org/cmake/help/v3.21/variable/CMAKE_HOST_SYSTEM_VERSION.html