File: Makefile

package info (click to toggle)
gridengine 8.1.9%2Bdfsg-13.1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 57,140 kB
  • sloc: ansic: 432,689; java: 87,068; cpp: 31,958; sh: 29,445; jsp: 7,757; perl: 6,336; xml: 5,828; makefile: 4,704; csh: 3,934; ruby: 2,221; tcl: 1,676; lisp: 669; yacc: 519; python: 503; lex: 361; javascript: 200
file content (84 lines) | stat: -rw-r--r-- 1,977 bytes parent folder | download | duplicates (9)
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
# ADOC -*- Makefile -*- for the GNU C/C++ Compiler on unix systems
#
# (c)Copyright 1995 by Tobias Ferber.
#
# This file is part of ADOC.
#
# ADOC 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 1 of the License, or
# (at your option) any later version.
#
# ADOC 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.
#
# You should have received a copy of the GNU General Public License
# along with ADOC; see the file COPYING.  If not, write to
# the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.

CC= gcc
CFLAGS= -O3
#CFLAGS= -ggdb -Wall -DDEBUG

RM= rm -f

srcs = main.c args.c lex.yy.c libfun.c gencode.c strarg.c strexpand.c mactab.c flist.c
#srcs = main.c args.c lex.yy.c libfun.c gencode.c strarg.c strexpand.c mactab.c flist.c debug.c smartmem.c timer.c
objs = $(srcs:.c=.o)
libs = 
prog = adoc


.PHONY: all

all: $(prog) coda

$(prog): $(objs)
	$(CC) $(CFLAGS) -o $@ $(objs) $(libs)

lex.yy.c: adoc.yy
	flex -8 -f adoc.yy

.c.o:
	$(CC) $(CFLAGS) -c -o $@ $<


#HOME = devel:gmd/HOME
#REX = $(HOME)/bin/rex
#LIBDIR= -L $(HOME)/lib
#INCDIR= -I $(HOME)/lib/include
#
#a.out: libfun.o
#	$(REX) -c -s -d -g adoc.rex
#	$(CC) $(CFLAGS) $(INCDIR) -c *.c
#	$(CC) $(CFLAGS) $(LIBDIR) *.o -lreuse

coda: coda.c
	$(CC) $(CFLAGS) -o $@ $<

coda.c: coda.yy
	flex -8 -f -t >coda.c coda.yy

.PHONY: clean

clean:
ifneq ($(strip $(wildcard $(prog) $(objs) lex.yy.c coda coda.c .depend core*)),)
	$(RM) $(wildcard $(prog) $(objs) lex.yy.c coda coda.c .depend core*)
endif


.PHONY: depend

depend: .depend

.depend:
	$(CC) $(CFLAGS) $(INCDIR) -MM *.c > .depend


# include the dependency file (if it exists)

ifeq (.depend,$(wildcard .depend))
include .depend
endif