File: Makefile

package info (click to toggle)
pmccabe 2.8-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 876 kB
  • sloc: ansic: 3,084; cpp: 1,080; sh: 401; makefile: 42
file content (63 lines) | stat: -rw-r--r-- 1,355 bytes parent folder | download | duplicates (2)
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
# Copyright (c) 2002 Hewlett-Packard under GPL version 2 or later
CFILES=\
	cparse.c      dmain.c	    gettoken.c	  nmain.c	pmccabe.c \
	getopt.c	    io.c

OFILES=$(CFILES:.c=.o)

CFLAGS = -Wall -Wextra -O3 -fwhole-program

INCLUDES=config.h dmain.h getopt.h pmccabe.h

###############{

# On HP-UX you will have to change this
INSTALL = install -o root -g root

DESTDIR = 

PROGS = codechanges pmccabe decomment vifn

MANPGS = codechanges.1 pmccabe.1 vifn.1 decomment.1

DOCS = TODO NEWS COPYING

PMOBJS	      = combined.o

all:		$(PROGS)

test:		$(PROGS)
		cd tests && ./testsuite

pmccabe:	$(PMOBJS)
	$(CC) $(CFLAGS) -o pmccabe $(PMOBJS)

combined.o:	$(CFILES)
	$(CC) $(CFLAGS) -c combined.c

clean:
	rm -f *.[oa] pmccabe decomment tests/*.out tests/*/*.out

install: $(PROGS) $(MANPGS) $(DOCS)
	$(INSTALL) -d $(DESTDIR)/usr/share/doc/pmccabe \
			$(DESTDIR)/usr/share/man/man1 \
			$(DESTDIR)/usr/bin
	$(INSTALL) -m 644 $(MANPGS) $(DESTDIR)/usr/share/man/man1
	#$(INSTALL) -m 644 $(DOCS)  $(DESTDIR)/usr/share/doc/pmccabe
	$(INSTALL) -m 755 $(PROGS) $(DESTDIR)/usr/bin

indent:
	indent -bap -bad -d0 -bli0 -nce -cli0 -ss -npcs -bs -di1 -nbc -psl -i4 -lp -ip0 -nfca -nfc1 *.c *.h

###############}

getopt.o :		config.h getopt.h

dmain.o \
io.o :		dmain.h pmccabe.h

cparse.o \
gettoken.o \
nmain.o :		pmccabe.h dmain.h

pmccabe.o :		pmccabe.h getopt.h