diff options
| author | Jouke Witteveen <j.witteveen@gmail.com> | 2024-04-12 19:44:17 +0200 |
|---|---|---|
| committer | Dylan Baker <dylan@pnwbakers.com> | 2024-04-24 08:35:23 -0700 |
| commit | 8e9be88f6967465473d4fdc9c32a046bbfb60daa (patch) | |
| tree | ab483e4d1e3a69480f7e1fb468756e6fff50fae7 /docs/markdown | |
| parent | 7a6b7ba14776f937149180330d080882627fd7e9 (diff) | |
| download | meson-8e9be88f6967465473d4fdc9c32a046bbfb60daa.tar.gz | |
docs: Add CMake build type release note snippet
Diffstat (limited to 'docs/markdown')
| -rw-r--r-- | docs/markdown/snippets/cmake_build_type.md | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/docs/markdown/snippets/cmake_build_type.md b/docs/markdown/snippets/cmake_build_type.md new file mode 100644 index 000000000..af9e84dc8 --- /dev/null +++ b/docs/markdown/snippets/cmake_build_type.md @@ -0,0 +1,15 @@ +## Meson now propagates its build type to CMake + +When the CMake build type variable, `CMAKE_BUILD_TYPE`, is not set via the +`add_cmake_defines` method of the [`cmake options` object](CMake-module.md#cmake-options-object), +it is inferred from the [Meson build type](Builtin-options.md#details-for-buildtype). +Build types of the two build systems do not match perfectly. The mapping from +Meson build type to CMake build type is as follows: + +- `debug` -> `Debug` +- `debugoptimized` -> `RelWithDebInfo` +- `release` -> `Release` +- `minsize` -> `MinSizeRel` + +No CMake build type is set for the `plain` Meson build type. The inferred CMake +build type overrides any `CMAKE_BUILD_TYPE` environment variable. |
