File: Makefile.in

package info (click to toggle)
webalizer 2.23.08-3.3
  • links: PTS
  • area: main
  • in suites: bookworm, sid
  • size: 9,864 kB
  • sloc: ansic: 10,021; sh: 345; makefile: 94; python: 55
file content (122 lines) | stat: -rw-r--r-- 4,255 bytes parent folder | download | duplicates (3)
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
118
119
120
121
122
#
# Makefile for webalizer - a web server log analysis program
#
# Copyright (C) 1997-2013  Bradford L. Barrett
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version, and provided that the above
# copyright and permission notice is included with all distributed
# copies of this or derived software.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details (file "COPYING").
#

prefix          = @prefix@
exec_prefix     = @exec_prefix@
datadir         = @datarootdir@

BINDIR          = @bindir@
MANDIR          = @mandir@/man1
ETCDIR          = @sysconfdir@
LOCALEDIR       = @localedir@
GEODB           = @GEODB_LOC@
CC              = @CC@
CFLAGS          = @CFLAGS@ @CPPFLAGS@
LIBS            = @LIBS@ -ldb
WCMGR_LIBS      = @WCMGR_LIBS@
DEFS            = -DETCDIR=\"${ETCDIR}\" -DGEODB_LOC=\"${GEODB}\" @DEFS@ @OPTS@
LDFLAGS         = @LDFLAGS@
INSTALL         = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA    = @INSTALL_DATA@
DEFLANG         = @DEFAULT_LANG@

LANGS=$(shell for a in po/*.po; do basename $${a%.po}; done)


# Shouldn't have to touch below here!

all: webalizer wcmgr

webalizer:	webalizer.o webalizer.h hashtab.o hashtab.h  \
		linklist.o linklist.h preserve.o preserve.h  \
                dns_resolv.o dns_resolv.h parser.o parser.h  \
                output.o output.h graphs.o graphs.h lang.h   \
		$(LANGS:%=po/%.mo)
	$(CC) ${LDFLAGS} -o webalizer webalizer.o hashtab.o linklist.o preserve.o parser.o output.o dns_resolv.o graphs.o ${LIBS}
	rm -f webazolver
	@LN_S@ webalizer webazolver

webalizer.o:	webalizer.c webalizer.h parser.h output.h preserve.h \
		graphs.h dns_resolv.h
	$(CC) ${CFLAGS} ${DEFS} -c webalizer.c

parser.o:	parser.c parser.h webalizer.h lang.h
	$(CC) ${CFLAGS} ${DEFS} -c parser.c

hashtab.o:	hashtab.c hashtab.h dns_resolv.h webalizer.h lang.h
	$(CC) ${CFLAGS} ${DEFS} -c hashtab.c

linklist.o:	linklist.c linklist.h webalizer.h lang.h
	$(CC) ${CFLAGS} ${DEFS} -c linklist.c

output.o:	output.c output.h webalizer.h preserve.h \
		hashtab.h graphs.h lang.h
	$(CC) ${CFLAGS} ${DEFS} -c output.c

preserve.o:	preserve.c preserve.h webalizer.h parser.h   \
		hashtab.h graphs.h lang.h
	$(CC) ${CFLAGS} ${DEFS} -c preserve.c

dns_resolv.o:	dns_resolv.c dns_resolv.h lang.h webalizer.h
	$(CC) ${CFLAGS} ${DEFS} -c dns_resolv.c

graphs.o:	graphs.c graphs.h webalizer.h lang.h
	$(CC) ${CFLAGS} ${DEFS} -c graphs.c

wcmgr:	wcmgr.o
	$(CC) ${LDFLAGS} -o wcmgr wcmgr.o ${WCMGR_LIBS} 

wcmgr.o:	wcmgr.c webalizer.h
	$(CC) ${CFLAGS} ${DEFS} -c wcmgr.c

$(LANGS:%=po/%.mo): %.mo: %.po
	msgfmt $< -o $@

clean:
	rm -f webalizer webazolver wcmgr *.o usage*.png daily*.png hourly*.png
	rm -f ctry*.png *.html *.hist *.current core *.gif

distclean: clean
	rm -f webalizer.conf *.tar *.tgz *.Z *.tar.gz
	rm -f Makefile config.cache config.log config.status $(LANGS:%=po/%.mo)

install: all
	mkdir -p ${DESTDIR}${BINDIR}
	mkdir -p ${DESTDIR}${MANDIR}
	mkdir -p ${DESTDIR}${ETCDIR}
	$(INSTALL_PROGRAM) webalizer ${DESTDIR}${BINDIR}/webalizer
	$(INSTALL_PROGRAM) wcmgr ${DESTDIR}${BINDIR}/wcmgr
	rm -f ${DESTDIR}${BINDIR}/webazolver
	@LN_S@ webalizer ${DESTDIR}${BINDIR}/webazolver
	$(INSTALL_DATA) webalizer.1 ${DESTDIR}${MANDIR}/webalizer.1
	$(INSTALL_DATA) wcmgr.1 ${DESTDIR}${MANDIR}/wcmgr.1
	rm -f ${DESTDIR}${MANDIR}/webazolver.1
	@LN_S@ webalizer.1 ${DESTDIR}${MANDIR}/webazolver.1
	$(INSTALL_DATA) sample.conf ${DESTDIR}${ETCDIR}/webalizer.conf.sample
	for a in $(LANGS); do $(INSTALL_DATA) po/$$a.mo ${DESTDIR}/$(LOCALEDIR)/$$a/LC_MESSAGES/webalizer.mo; done

uninstall:
	rm -f ${DESTDIR}${BINDIR}/webalizer
	rm -f ${DESTDIR}${BINDIR}/webazolver
	rm -f ${DESTDIR}${BINDIR}/wcmgr
	rm -f ${DESTDIR}${MANDIR}/webalizer.1
	rm -f ${DESTDIR}${MANDIR}/webazolver.1
	rm -f ${DESTDIR}${MANDIR}/wcmgr.1
	rm -f ${DESTDIR}${ETCDIR}/webalizer.conf.sample
	for a in $(LANGS); do rm -f $(LOCALEDIR)/$$a/LC_MESSAGES/webalizer.mo; done