diff options
| author | Chun Kuan Lee <[email protected]> | 2018-06-12 07:50:14 +0000 |
|---|---|---|
| committer | Chun Kuan Lee <[email protected]> | 2018-06-12 07:51:56 +0000 |
| commit | 9882d1f044133832b3c0809676d5f26a861b9f44 (patch) | |
| tree | a36dca9ec874fe5734a87dce2bcf93ba8b8df301 | |
| parent | Merge #13230: Simplify include analysis by enforcing the developer guide's in... (diff) | |
| download | discoin-9882d1f044133832b3c0809676d5f26a861b9f44.tar.xz discoin-9882d1f044133832b3c0809676d5f26a861b9f44.zip | |
Reset default -g -O2 flags when enable debug
| -rw-r--r-- | configure.ac | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index af60b28c7..a03b3a575 100644 --- a/configure.ac +++ b/configure.ac @@ -243,6 +243,10 @@ AC_LANG_PUSH([C++]) AX_CHECK_COMPILE_FLAG([-Werror],[CXXFLAG_WERROR="-Werror"],[CXXFLAG_WERROR=""]) if test "x$enable_debug" = xyes; then + # Clear default -g -O2 flags + if test "x$CXXFLAGS_overridden" = xno; then + CXXFLAGS="" + fi # Prefer -Og, fall back to -O0 if that is unavailable. AX_CHECK_COMPILE_FLAG( [-Og], |