Skip to content

Commit

Permalink
build(CMake): Add basic CMake presets for MSVC
Browse files Browse the repository at this point in the history
  • Loading branch information
BurningEnlightenment committed Jul 2, 2024
1 parent d72f2db commit 7842314
Show file tree
Hide file tree
Showing 2 changed files with 75 additions and 0 deletions.
2 changes: 2 additions & 0 deletions c/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,5 @@ blake3
example
build/
*.o

CMakeUserPresets.json
73 changes: 73 additions & 0 deletions c/CMakePresets.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
{
"version": 3,
"cmakeMinimumRequired": {
"major": 3,
"minor": 22,
"patch": 0
},
"configurePresets": [
{
"name": "base",
"hidden": true,
"binaryDir": "${sourceDir}/build/${presetName}"
},
{
"name": "msvc",
"hidden": true,
"generator": "Visual Studio 17 2022",
"vendor": {
"microsoft.com/VisualStudioSettings/CMake/1.0": {
"hostOS": [
"Windows"
]
}
}
},
{
"name": "x64-windows-msvc",
"inherits": [
"msvc",
"base"
],
"architecture": "x64"
},
{
"name": "x86-windows-msvc",
"inherits": [
"msvc",
"base"
],
"architecture": "Win32"
},
{
"name": "arm64-windows-msvc",
"inherits": [
"msvc",
"base"
],
"architecture": "ARM64"
}
],
"buildPresets": [
{
"name": "x64-windows-msvc-debug",
"configurePreset": "x64-windows-msvc",
"configuration": "Debug"
},
{
"name": "x64-windows-msvc-release",
"configurePreset": "x64-windows-msvc",
"configuration": "RelWithDebInfo"
},
{
"name": "x86-windows-msvc-debug",
"configurePreset": "x86-windows-msvc",
"configuration": "Debug"
},
{
"name": "x86-windows-msvc-release",
"configurePreset": "x86-windows-msvc",
"configuration": "RelWithDebInfo"
}
]
}

0 comments on commit 7842314

Please sign in to comment.