In the man page for add_compile_options()
I don't see any mention of how to modify the Release/Debug compiler flags. Can you use add_compiler_options()
to modify the Release/Debug compiler flags? If yes, how?
If no, is the recommended canonical method to modify the release/debug cmake variables[1] as described here ?
[1] i.e. set the cmake variables CMAKE_<LANG>_FLAGS_<TYPE> (for lang c/c++ it would be: CMAKE_CXX_FLAGS_RELEASE, CMAKE_CXX_FLAGS_DEBUG, CMAKE_C_FLAGS_RELEASE, CMAKE_C_FLAGS_DEBUG).