Skip to content

Commit

Permalink
cmake: Add dev-mode
Browse files Browse the repository at this point in the history
To use, invoke `cmake` with argument `--preset dev-mode`.

One disadvantage over `./configure --enable-dev-mode` is that CMake
does not provide a way to "hide" presets from users. That is,
`cmake --list-presets` will list dev-mode, and it will also appear
in `cmake-gui`, even though it's not selectable there due to a bug
in cmake-gui.

Solves one item in #1224.
  • Loading branch information
real-or-random committed Mar 10, 2023
1 parent 5658209 commit d121958
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions CMakePresets.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"version": 3,
"configurePresets": [
{
// Don't set "generator" here because developers should still be able to
// select their preferred generators. As a result we're affected by CMake
// bug https://gitlab.kitware.com/cmake/cmake/-/issues/23341, which means
// that dev-mode is not selectable in cmake-gui. But in our case, that's
// probably rather a feature than a bug.
"name": "dev-mode",
"displayName": "Development mode (intended only for developers of the library)",
"cacheVariables": {
"SECP256K1_EXPERIMENTAL": "ON",
"SECP256K1_ENABLE_MODULE_RECOVERY": "ON",
"SECP256K1_BUILD_EXAMPLES": "ON"
},
"warnings": {
"dev": true,
"uninitialized": true
}
}
]
}

0 comments on commit d121958

Please sign in to comment.