forked from britown88/scratch
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add some CMake presets and fix Github Actions workflows
- Loading branch information
1 parent
6a1dc59
commit b287b1d
Showing
3 changed files
with
186 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,151 @@ | ||
{ | ||
"version": 3, | ||
"cmakeMinimumRequired": { | ||
"major": 3, | ||
"minor": 21, | ||
"patch": 0 | ||
}, | ||
"configurePresets": [ | ||
{ | ||
"name": "conf-common", | ||
"description": "General settings that apply to all configurations", | ||
"hidden": true, | ||
"generator": "Ninja", | ||
"binaryDir": "${sourceDir}/out/build/${presetName}", | ||
"installDir": "${sourceDir}/out/install/${presetName}" | ||
}, | ||
{ | ||
"name": "conf-windows-common", | ||
"description": "Windows settings for MSBuild toolchain that apply to msvc and clang", | ||
"hidden": true, | ||
"inherits": "conf-common", | ||
"condition": { | ||
"type": "equals", | ||
"lhs": "${hostSystemName}", | ||
"rhs": "Windows" | ||
}, | ||
"architecture": { | ||
"value": "x64", | ||
"strategy": "external" | ||
}, | ||
"toolset": { | ||
"value": "host=x64", | ||
"strategy": "external" | ||
} | ||
}, | ||
{ | ||
"name": "conf-unixlike-common", | ||
"description": "Unix-like OS settings for gcc and clang toolchains", | ||
"hidden": true, | ||
"inherits": "conf-common", | ||
"condition": { | ||
"type": "inList", | ||
"string": "${hostSystemName}", | ||
"list": ["Linux", "Darwin"] | ||
}, | ||
"vendor": { | ||
"microsoft.com/VisualStudioRemoteSettings/CMake/1.0": { | ||
"sourceDir": "$env{HOME}/.vs/$ms{projectDirName}" | ||
} | ||
} | ||
}, | ||
{ | ||
"name": "windows-cl-release", | ||
"displayName": "msvc Release", | ||
"description": "Target Windows with the msvc compiler, release build type", | ||
"inherits": "conf-windows-common", | ||
"cacheVariables": { | ||
"CMAKE_C_COMPILER": "cl", | ||
"CMAKE_CXX_COMPILER": "cl", | ||
"CMAKE_BUILD_TYPE": "RelWithDebInfo" | ||
} | ||
}, | ||
{ | ||
"name": "windows-cl-debug", | ||
"displayName": "msvc Debug", | ||
"description": "Target Windows with the msvc compiler, debug build type", | ||
"inherits": "conf-windows-common", | ||
"cacheVariables": { | ||
"CMAKE_C_COMPILER": "cl", | ||
"CMAKE_CXX_COMPILER": "cl", | ||
"CMAKE_BUILD_TYPE": "Debug" | ||
} | ||
}, | ||
{ | ||
"name": "windows-clang-debug", | ||
"displayName": "clang Debug", | ||
"description": "Target Windows with the clang compiler, debug build type", | ||
"inherits": "conf-windows-common", | ||
"cacheVariables": { | ||
"CMAKE_C_COMPILER": "clang-cl", | ||
"CMAKE_CXX_COMPILER": "clang-cl", | ||
"CMAKE_BUILD_TYPE": "Debug" | ||
}, | ||
"vendor": { | ||
"microsoft.com/VisualStudioSettings/CMake/1.0": { | ||
"intelliSenseMode": "windows-clang-x64" | ||
} | ||
} | ||
}, | ||
{ | ||
"name": "windows-clang-release", | ||
"displayName": "clang Release", | ||
"description": "Target Windows with the clang compiler, release build type", | ||
"inherits": "conf-windows-common", | ||
"cacheVariables": { | ||
"CMAKE_C_COMPILER": "clang-cl", | ||
"CMAKE_CXX_COMPILER": "clang-cl", | ||
"CMAKE_BUILD_TYPE": "RelWithDebInfo" | ||
}, | ||
"vendor": { | ||
"microsoft.com/VisualStudioSettings/CMake/1.0": { | ||
"intelliSenseMode": "windows-clang-x64" | ||
} | ||
} | ||
}, | ||
{ | ||
"name": "unixlike-gcc-debug", | ||
"displayName": "gcc Debug", | ||
"description": "Target Unix-like OS with the gcc compiler, debug build type", | ||
"inherits": "conf-unixlike-common", | ||
"cacheVariables": { | ||
"CMAKE_C_COMPILER": "gcc", | ||
"CMAKE_CXX_COMPILER": "g++", | ||
"CMAKE_BUILD_TYPE": "Debug" | ||
} | ||
}, | ||
{ | ||
"name": "unixlike-gcc-release", | ||
"displayName": "gcc Release", | ||
"description": "Target Unix-like OS with the gcc compiler, release build type", | ||
"inherits": "conf-unixlike-common", | ||
"cacheVariables": { | ||
"CMAKE_C_COMPILER": "gcc", | ||
"CMAKE_CXX_COMPILER": "g++", | ||
"CMAKE_BUILD_TYPE": "RelWithDebInfo" | ||
} | ||
}, | ||
{ | ||
"name": "unixlike-clang-debug", | ||
"displayName": "clang Debug", | ||
"description": "Target Unix-like OS with the clang compiler, debug build type", | ||
"inherits": "conf-unixlike-common", | ||
"cacheVariables": { | ||
"CMAKE_C_COMPILER": "clang", | ||
"CMAKE_CXX_COMPILER": "clang++", | ||
"CMAKE_BUILD_TYPE": "Debug" | ||
} | ||
}, | ||
{ | ||
"name": "unixlike-clang-release", | ||
"displayName": "clang Release", | ||
"description": "Target Unix-like OS with the clang compiler, release build type", | ||
"inherits": "conf-unixlike-common", | ||
"cacheVariables": { | ||
"CMAKE_C_COMPILER": "clang", | ||
"CMAKE_CXX_COMPILER": "clang++", | ||
"CMAKE_BUILD_TYPE": "RelWithDebInfo" | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters