2 # copyright (c) 2001-2011 Emil Mikulic.
4 # You may use, modify and redistribute this file under the terms of the
5 # GNU General Public License version 2. (see COPYING.GPL)
16 HOSTCFLAGS ?
= $(CFLAGS
)
19 exec_prefix = @
exec_prefix@
21 datarootdir
= @datarootdir@
24 # Optimizations FIXME: dead code. push into autoconf?
25 #CPPFLAGS += -D__OPTIMIZE__
48 OBJS
= $(SRCS
:%.c
=%.o
)
58 $(AM_V_at
)$(CC
) $(CFLAGS
) $(OBJS
) $(LDFLAGS
) $(LIBS
) -o
$@
62 $(AM_V_at
)$(CC
) $(CPPFLAGS
) $(CFLAGS
) -c
$< -o
$@
70 depend
: config.status
$(STATICHS
)
71 cp Makefile.in Makefile.in.old
72 sed
'/^# Automatically generated dependencies$$/,$$d' \
73 <Makefile.in.old
>Makefile.in
74 echo
"# Automatically generated dependencies" >>Makefile.in
75 $(CPP
) $(CPPFLAGS
) -MM
$(SRCS
) >>Makefile.in
80 @echo
$(CPP
) $(CPPFLAGS
) -MM
$(SRCS
)
82 graphjs.h
: static
/graph.js
84 $(AM_V_at
).
/c-ify graph_js
<static
/graph.js
>$@
86 stylecss.h
: static
/style.css
88 $(AM_V_at
).
/c-ify style_css
<static
/style.css
>$@
93 $(AM_V_at
)$(HOSTCC
) $(HOSTCFLAGS
) static
/c-ify.c
-o
$@
96 $(INSTALL
) -d
$(DESTDIR
)$(sbindir
)
97 $(INSTALL
) -m
555 darkstat
$(DESTDIR
)$(sbindir
)
98 $(INSTALL
) -d
$(DESTDIR
)$(mandir)/man8
99 $(INSTALL
) -m
444 darkstat
.8 $(DESTDIR
)$(mandir)/man8
101 .PHONY
: all install clean depend show-dep
104 AM_DEFAULT_VERBOSITY
= @AM_DEFAULT_VERBOSITY@
105 AM_V_CC
= $(am__v_CC_
$(V
))
106 am__v_CC_
= $(am__v_CC_
$(AM_DEFAULT_VERBOSITY
))
107 am__v_CC_0
= @echo
" CC " $@
;
108 AM_V_LINK
= $(am__v_LINK_
$(V
))
109 am__v_LINK_
= $(am__v_LINK_
$(AM_DEFAULT_VERBOSITY
))
110 am__v_LINK_0
= @echo
" LINK " $@
;
111 AM_V_HOSTCC
= $(am__v_HOSTCC_
$(V
))
112 am__v_HOSTCC_
= $(am__v_HOSTCC_
$(AM_DEFAULT_VERBOSITY
))
113 am__v_HOSTCC_0
= @echo
" HOSTCC" $@
;
114 AM_V_CIFY
= $(am__v_CIFY_
$(V
))
115 am__v_CIFY_
= $(am__v_CIFY_
$(AM_DEFAULT_VERBOSITY
))
116 am__v_CIFY_0
= @echo
" C-IFY " $@
;
117 AM_V_at
= $(am__v_at_
$(V
))
118 am__v_at_
= $(am__v_at_
$(AM_DEFAULT_VERBOSITY
))
121 # Automatically generated dependencies
122 acct.o
: acct.c acct.h decode.h addr.h conv.h config.h daylog.h graph_db.h \
123 err.h cdefs.h hosts_db.h localip.h now.h opt.h
124 addr.o
: addr.c addr.h
125 cap.o
: cap.c cdefs.h cap.h config.h conv.h decode.h addr.h hosts_db.h \
126 localip.h opt.h err.h
127 conv.o
: conv.c cdefs.h config.h conv.h err.h
128 darkstat.o
: darkstat.c acct.h cap.h cdefs.h config.h conv.h daylog.h \
129 graph_db.h db.h dns.h err.h http.h hosts_db.h addr.h localip.h ncache.h \
131 daylog.o
: daylog.c err.h cdefs.h daylog.h graph_db.h str.h now.h
132 db.o
: db.c cdefs.h err.h hosts_db.h addr.h graph_db.h db.h
133 decode.o
: decode.c cdefs.h acct.h cap.h config.h decode.h addr.h err.h \
135 dns.o
: dns.c cdefs.h conv.h config.h decode.h addr.h dns.h err.h \
136 hosts_db.h queue.h str.h tree.h
137 err.o
: err.c cdefs.h conv.h config.h err.h opt.h pidfile.h
138 graph_db.o
: graph_db.c cap.h conv.h config.h db.h acct.h err.h cdefs.h \
139 str.h html.h graph_db.h now.h opt.h
140 hosts_db.o
: hosts_db.c cdefs.h conv.h config.h decode.h addr.h dns.h \
141 err.h hosts_db.h db.h html.h ncache.h now.h opt.h str.h
142 hosts_sort.o
: hosts_sort.c cdefs.h err.h hosts_db.h addr.h
143 html.o
: html.c config.h str.h html.h opt.h
144 http.o
: http.c cdefs.h config.h conv.h err.h graph_db.h hosts_db.h addr.h \
145 http.h now.h queue.h str.h stylecss.h graphjs.h
146 localip.o
: localip.c addr.h config.h conv.h err.h cdefs.h localip.h
147 ncache.o
: ncache.c conv.h config.h err.h cdefs.h ncache.h tree.h
148 pidfile.o
: pidfile.c err.h cdefs.h str.h pidfile.h
149 str.o
: str.c conv.h config.h err.h cdefs.h str.h