Skip to content

Commit

Permalink
feat: add presets
Browse files Browse the repository at this point in the history
  • Loading branch information
f0e committed Nov 4, 2024
1 parent 1df0223 commit 62c40f5
Showing 1 changed file with 111 additions and 11 deletions.
122 changes: 111 additions & 11 deletions CMakePresets.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,113 @@
{
"version": 2,
"configurePresets": [
{
"name": "vcpkg",
"generator": "Ninja",
"binaryDir": "${sourceDir}/build",
"cacheVariables": {
"CMAKE_TOOLCHAIN_FILE": "$env{VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake"
}
}
]
"version": 6,
"configurePresets": [
{
"name": "base",
"hidden": true,
"cacheVariables": {
"CMAKE_TOOLCHAIN_FILE": "$env{VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake"
}
},
{
"name": "windows-base",
"inherits": "base",
"hidden": true,
"condition": {
"type": "equals",
"lhs": "${hostSystemName}",
"rhs": "Windows"
},
"generator": "Ninja",
"architecture": {
"value": "x64",
"strategy": "external"
},
"cacheVariables": {
"CMAKE_C_COMPILER": "cl",
"CMAKE_CXX_COMPILER": "cl"
},
"vendor": {
"microsoft.com/VisualStudioSettings/CMake/1.0": {
"intelliSenseMode": "windows-msvc-x64"
}
}
},
{
"name": "unix-base",
"inherits": "base",
"hidden": true,
"condition": {
"type": "notEquals",
"lhs": "${hostSystemName}",
"rhs": "Windows"
},
"generator": "Ninja"
},
{
"name": "debug",
"inherits": [
"windows-base",
"unix-base"
],
"displayName": "Debug Build",
"binaryDir": "${sourceDir}/build/debug",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Debug",
"CMAKE_EXPORT_COMPILE_COMMANDS": "ON",
"CMAKE_MSVC_RUNTIME_LIBRARY": {
"type": "STRING",
"value": "MultiThreadedDebugDLL"
}
}
},
{
"name": "release",
"inherits": [
"windows-base",
"unix-base"
],
"displayName": "Release Build",
"binaryDir": "${sourceDir}/build/release",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Release",
"CMAKE_MSVC_RUNTIME_LIBRARY": {
"type": "STRING",
"value": "MultiThreadedDLL"
}
}
},
{
"name": "relwithdebinfo",
"inherits": [
"windows-base",
"unix-base"
],
"displayName": "Release with Debug Info",
"binaryDir": "${sourceDir}/build/relwithdebinfo",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "RelWithDebInfo",
"CMAKE_MSVC_RUNTIME_LIBRARY": {
"type": "STRING",
"value": "MultiThreadedDLL"
}
}
}
],
"buildPresets": [
{
"name": "debug",
"configurePreset": "debug",
"jobs": 0
},
{
"name": "release",
"configurePreset": "release",
"jobs": 0
},
{
"name": "relwithdebinfo",
"configurePreset": "relwithdebinfo",
"jobs": 0
}
]
}

0 comments on commit 62c40f5

Please sign in to comment.