1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117
|
#
# $Id: Makefile.in,v 1.13 2005/01/05 15:50:08 niklas Exp niklas $
#
#OPTIONS = -DDEBUG
#OPTIONS = -W -Wall -Werror -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wbad-function-cast -pedantic-errors -O2
srcdir=@srcdir@
VPATH=@srcdir@
prefix=@prefix@
exec_prefix=@exec_prefix@
bindir=@bindir@
mandir=@mandir@
DESTDIR=
SHELL=@SHELL@
SRCS = main.c print.c socket.c request.c http.c alloc.c filter.c db.c file.c dns.c signals.c access.c regex.c msg.c poll.c number.c
OBJS = $(SRCS:.c=.o)
MANPAGES = ffproxy.8 ffproxy.conf.5 ffproxy.quick.7
SMANPAGES = ffproxy.8.s ffproxy.conf.5.s ffproxy.quick.7.s
MY_DBFILES=db/access.dyndns db/access.host db/access.ip db/filter.header.add db/filter.header.drop db/filter.header.entry db/filter.header.match db/filter.host.match db/filter.rheader.drop db/filter.rheader.entry db/filter.rheader.match db/filter.url.match
MY_HTMLFILES=html/connect html/filtered html/invalid html/post html/resolve
sysconfdir=@sysconfdir@
datadir=@datadir@
pkgdatadir=$(datadir)/ffproxy
CC=@CC@
CFLAGS=@CFLAGS@ -DCFGFILE="\"${sysconfdir}/ffproxy.conf\"" \
-DDATADIR="\"$(pkgdatadir)\"" $(OPTIONS)
LDFLAGS=@LDFLAGS@
LIBS=@LIBS@
INSTALL=@INSTALL@
INSTALL_PROGRAM=@INSTALL_PROGRAM@
INSTALL_DATA=@INSTALL_DATA@
all: ffproxy man conf
man:
for i in $(MANPAGES); do \
sed -e 's|_BASE_|$(pkgdatadir)|g' -e 's|_CFGFILE_|$(sysconfdir)/ffproxy.conf|g' $$i.s > $$i; \
done || for i in $(MANPAGES); do \
cp $$i $$i.s; done
conf:
sed -e 's|_BASE_|$(pkgdatadir)|g' sample.config.s \
> sample.config || cp sample.config.s sample.config
cp sample.config ffproxy.conf
installdirs: mkinstalldirs
$(SHELL) $(srcdir)/mkinstalldirs $(DESTDIR)$(bindir) \
$(DESTDIR)$(datadir) \
$(DESTDIR)$(sysconfdir) \
$(DESTDIR)$(pkgdatadir) \
$(DESTDIR)$(pkgdatadir)/db \
$(DESTDIR)$(pkgdatadir)/html \
$(DESTDIR)$(mandir) \
$(DESTDIR)$(mandir)/man5 \
$(DESTDIR)$(mandir)/man7 \
$(DESTDIR)$(mandir)/man8
install: installdirs .WAIT install_bin install_man install_config install_sample install_data
install_bin: ffproxy
$(INSTALL_PROGRAM) ffproxy $(DESTDIR)$(bindir)
install_man: man
$(INSTALL_DATA) ffproxy.conf.5 $(DESTDIR)$(mandir)/man5
$(INSTALL_DATA) ffproxy.quick.7 $(DESTDIR)$(mandir)/man7
$(INSTALL_DATA) ffproxy.8 $(DESTDIR)$(mandir)/man8
install_config: conf
$(INSTALL_DATA) ffproxy.conf $(DESTDIR)$(sysconfdir)
install_sample: conf
$(INSTALL_DATA) sample.config $(DESTDIR)$(pkgdatadir)
install_data:
$(INSTALL_DATA) $(MY_DBFILES) $(DESTDIR)$(pkgdatadir)/db
$(INSTALL_DATA) $(MY_HTMLFILES) $(DESTDIR)$(pkgdatadir)/html
uninstall: uninstall_bin uninstall_man uninstall_sample
uninstall_all: uninstall uninstall_config uninstall_data
uninstall_bin:
-rm -f $(DESTDIR)$(bindir)/ffproxy
uninstall_man:
-rm -f $(DESTDIR)$(mandir)/man5/ffproxy.conf.5
-rm -f $(DESTDIR)$(mandir)/man7/ffproxy.quick.7
-rm -f $(DESTDIR)$(mandir)/man8/ffproxy.8
uninstall_sample:
-rm -f $(DESTDIR)$(pkgdatadir)/sample.config
uninstall_config:
-rm -f $(DESTDIR)$(sysconfdir)/ffproxy.conf
uninstall_data: uninstall_sample
-( cd $(DESTDIR)$(pkgdatadir) && rm -f $(MY_DBFILES) )
-( cd $(DESTDIR)$(pkgdatadir) && rm -f $(MY_HTMLFILES) )
-rmdir $(DESTDIR)$(pkgdatadir)/db
-rmdir $(DESTDIR)$(pkgdatadir)/html
-rmdir $(DESTDIR)$(pkgdatadir)
ffproxy: $(OBJS)
$(CC) $(LDFLAGS) -o $@ $(OBJS) $(LIBS)
clean:
rm -f $(OBJS) $(MANPAGES) sample.config ffproxy.conf ffproxy
distclean: clean
rm -f Makefile configure.h config.cache config.log config.status
|