forked from antirez/yaku-ns
-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
82 lines (63 loc) · 1.69 KB
/
Makefile
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
# YAKU-NS Makefile
#
# Copyright (C) 2000 by Salvatore Sanfilippo
.SUFFIXES:
.SUFFIXES: .c .o
SHELL= /bin/sh
CFLAGS= -W -Wall -O2 -g
AR=/usr/bin/ar
INSTALL= /usr/bin/install
INSTALL_PROGRAM= $(INSTALL)
INSTALL_DATA= $(INSTALL) -m 644
DESTDIR= /usr/bin/
PROGRAMS= yaku-ns yaku-getzone
YAKUNS_OBJECTS= acl.o arr.o axfr_out.o autoptr.o cache.o config.o core.o \
dns.o forward.o local.o log.o htkey.o \
misc.o unix.o uptime.o aht.o strlcpy.o strlcat.o \
signal.o response.o rlimit.o
GETZONE_OBJECTS= getzone.o dns.o strlcpy.o
all: .depend yaku-ns yaku-getzone success
.depend:
@echo Making dependences
@$(CC) -MM *.c > .depend
.c.o:
$(CC) -I. $(CFLAGS) $(DEFS) -c $< -o $@
yaku-ns: $(YAKUNS_OBJECTS)
$(CC) $(LDFLAGS) $^ -o $@
yaku-getzone: $(GETZONE_OBJECTS)
$(CC) $(LDFLAGS) $^ -o $@
strip:
strip $(PROGRAMS)
@ls -l $(PROGRAMS)
install:
@echo See the INSTALL file
clean:
rm -f *.o core .depend .nfs* */.nfs* .*.swp $(PROGRAMS)
success:
@echo
@echo Compilation successful!
@echo Now you can read the INSTALL file
distclean:
mostlyclean:
dist: clean tar
tar:
if [ "x" = "x$(RELEASE)" ]; then \
d=`date -Iseconds | cut -d+ -f1 | tr -- :T -.`; \
v=`grep VERSION tunable.h | cut -d\" -f2`; \
b=`echo yaku-ns-$$v-$$d`; mkdir ../$$b; cp -a . ../$$b; \
cd ..; read; tar cvzf $$b.tar.gz $$b; \
else \
v=`grep VERSION tunable.h | cut -d\" -f2`; \
b=`echo yaku-ns-$$v`; mkdir ../$$b; cp -a . ../$$b; \
cd ..; read; tar cvf - $$b | gzip -9 > $$b.tar.gz; \
read; tar cvf - $$b | bzip2 -9 > $$b.tar.bz2; \
fi; \
ls -l $$b.tar.*
wc:
cat *.[ch] | sed -e /^$$/d | wc -l
#check:
# md5sum -vc MD5SUM.SIGNED.asc
ifeq (.depend,$(wildcard .depend))
include .depend
endif