File: Makefile

package info (click to toggle)
since 0.5-4
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 76 kB
  • ctags: 30
  • sloc: ansic: 467; makefile: 65
file content (39 lines) | stat: -rw-r--r-- 674 bytes parent folder | download | duplicates (3)
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
# Files
SRC       = since.c
OBJ       = since.o
TARGET    = since
MAN       = since.1
BINDIR    = /usr/local/bin
MANDIR    = /usr/local/man/man1

# Compiler and Flags
CC        = gcc
CFLAGS    = -Wall -O2 
RM        = rm -f
INSTALL   = install -c
LINK      = ln -s
TOUCH     = touch
TAR       = tar

# Generic build all
all : $(TARGET)

# Install
install : $(TARGET)
	$(INSTALL) -m 0755 $(TARGET) $(BINDIR)
	$(INSTALL) -m 0644 $(MAN) $(MANDIR)

# Build since executable 
$(TARGET) : $(OBJ)
	$(CC) $(CFLAGS) $(OBJ) -o $(TARGET)

# Build object files from source
.c.o :
	$(CC) $(CFLAGS) -c $*.c

# Remove junk
clean : 
	$(RM) *.o core *~

reallyclean : clean
	$(RM) $(TARGET)