]> git.ipfire.org Git - thirdparty/squid.git/blob - tools/Makefile.am
Merge form trunk
[thirdparty/squid.git] / tools / Makefile.am
1 #
2 # Makefile for the Squid Object Cache server
3 #
4 # Uncomment and customize the following to suit your needs:
5 #
6
7 include $(top_srcdir)/src/Common.am
8
9 AUTOMAKE_OPTIONS = subdir-objects
10
11 ## we need our local files too (but avoid -I. at all costs)
12 INCLUDES += -I$(srcdir)
13
14 SUBDIRS = purge
15 EXTRA_DIST =
16 man_MANS =
17 DISTCLEANFILES =
18
19 LDADD = \
20 $(top_builddir)/src/tests/stub_debug.o \
21 $(top_builddir)/src/time.o \
22 $(top_builddir)/src/ip/libip.la \
23 $(top_builddir)/lib/libmiscencoding.la \
24 $(top_builddir)/lib/libmiscutil.la \
25 $(COMPAT_LIB) \
26 $(KRB5LIBS) \
27 $(XTRA_LIBS)
28
29 include $(top_srcdir)/doc/manuals/Substitute.am
30
31 test_tools.cc: $(top_srcdir)/test-suite/test_tools.cc
32 cp $(top_srcdir)/test-suite/test_tools.cc .
33
34 # stock tools for unit tests - library independent versions of dlink_list
35 # etc.
36 # globals.cc is needed by test_tools.cc.
37 # Neither of these should be disted from here.
38 TESTSOURCES= test_tools.cc
39 CLEANFILES += test_tools.cc
40
41 ## ##### helper-mux #####
42
43 libexec_SCRIPTS = helper-mux.pl
44 EXTRA_DIST += helper-mux.pl helper-mux.README
45
46 ## Test Scripts
47 EXTRA_DIST += helper-ok-dying.pl helper-ok.pl
48
49 ## ##### squidclient #####
50
51 bin_PROGRAMS = squidclient
52
53 squidclient_SOURCES = squidclient.cc \
54 test_tools.cc
55
56 EXTRA_DIST += squidclient.1
57 man_MANS += squidclient.1
58
59
60
61 ## ##### cachemgr.cgi #####
62
63 DEFAULT_CACHEMGR_CONFIG = $(sysconfdir)/cachemgr.conf
64
65 libexec_PROGRAMS = cachemgr$(CGIEXT)
66
67 cachemgr__CGIEXT__SOURCES = cachemgr.cc \
68 test_tools.cc
69
70 cachemgr__CGIEXT__CXXFLAGS = -DDEFAULT_CACHEMGR_CONFIG=\"$(DEFAULT_CACHEMGR_CONFIG)\" $(AM_CXXFLAGS)
71
72 EXTRA_DIST += cachemgr.conf cachemgr.cgi.8 cachemgr.cgi.8.in
73 CLEANFILES += cachemgr.cgi.8
74 man_MANS += cachemgr.cgi.8
75
76 cachemgr.cgi.8: $(srcdir)/cachemgr.cgi.8.in Makefile
77 $(SUBSTITUTE) < $(srcdir)/cachemgr.cgi.8.in > $@
78
79
80
81 ## Shared
82
83 install-data-local:
84 $(INSTALL_DATA) $(srcdir)/cachemgr.conf $(DESTDIR)$(DEFAULT_CACHEMGR_CONFIG).default
85 @if test -f $(DESTDIR)$(DEFAULT_CACHEMGR_CONFIG) ; then \
86 echo "$@ will not overwrite existing $(DESTDIR)$(DEFAULT_CACHEMGR_CONFIG)" ; \
87 else \
88 echo "$(INSTALL_DATA) $(srcdir)/cachemgr.conf $(DESTDIR)$(DEFAULT_CACHEMGR_CONFIG)"; \
89 $(INSTALL_DATA) $(srcdir)/cachemgr.conf $(DESTDIR)$(DEFAULT_CACHEMGR_CONFIG); \
90 fi
91
92 uninstall-local:
93 @$(SHELL) $(top_srcdir)/scripts/remove-cfg.sh "$(RM)" $(DESTDIR)$(DEFAULT_CACHEMGR_CONFIG)
94 $(RM) -f $(DESTDIR)$(DEFAULT_CACHEMGR_CONFIG).default