File: Makefile

package info (click to toggle)
dealer 20161012-4
  • links: PTS, VCS
  • area: main
  • in suites: buster, sid
  • size: 1,148 kB
  • sloc: ansic: 2,436; yacc: 630; perl: 400; makefile: 139; sh: 5
file content (80 lines) | stat: -rw-r--r-- 1,398 bytes parent folder | download
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
# $Header: /home/henk/CVS/dealer/Makefile,v 1.15 1999/08/05 19:57:44 henk Exp $

CC      = gcc
CPPFLAGS += -DSTD_RAND # don't use embedded GNU random lib
FLEX    = flex
YACC    = yacc
# Note: this should be the Berkeley Yacc, sometimes called byacc

PROGRAM  = dealer
TARFILE  = ${PROGRAM}.tar
GZIPFILE = ${PROGRAM}.tar.gz

SRC  = dealer.c pbn.c  c4.c pointcount.c
LSRC = scan.l
YSRC = defs.y
HDR  = dealer.h tree.h

OBJ  = dealer.o defs.o pbn.o c4.o pointcount.o
LOBJ = scan.c
YOBJ = defs.c
MAN  = dealer.6 dealer.dpp.6

dealer: ${OBJ} ${LOBJ} ${YOBJ} ${MAN}
	$(LINK.c) -o $@ ${OBJ}

clean:
	rm -f ${OBJ} ${LOBJ} ${YOBJ} ${MAN}
	${MAKE} -C Examples clean
	${MAKE} -C Random   clean

tarclean: clean ${YOBJ}
	rm -f ${PROGRAM}
	rm -f ${TARFILE}  ${GZIPFILE}

tarfile: tarclean
	cd .. ; \
        rm ${TARFILE} ${GZIPFILE} ; \
	tar cvf ${TARFILE} ${PROGRAM} ; \
	mv ${TARFILE} ${PROGRAM} 
	gzip -f ${TARFILE}

test: dealer
	${MAKE} -C Examples test

#
# Lex
#
.l.c:
	${FLEX} -t $< >$@

#
# Yacc
#
.y.c:
	${YACC} $<
	mv -f y.tab.c $@

#
# C-code
#
.c.o:
	$(COMPILE.c) -o $@ $<

#
# Manpages
#
%.6: %.pod
	pod2man --section=6 --release="Dealer" --center="User Documentation" $< > $@

# 
# File dependencies
#
scan.c: scan.l
defs.c: scan.c defs.y
dealer.o: tree.h scan.l dealer.h defs.c scan.c 
pbn.o: tree.h scan.l dealer.h
defs.o:	tree.h
c4.o: c4.c  c4.h
getopt.o: getopt.h
pointcount.o: pointcount.h