Makefile.am 2.82 KB
Newer Older
1 2 3
SUBDIRS = . tests

AM_CPPFLAGS = -I$(top_srcdir)/src/lib -I$(top_builddir)/src/lib
4
AM_CPPFLAGS += $(BOOST_INCLUDES) $(MULTITHREADING_FLAG)
5
AM_CPPFLAGS += -I$(top_srcdir)/src/lib/dns -I$(top_builddir)/src/lib/dns
6
AM_CPPFLAGS += -I$(top_srcdir)/src/lib/util -I$(top_builddir)/src/lib/util
7
AM_CPPFLAGS += -I$(top_srcdir)/src/lib/log -I$(top_builddir)/src/lib/log
8 9 10 11
AM_CPPFLAGS += -I$(top_srcdir)/src/lib/nsas -I$(top_builddir)/src/lib/nsas
AM_CPPFLAGS += $(SQLITE_CFLAGS)
AM_CXXFLAGS = $(B10_CXXFLAGS)

12 13
# Some versions of GCC warn about some versions of Boost regarding missing
# initializer for members in its posix_time.
14
# https://svn.boost.org/trac/boost/ticket/3477
15 16
# But older GCC compilers don't have the flag.
AM_CXXFLAGS += $(WARNING_NO_MISSING_FIELD_INITIALIZERS_CFLAG)
17

18 19
# clang++ complains about unused function parameters in some boost header
# files.
20
if USE_CLANGPP
21 22 23
AM_CXXFLAGS += -Wno-unused-parameter
endif

24
# Define rule to build logging source files from message file
25 26 27
nsas_messages.h nsas_messages.cc: s-messages

s-messages: nsas_messages.mes
28
	$(top_builddir)/src/lib/log/compiler/message $(top_srcdir)/src/lib/nsas/nsas_messages.mes
29
	touch $@
30

31
# What is being built.
32
lib_LTLIBRARIES = libb10-nsas.la
33

34
# Tell Automake that the nsas_messages.{cc,h} source files are created in the build
35 36 37 38 39
# process, so it must create these before doing anything else.  Although they
# are a dependency of the library (so will be created from the message file
# anyway), there is no guarantee as to exactly _when_ in the build they will be
# created.  As the .h file is included in other sources file (so must be
# present when they are compiled), the safest option is to create it first.
40
BUILT_SOURCES = nsas_messages.h nsas_messages.cc
41 42

# Library sources. The generated files will not be in the distribution.
43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59
libb10_nsas_la_SOURCES  = address_entry.h address_entry.cc
libb10_nsas_la_SOURCES += hash.cc hash.h
libb10_nsas_la_SOURCES += hash_deleter.h
libb10_nsas_la_SOURCES += hash_key.cc hash_key.h
libb10_nsas_la_SOURCES += hash_table.h
libb10_nsas_la_SOURCES += nameserver_address_store.cc nameserver_address_store.h
libb10_nsas_la_SOURCES += nameserver_address.h nameserver_address.cc
libb10_nsas_la_SOURCES += nameserver_entry.cc nameserver_entry.h
libb10_nsas_la_SOURCES += nsas_entry_compare.h
libb10_nsas_la_SOURCES += nsas_entry.h nsas_types.h
libb10_nsas_la_SOURCES += nsas_log.cc nsas_log.h
libb10_nsas_la_SOURCES += zone_entry.cc zone_entry.h
libb10_nsas_la_SOURCES += fetchable.h
libb10_nsas_la_SOURCES += address_request_callback.h
libb10_nsas_la_SOURCES += glue_hints.h glue_hints.cc

nodist_libb10_nsas_la_SOURCES  = nsas_messages.h nsas_messages.cc
60 61

# The message file should be in the distribution.
62
EXTRA_DIST = nsas_messages.mes
63

64
# Make sure that the generated files are got rid of in a clean operation
65
CLEANFILES = *.gcno *.gcda nsas_messages.h nsas_messages.cc s-messages