bind9/fuzz/Makefile.am
Michał Kępień b60d7345ed Fix function overrides in unit tests on macOS
Since Mac OS X 10.1, Mach-O object files are by default built with a
so-called two-level namespace which prevents symbol lookups in BIND unit
tests that attempt to override the implementations of certain library
functions from working as intended.  This feature can be disabled by
passing the "-flat_namespace" flag to the linker.  Fix unit tests
affected by this issue on macOS by adding "-flat_namespace" to LDFLAGS
used for building all object files on that operating system (it is not
enough to only set that flag for the unit test executables).
2020-09-28 09:09:21 +02:00

42 lines
793 B
Makefile

include $(top_srcdir)/Makefile.top
AM_CPPFLAGS += \
$(LIBISC_CFLAGS) \
$(LIBDNS_CFLAGS) \
-DFUZZDIR=\"$(abs_srcdir)\"
AM_LDFLAGS += \
$(FUZZ_LDFLAGS)
LDADD = \
libfuzzmain.la \
$(LIBISC_LIBS) \
$(LIBDNS_LIBS)
check_LTLIBRARIES = libfuzzmain.la
libfuzzmain_la_SOURCES = \
fuzz.h \
main.c
check_PROGRAMS = \
dns_message_parse \
dns_name_fromtext_target \
dns_rdata_fromwire_text \
isc_lex_getmastertoken \
isc_lex_gettoken
EXTRA_DIST = \
dns_message_parse.in \
dns_name_fromtext_target.in \
dns_rdata_fromwire_text.in \
isc_lex_getmastertoken.in \
isc_lex_gettoken.in
TESTS = $(check_PROGRAMS)
if HAVE_FUZZ_LOG_COMPILER
LOG_COMPILER = $(srcdir)/$(FUZZ_LOG_COMPILER)
AM_LOG_FLAGS = $(srcdir)
endif HAVE_FUZZ_LOG_COMPILER
unit-local: check