summaryrefslogtreecommitdiff
path: root/lib/subdir.am
diff options
context:
space:
mode:
authorDavid Lamparter <equinox@diac24.net>2021-03-16 11:03:44 +0100
committerDavid Lamparter <equinox@opensourcerouting.org>2021-05-02 16:27:17 +0200
commit64dd77361f7ab97365d264408afb538097c0339c (patch)
treefb9350dd6f43fae80b8d3e67cbb285901f42e125 /lib/subdir.am
parent642ac49da40a196c4e4ad74128de2056237d3cb4 (diff)
lib: rework how we "override" assert()
The previous method, using zassert.h and hoping nothing includes assert.h (which, on glibc at least, just does "#undef assert" and puts its own definition in...) was fragile - and actually broke undetected. Just provide our own assert.h and control overriding by putting it in a separate directory to add to the include path (or not.) Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Diffstat (limited to 'lib/subdir.am')
-rw-r--r--lib/subdir.am4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/subdir.am b/lib/subdir.am
index fcaae9628a..480c2938d0 100644
--- a/lib/subdir.am
+++ b/lib/subdir.am
@@ -284,6 +284,8 @@ pkginclude_HEADERS += \
lib/zlog_targets.h \
lib/pbr.h \
lib/routing_nb.h \
+ \
+ lib/assert/assert.h \
# end
@@ -412,7 +414,7 @@ lib_grammar_sandbox_SOURCES = \
lib_grammar_sandbox_LDADD = \
lib/libfrr.la
-lib_clippy_CPPFLAGS = $(AM_CPPFLAGS) -D_GNU_SOURCE -DBUILDING_CLIPPY
+lib_clippy_CPPFLAGS = $(CPPFLAGS_BASE) -D_GNU_SOURCE -DBUILDING_CLIPPY
lib_clippy_CFLAGS = $(AC_CFLAGS) $(PYTHON_CFLAGS)
lib_clippy_LDADD = $(PYTHON_LIBS) $(UST_LIBS) -lelf
lib_clippy_LDFLAGS = -export-dynamic