-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
40 lines (30 loc) · 783 Bytes
/
Makefile
File metadata and controls
40 lines (30 loc) · 783 Bytes
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
PREFIX := /usr/local
CC := cc
CFLAGS := -pedantic -Wall -O2
LDFLAGS := -lX11
# Uncomment to build on FreeBSD
#LDFLAGS += -L/usr/local/lib -I/usr/local/include
# ···or on OpenBSD
#LDFLAGS += -L/usr/X11R6/lib -I/usr/X11R6/include
all: options scells
options:
@echo \
"scells build options:" \
"\nCC = ${CC}" \
"\nCFLAGS = ${CFLAGS}" \
"\nLDFLAGS = ${LDFLAGS}" \
"\nPREFIX = ${PREFIX}"
scells: scells.c config.def.h config
${CC} ${CFLAGS} ${LDFLAGS} scells.c -o scells
config:
cp config.def.h $@.h
clean:
rm -f *.o scells
strip:
strip -s scells
install: scells strip
mkdir -p ${DESTDIR}/${PREFIX}/bin
install -m 755 scells ${DESTDIR}/${PREFIX}/bin
uninstall:
rm -f ${DESTDIR}/${PREFIX}/bin/scells
.PHONY: all options clean install uninstall