libutil_a_SOURCES = include/util/util.h include/util/str_table.h \ include/util/hash_table.h include/util/test.h include/util/rbtree.h \ include/util/array.h include/util/threadpool.h \ include/util/w32threadwrap.h include/util/mempool.h \ lib/util/src/str_table.c lib/util/src/alloc.c lib/util/src/rbtree.c \ lib/util/src/array.c lib/util/src/xxhash.c lib/util/src/hash_table.c \ lib/util/src/fast_urem_by_const.h lib/util/src/threadpool_serial.c \ lib/util/src/is_memory_zero.c lib/util/src/mkdir_p.c \ lib/util/src/canonicalize_name.c lib/util/src/filename_sane.c \ lib/util/src/source_date_epoch.c lib/util/src/file_cmp.c \ lib/util/src/hex_decode.c lib/util/src/base64_decode.c libutil_a_CFLAGS = $(AM_CFLAGS) libutil_a_CPPFLAGS = $(AM_CPPFLAGS) if WINDOWS libutil_a_CFLAGS += -DWINVER=0x0600 -D_WIN32_WINNT=0x0600 endif if HAVE_PTHREAD libutil_a_SOURCES += lib/util/src/threadpool.c libutil_a_CFLAGS += $(PTHREAD_CFLAGS) else if WINDOWS libutil_a_SOURCES += lib/util/src/threadpool.c else libutil_a_CPPFLAGS += -DNO_THREAD_IMPL endif endif if CUSTOM_ALLOC libutil_a_SOURCES += lib/util/src/mempool.c endif noinst_LIBRARIES += libutil.a test_str_table_SOURCES = lib/util/test/str_table.c test_str_table_LDADD = libio.a libsquashfs.la libutil.a libcompat.a test_str_table_CPPFLAGS = $(AM_CPPFLAGS) -DTESTPATH=$(top_srcdir)/lib/util/test test_rbtree_SOURCES = lib/util/test/rbtree.c test_rbtree_LDADD = libutil.a libcompat.a test_xxhash_SOURCES = lib/util/test/xxhash.c test_xxhash_LDADD = libutil.a libcompat.a test_threadpool_SOURCES = lib/util/test/threadpool.c test_threadpool_CFLAGS = $(AM_CFLAGS) $(PTHREAD_CFLAGS) test_threadpool_CPPFLAGS = $(AM_CPPFLAGS) test_threadpool_LDADD = libutil.a libcompat.a $(PTHREAD_LIBS) if HAVE_PTHREAD test_threadpool_CPPFLAGS += -DHAVE_PTHREAD endif test_ismemzero_SOURCES = lib/util/test/is_memory_zero.c test_ismemzero_LDADD = libutil.a libcompat.a test_canonicalize_name_SOURCES = lib/util/test/canonicalize_name.c test_canonicalize_name_LDADD = libutil.a libcompat.a test_filename_sane_SOURCES = lib/util/test/filename_sane.c test_filename_sane_SOURCES += lib/util/src/filename_sane.c test_filename_sane_LDADD = libcompat.a libutil.a test_filename_sane_w32_SOURCES = lib/util/test/filename_sane.c test_filename_sane_w32_SOURCES += lib/util/src/filename_sane.c test_filename_sane_w32_CPPFLAGS = $(AM_CPPFLAGS) -DTEST_WIN32=1 test_filename_sane_w32_LDADD = libcompat.a test_sdate_epoch_SOURCES = lib/util/test/epoch.c test_sdate_epoch_LDADD = libutil.a libcompat.a test_hex_decode_SOURCES = lib/util/test/hex_decode.c test_hex_decode_LDADD = libutil.a libcompat.a test_base64_decode_SOURCES = lib/util/test/base64_decode.c test_base64_decode_LDADD = libutil.a libcompat.a LIBUTIL_TESTS = \ test_str_table test_rbtree test_xxhash test_threadpool test_ismemzero \ test_canonicalize_name test_filename_sane test_filename_sane_w32 \ test_sdate_epoch test_hex_decode test_base64_decode check_PROGRAMS += $(LIBUTIL_TESTS) TESTS += $(LIBUTIL_TESTS) EXTRA_DIST += $(top_srcdir)/lib/util/test/words.txt