File: Makefile

package info (click to toggle)
randtype 1.13-9
  • links: PTS
  • area: main
  • in suites: lenny, squeeze
  • size: 96 kB
  • ctags: 44
  • sloc: ansic: 546; makefile: 45
file content (41 lines) | stat: -rw-r--r-- 1,068 bytes parent folder | download | duplicates (6)
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
#
# This is the Makefile for randtype. If you don't have the random() function
# remove the apropriate define. The others are defaults for character delays 
# on output; they can be changed at runtime. 
#
CC		= gcc
CFLAGS		= -Wall -ansi -pedantic -O2 -g
DEFINES		= -DDEF_MS=18 -DDEF_MULT=20000 -DHAVE_RANDOM
LIBS		= -lz

#-------------------------------------------------------------------------------
# Shouldnt need to edit anything below here.
#-------------------------------------------------------------------------------
MANPAGE_DIR	= /usr/local/share/man
MANPAGE_SECTION	= 1
DEFINES		+= -D_GNU_SOURCE -DHAVE_ZLIB
TARGET		= randtype
OBJS		= randtype.o

all: $(TARGET)

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

$(TARGET): $(OBJS)
	$(CC) $(CFLAGS) $(DEFINES) -o $(TARGET) $(OBJS) $(LIBS)

install: all
	install -cp -m 0644 -o root $(TARGET).$(MANPAGE_SECTION).gz \
		$(MANPAGE_DIR)/man$(MANPAGE_SECTION)
	install -cps -m 0755 -o root $(TARGET) /usr/local/bin

tags:
	rm -f tags
	ctags *.c

clean:
	rm -f $(TARGET) $(OBJS) core

realclean: clean
	rm -f tags