]> git.ipfire.org Git - thirdparty/squid.git/blob - src/icmp/Makefile.am
SourceFormat Enforcement
[thirdparty/squid.git] / src / icmp / Makefile.am
1 ## Copyright (C) 1996-2015 The Squid Software Foundation and contributors
2 ##
3 ## Squid software is distributed under GPLv2+ license and includes
4 ## contributions from numerous individuals and organizations.
5 ## Please see the COPYING and CONTRIBUTORS files for details.
6 ##
7
8 include $(top_srcdir)/src/Common.am
9 include $(top_srcdir)/src/TestHeaders.am
10
11 # TODO: get rid of this when config filename is no longer a global constant.
12 # its only here so the testIcmp will link .
13 DEFS += -DDEFAULT_CONFIG_FILE=NULL
14
15
16 # ICMP Specific Configurations
17
18 if ENABLE_PINGER
19 PINGER = pinger
20 else
21 PINGER =
22 endif
23
24 EXTRA_PROGRAMS = \
25 pinger \
26 testIcmp
27
28 libexec_PROGRAMS = $(PINGER)
29
30 noinst_LTLIBRARIES = libicmp-core.la libicmp.la
31
32 SBUF_SOURCE= \
33 $(top_srcdir)/src/base/CharacterSet.h \
34 $(top_srcdir)/src/SBuf.h \
35 $(top_srcdir)/src/SBuf.cc \
36 $(top_srcdir)/src/MemBlob.h \
37 $(top_srcdir)/src/MemBlob.cc \
38 $(top_srcdir)/src/OutOfBoundsException.h \
39 $(top_srcdir)/src/SBufExceptions.h \
40 $(top_srcdir)/src/SBufExceptions.cc \
41 $(top_srcdir)/src/String.cc \
42 $(top_srcdir)/src/SquidString.h \
43 $(top_srcdir)/src/base/TextException.h \
44 $(top_srcdir)/src/base/TextException.cc
45
46 # ICMP API definition ...
47 libicmp_core_la_SOURCES = \
48 Icmp.h \
49 Icmp.cc
50
51 # Squid Internal ICMP helper interface
52 libicmp_la_SOURCES = \
53 IcmpConfig.h \
54 IcmpSquid.h \
55 IcmpSquid.cc \
56 net_db.h \
57 net_db.cc
58
59 # ICMP lookup helper
60 pinger_SOURCES = \
61 Icmp.h \
62 IcmpPinger.h \
63 IcmpPinger.cc \
64 Icmp4.h \
65 Icmp4.cc \
66 Icmp6.h \
67 Icmp6.cc \
68 pinger.cc
69
70 # depends on these but install/dist is done elsewhere.
71 # TODO: remove when these are cleaned up in their own way.
72 nodist_pinger_SOURCES = \
73 $(top_srcdir)/src/debug.cc \
74 $(top_builddir)/src/globals.cc \
75 $(top_srcdir)/src/time.cc \
76 $(top_srcdir)/src/SquidConfig.cc \
77 $(top_srcdir)/src/SquidNew.cc \
78 $(top_srcdir)/src/tests/stub_HelperChildConfig.cc
79
80 pinger_LDFLAGS = $(LIBADD_DL)
81 pinger_LDADD=\
82 libicmp-core.la \
83 ../ip/libip.la \
84 $(COMPAT_LIB) \
85 $(XTRA_LIBS)
86
87
88 ##install-pinger:
89 ## @f=$(PINGER_EXE); \
90 ## if test -f $(libexecdir)/$$f; then \
91 ## echo $(MV) $(libexecdir)/$$f $(libexecdir)/-$$f; \
92 ## $(MV) $(libexecdir)/$$f $(libexecdir)/-$$f; \
93 ## fi; \
94 ## echo $(INSTALL_SUID) $$f $(libexecdir); \
95 ## $(INSTALL_SUID) $$f $(libexecdir) || exit 1; \
96 ## if test -f $(libexecdir)/-$$f; then \
97 ## echo $(RM) -f $(libexecdir)/-$$f; \
98 ## $(RM) -f $(libexecdir)/-$$f; \
99 ## fi
100
101
102 check_PROGRAMS += testIcmp
103 TESTS += testIcmp
104
105 ## Tests of the ICMP base module.
106 # Its used by pinger so SHOULD NOT require more dependancies! :-(
107 testIcmp_SOURCES = \
108 Icmp.h \
109 testIcmp.h \
110 testIcmp.cc
111 nodist_testIcmp_SOURCES = \
112 $(top_srcdir)/src/SquidTime.h \
113 $(top_srcdir)/src/tests/stub_debug.cc \
114 $(top_srcdir)/src/time.cc \
115 $(top_srcdir)/test-suite/test_tools.cc \
116 $(top_builddir)/src/globals.cc
117 testIcmp_LDFLAGS = $(LIBADD_DL)
118 testIcmp_LDADD=\
119 $(SQUID_CPPUNIT_LIBS) \
120 $(SQUID_CPPUNIT_LA) \
121 libicmp-core.la \
122 ../ip/libip.la \
123 ../base/libbase.la \
124 $(COMPAT_LIB) \
125 $(XTRA_LIBS)
126 testIcmp_DEPENDENCIES= $(SQUID_CPPUNIT_LA)