Skip to content

Instantly share code, notes, and snippets.

@KrystalDelusion
Created July 23, 2026 21:07
Show Gist options
  • Select an option

  • Save KrystalDelusion/65b617d6fb875424444a4a3a0ea0d093 to your computer and use it in GitHub Desktop.

Select an option

Save KrystalDelusion/65b617d6fb875424444a4a3a0ea0d093 to your computer and use it in GitHub Desktop.
Yosys CMake presets
{
"version": 10,
"configurePresets": [
{
"$comment": "call with cmake --preset clang",
"name": "clang",
"binaryDir": "build",
"generator": "Unix Makefiles",
"cacheVariables": {
"CMAKE_C_COMPILER": "clang",
"CMAKE_CXX_COMPILER": "clang++",
"CMAKE_INTERPROCEDURAL_OPTIMIZATION": "ON",
"YOSYS_COMPILER_LAUNCHER": "ccache"
}
},
{
"name": "ninja",
"inherits": "clang",
"generator": "Ninja"
}
],
"buildPresets": [
{
"name": "default",
"configurePreset": "clang",
"jobs": 12
},
{
"$comment": "call with cmake --build --preset clean",
"name": "clean",
"inherits": "default",
"cleanFirst": true
},
{
"name": "bisect",
"inherits": "default",
"targets": "docs-prepare",
"cleanFirst": false
},
{
"name": "html",
"inherits": "default",
"targets": "docs-html",
"cleanFirst": false
}
],
"workflowPresets": [
{
"$comment": "call with cmake --workflow --preset build",
"name": "build",
"steps": [
{
"type": "configure",
"name": "clang"
},
{
"type": "build",
"name": "clean"
}
]
},
{
"name": "bisect",
"steps": [
{
"type": "configure",
"name": "clang"
},
{
"type": "build",
"name": "bisect"
}
]
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment