]> git.ipfire.org Git - thirdparty/squid.git/blame - src/icmp/Makefile.am
SourceLayout: lost ICMP Makefile.am
[thirdparty/squid.git] / src / icmp / Makefile.am
CommitLineData
8a40230f
AJ
1#
2# Makefile for the Squid ICMP and Network Measurement API
3#
4
5# Housekeeping, shared by all Squid Makefiles.
6# TODO: make this set by configure?
7AM_CFLAGS = @SQUID_CFLAGS@
8AM_CXXFLAGS = @SQUID_CXXFLAGS@
9DEFS = @DEFS@
10
11INCLUDES = -I$(top_srcdir)/src @SQUID_CPPUNIT_INC@ -I$(top_builddir)/lib
12$(OBJS): $(top_srcdir)/include/version.h $(top_srcdir)/include/autoconf.h
13
14# TODO: get rid of this when config filename is no longer a global constant.
15# its only here so the testIcmp will link .
16DEFS += -DDEFAULT_CONFIG_FILE=NULL
17
18
19
20# ICMP Specific Configurations
21
22if ENABLE_PINGER
23PINGER = pinger
24else
25PINGER =
26endif
27
28EXTRA_PROGRAMS = \
29 pinger \
30 testIcmp
31
32libexec_PROGRAMS = $(PINGER)
33
34noinst_LTLIBRARIES = libicmp-core.la libicmp.la
35
36# ICMP API definition ...
37libicmp_core_la_SOURCES = \
38 Icmp.h \
39 Icmp.cc
40
41# Squid Internal ICMP helper interface
42libicmp_la_SOURCES = \
43 IcmpConfig.h \
44 IcmpSquid.h \
45 IcmpSquid.cc \
46 net_db.h \
47 net_db.cc
48
49# ICMP lookup helper
50pinger_SOURCES = \
51 IcmpPinger.h \
52 IcmpPinger.cc \
53 Icmp4.h \
54 Icmp4.cc \
55 Icmp6.h \
56 Icmp6.cc \
57 pinger.cc
58
59# depends on these but install/dist is done elsewhere.
60# TODO: remove when these are cleaned up in their own way.
61nodist_pinger_SOURCES = \
62 Icmp.h \
63 ../debug.cc \
64 ../time.cc \
65 ../SquidConfig.cc \
66 ../SquidNew.cc \
67 ../globals.cc
68
69pinger_LDFLAGS = $(LIBADD_DL)
70pinger_LDADD=\
71 libicmp-core.la \
72 libmiscutil.a
73pinger_DEPENDENCIES= \
74 libicmp-core.la \
75 $(top_builddir)/lib/libmiscutil.a
76
77
78
79##install-pinger:
80## @f=$(PINGER_EXE); \
81## if test -f $(libexecdir)/$$f; then \
82## echo $(MV) $(libexecdir)/$$f $(libexecdir)/-$$f; \
83## $(MV) $(libexecdir)/$$f $(libexecdir)/-$$f; \
84## fi; \
85## echo $(INSTALL_SUID) $$f $(libexecdir); \
86## $(INSTALL_SUID) $$f $(libexecdir) || exit 1; \
87## if test -f $(libexecdir)/-$$f; then \
88## echo $(RM) -f $(libexecdir)/-$$f; \
89## $(RM) -f $(libexecdir)/-$$f; \
90## fi
91
92
93check_PROGRAMS= testIcmp testHeaders
94TESTS= $(check_PROGRAMS)
95
96## Special Universal .h dependency test script
97## aborts if error encountered
98testHeaders: $(top_srcdir)/src/icmp/*.h
99 $(SHELL) $(top_srcdir)/test-suite/testheaders.sh "$(CXXCOMPILE)" "." || exit 1
100
101## No such file...
102testHeaders.c:
103 touch testHeaders.c
104
105
106## Tests of the ICMP base module.
107# Its used by pinger so SHOULD NOT require more dependancies! :-(
108testIcmp_SOURCES=\
109 Icmp.h \
110 testIcmp.h \
111 testIcmp.cc \
112 \
113 ../tests/testMain.cc \
114 ../SquidTime.h \
115 ../time.cc \
116 ../../test-suite/test_tools.cc \
117 ../globals.cc
118testIcmp_LDFLAGS = $(LIBADD_DL)
119testIcmp_LDADD=\
120 @SQUID_CPPUNIT_LIBS@ \
121 @SQUID_CPPUNIT_LA@ \
122 libicmp-core.la \
123 libmiscutil.a
124testIcmp_DEPENDENCIES= @SQUID_CPPUNIT_LA@ \
125 libicmp-core.la \
126 $(top_builddir)/lib/libmiscutil.a