pw_build: add "-Wundef" to strict_warnings
Adds "-Wundef" to "strict_warnings" to catch use of accidentally
undefined macros which otherwise implicitly default to 0.
Updates macros across Pigweed to make it compile.
Drops support for PW_TEST_DONT_DEFINE_* in addition to
GTEST_DONT_DEFINE_*, instead only GTEST_DONT_DEFINE_* is used.
Change-Id: Id89f85f7cb8a52c1619bc0f7262349310203067b
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/21463
Reviewed-by: Alexei Frolov <frolv@google.com>
Reviewed-by: Wyatt Hepler <hepler@google.com>
Commit-Queue: Ewout van Bekkum <ewout@google.com>
diff --git a/pw_assert_log/assert_log.cc b/pw_assert_log/assert_log.cc
index 2d835d9..9d8b9ba 100644
--- a/pw_assert_log/assert_log.cc
+++ b/pw_assert_log/assert_log.cc
@@ -14,8 +14,10 @@
#include "pw_assert_log/assert_log.h"
+#include "pw_assert/options.h"
+
extern "C" void pw_assert_HandleFailure(void) {
-#if PW_ASSERT_DEBUG_ENABLED
+#if PW_ASSERT_ENABLE_DEBUG
PW_LOG(PW_LOG_LEVEL_CRITICAL,
PW_LOG_ASSERT_FAILED_FLAG,
"Crash: PW_ASSERT() or PW_DASSERT() failure");
@@ -23,6 +25,6 @@
PW_LOG(PW_LOG_LEVEL_CRITICAL,
PW_LOG_ASSERT_FAILED_FLAG,
"Crash: PW_ASSERT() failure. Note: PW_DASSERT disabled");
-#endif // PW_ASSERT_DEBUG_ENABLED
+#endif // PW_ASSERT_ENABLE_DEBUG
PW_UNREACHABLE;
}