added cmake presets
This commit is contained in:
parent
9669d4bba5
commit
bc9d138960
2 changed files with 86 additions and 4 deletions
|
@ -5,10 +5,10 @@ set(CMAKE_C_STANDARD 99)
|
|||
set(CMAKE_C_STANDARD_REQUIRED True)
|
||||
string(JOIN " " CMAKE_C_FLAGS
|
||||
"-Wall -Wextra -Wformat=2"
|
||||
"-Wconversion -Wsign-conversion -Wimplicit-fallthrough"
|
||||
"-Werror=implicit"
|
||||
"-Werror=incompatible-pointer-types"
|
||||
"-Werror=int-conversion")
|
||||
"-Wconversion -Wsign-conversion -Wimplicit-fallthrough"
|
||||
"-Werror=implicit"
|
||||
"-Werror=incompatible-pointer-types"
|
||||
"-Werror=int-conversion")
|
||||
set(CMAKE_VERBOSE_MAKEFILE ON)
|
||||
|
||||
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
|
||||
|
|
82
CMakePresets.json
Normal file
82
CMakePresets.json
Normal file
|
@ -0,0 +1,82 @@
|
|||
{
|
||||
"version": 10,
|
||||
"cmakeMinimumRequired": {
|
||||
"major": 3,
|
||||
"minor": 31,
|
||||
"patch": 0
|
||||
},
|
||||
"configurePresets": [
|
||||
{
|
||||
"name": "debug",
|
||||
"displayName": "Debug",
|
||||
"description": "Debug config",
|
||||
"generator": "Unix Makefiles",
|
||||
"binaryDir": "${sourceDir}/build-${presetName}/",
|
||||
"cacheVariables": {
|
||||
"CMAKE_BUILD_TYPE": "Debug"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "release",
|
||||
"displayName": "Release",
|
||||
"description": "Release config",
|
||||
"generator": "Unix Makefiles",
|
||||
"binaryDir": "${sourceDir}/build-${presetName}/",
|
||||
"cacheVariables": {
|
||||
"CMAKE_BUILD_TYPE": "Release"
|
||||
}
|
||||
}
|
||||
],
|
||||
"buildPresets": [
|
||||
{
|
||||
"name": "debug",
|
||||
"configurePreset": "debug"
|
||||
},
|
||||
{
|
||||
"name": "release",
|
||||
"configurePreset": "release"
|
||||
}
|
||||
],
|
||||
"$comment": [{
|
||||
"testPresets": [
|
||||
{
|
||||
"name": "default",
|
||||
"configurePreset": "default",
|
||||
"output": {"outputOnFailure": true},
|
||||
"execution": {"noTestsAction": "error", "stopOnFailure": true}
|
||||
}
|
||||
],
|
||||
"packagePresets": [
|
||||
{
|
||||
"name": "default",
|
||||
"configurePreset": "default",
|
||||
"generators": [
|
||||
"TGZ"
|
||||
]
|
||||
}
|
||||
],
|
||||
"workflowPresets": [
|
||||
{
|
||||
"name": "default",
|
||||
"steps": [
|
||||
{
|
||||
"type": "configure",
|
||||
"name": "default"
|
||||
},
|
||||
{
|
||||
"type": "build",
|
||||
"name": "default"
|
||||
},
|
||||
{
|
||||
"type": "test",
|
||||
"name": "default"
|
||||
},
|
||||
{
|
||||
"type": "package",
|
||||
"name": "default"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}]
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue