CMake fails if `CMAKE_BUILD_TYPE` is not one of Debug, Release, MinSizeRel, and RelWithDebInfo
As the title states, CMake fails if CMAKE_BUILD_TYPE
is not one of Debug
, Release
, MinSizeRel
, and RelWithDebInfo
. This would normally not be a problem, but file_options
is intended to be included as a subproject using FetchContent
, which means that it could make the parent project fail if it is configured with another CMAKE_BUILD_TYPE
. The solution when this happens is to warn the user and change CMAKE_BUILD_TYPE
to the default one.