CMAKE_HOST_SYSTEM_NAME

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


CMAKE_HOST_SYSTEM_NAME

Name of the OS CMake is running on.

On systems that have the uname command, this variable is set to the output of uname -s. Linux, Windows, and Darwin for macOS are the values found on the big three operating systems.

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