tests/Makefile.am
author psykose <alice@ayaya.dev>
Thu, 21 Apr 2022 20:23:32 +0200
changeset 744 4ebe32453682
parent 686 206f6c199485
permissions -rw-r--r--
fix macro define for freeaddrinfo with asyncns previously, this define was only made in lm-asyncns-resolver.c, which does not propagate it to lm-resolver.c, where freeaddrinfo() is used. this means that when asyncns support is used, the standard libc freeaddrinfo() is called on an addrinfo acquired from asyncns_getaddrinfo, which is undefined behaviour, and leads to a segfault on musl libc.

include $(top_srcdir)/build/Makefile.am.lm

SUBDIRS = parser-tests

noinst_PROGRAMS = $(TEST_PROGS)
TEST_PROGS =

TEST_PROGS += test-parser                       \
	test-data-objects

test_parser_SOURCES =                           \
	test-parser.c
	
test_data_objects_SOURCES =                     \
	../loudmouth/lm-data-objects.c          \
	test-data-objects.c

AM_CPPFLAGS =                                   \
	-I.                                         \
	-I$(top_srcdir)                             \
	-DLM_COMPILATION                            \
	-DRUNTIME_ENDIAN                            \
	$(LOUDMOUTH_CFLAGS)                         \
	-DPARSER_TEST_DIR="\"$(top_srcdir)/tests/parser-tests\""

LIBS =                                          \
	$(LOUDMOUTH_LIBS)                           \
	$(top_builddir)/loudmouth/libloudmouth-1.la