Description
In meson-python we pass some opinionated options to meson setup
to tailor the project configuration to the users expectations when building a Python package. Among other things, we pass the -Db_ndebug=if-release
options. AFAIU, b_ndebug
is not recognized as a valid option when project()
does not specify at least one language or one is added with add_languages()
.
There may be good reasons for this change. However, in meson-python we want to be able to keep passing the -Db_ndebug
option. Is there is a way to know before hand if it is a valid option?
Funny enough, if the project is configured without the -Db_ndebug
option, and then reconfigured with it, the option is recognized as valid regardless of the project configuring a language or not.
$ meson setup build/ -Db_ndebug=if-release
The Meson build system
Version: 1.7.99
[...]
meson-python undefined
User defined options
b_ndebug: if-release
ERROR: Unknown options: "b_ndebug"
A full log can be found at /Users/daniele/src/meson-python/build/meson-logs/meson-log.txt
$ meson setup build/
The Meson build system
Version: 1.7.99
[...]
Found ninja-1.12.1 at /usr/local/bin/ninja
$ meson setup build/ --reconfigure -Db_ndebug=if-release
The Meson build system
Version: 1.7.99
[...]
meson-python undefined
User defined options
b_ndebug: if-release
Found ninja-1.12.1 at /usr/local/bin/ninja
$