Starting with CMake 3.30 and CMakePresets version 9, the include field supports interesting macro expansions. We can now define platform specific presets in separate files and include them in the top-level CMakePresets.json, while keeping the same preset names across all platforms. This avoids some preset explosion at the cost of some mostly empty json files for each unix platform. The CMake minimum required in the top-level and Lagom CMakeLists.txt have not been adjusted in this patch, as that would have the effect of changing the default policy versions and is a bit out of scope.
62 lines
1.7 KiB
JSON
62 lines
1.7 KiB
JSON
{
|
|
"version": 6,
|
|
"include": [
|
|
"CMakeBasePresets.json"
|
|
],
|
|
"configurePresets": [
|
|
{
|
|
"hidden": true,
|
|
"name": "windows_base",
|
|
"inherits": "base",
|
|
"description": "Visual Studio via Clang/LLVM Toolchain",
|
|
"architecture": {
|
|
"value": "x64",
|
|
"strategy": "external"
|
|
},
|
|
"cacheVariables": {
|
|
"CMAKE_C_COMPILER": "clang-cl",
|
|
"CMAKE_CXX_COMPILER": "clang-cl"
|
|
},
|
|
"vendor": {
|
|
"microsoft.com/VisualStudioSettings/CMake/1.0": {
|
|
"intelliSenseMode": "windows-clang-x64"
|
|
}
|
|
},
|
|
"condition": {
|
|
"type": "equals",
|
|
"lhs": "${hostSystemName}",
|
|
"rhs": "Windows"
|
|
}
|
|
},
|
|
{
|
|
"name": "Release",
|
|
"inherits": [
|
|
"windows_base",
|
|
"Release_base"
|
|
],
|
|
"displayName": "Windows Experimental Release Config",
|
|
"description": "Experimental Windows Release build. Not all targets in this preset are built and there is minimal runtime support"
|
|
},
|
|
{
|
|
"name": "Debug",
|
|
"inherits": [
|
|
"windows_base",
|
|
"Debug_base"
|
|
],
|
|
"displayName": "Windows Experimental Debug Config",
|
|
"description": "Experimental Windows Debug build. Not all targets in this preset are built and there is minimal runtime support"
|
|
},
|
|
{
|
|
"name": "Sanitizer",
|
|
"inherits": [
|
|
"windows_base",
|
|
"Sanitizer_base"
|
|
],
|
|
"displayName": "Windows Experimental Sanitizer Config",
|
|
"description": "Experimental Windows Sanitizer build. Not all targets in this preset are built and there is minimal runtime support",
|
|
"cacheVariables": {
|
|
"CMAKE_BUILD_TYPE": "RelWithDebInfo"
|
|
}
|
|
}
|
|
]
|
|
}
|