I am exposing my C++ code to Python using pybind11. Let's say I'm doing exactly the example provided by the pybind developers. In the end, I'm building using
python setup.py build
The compiler is invoked with
clang ... -DNDEBUG ... -O3 ... -I... -std=c++14
My question is simple:
How can I, at least temporarily, switch on the assertions in my code? I.e. how can I tell the setuptools to omit the -DNDEBUG
compiler option?