cmakeme_defaults

Basic helper functions providing some useful generic cmake features

Use this module with find_package(cmakeme)

Commands

cmakeme_defaults

Sets up all of the default settings from cmakeme: 1. Sets a default build type (single-configuration generators, and is user-overridable with -DCMAKE_BUILD_TYPE=) 2. Disables in-source builds (prevent accidentally polluting the source space) 3. Disables language extensions

cmakeme_defaults(type)

type The build type to set as the default type. (Release, Debug, RelWithDebInfo, MinSizeRel, or “”)

cmakeme_set_default_build_type

Set a default build type if not specified and store it in the cache. The default type specified the developer can still be overriden by a user when they generate the build system.

cmakeme_set_default_build_type(type)

type The build type to set as the default type (Release, Debug, RelWithDebInfo, MinSizeRel, or “”)

cmakeme_disable_in_source_builds

Disable in-source builds of the project so that it is an error to configure a project from within the source directory. This feature presents litering the source code directory with CMake files; however, you will need to manually delete CMakeFiles and CMakeCache.txt should you try an in-source build.

cmakeme_disable_in_source_builds()
cmakeme_no_lang_extensions

Disable c/c++ language extensions globally

cmakeme_no_lang_extensions