Message ID | 7f4d3a93-e140-5125-5247-52b86dcb6247@redhat.com |
---|---|
State | New |
Headers | show |
Series | [v2] Fix build with -march=486 -Os -DNDEBUG (Bug 25240) | expand |
* Carlos O'Donell:
> How is this v2 with a better commit message?
Sorry, why has -DNDEBUG got anything with -march=i486 (sic) or -Os?
I think you should mention -DNDEBUG only.
The comment should probably mention CFLAGS and -DNDEBUG, because that's
the common case.
Thanks,
Florian
diff --git a/assert/tst-assert-c++.cc b/assert/tst-assert-c++.cc index 41cb487512..a175f5e961 100644 --- a/assert/tst-assert-c++.cc +++ b/assert/tst-assert-c++.cc @@ -16,6 +16,9 @@ License along with the GNU C Library; if not, see <https://www.gnu.org/licenses/>. */ +/* We do not want the compiler or any other pre-included header from + removing the assert we want to test, so undefine NDEBUG right now. */ +#undef NDEBUG #include <assert.h> /* The C++ standard requires that if the assert argument is a constant