-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.LNI
62 lines (43 loc) · 1.12 KB
/
Makefile.LNI
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
# Makefile for MEX on Linux glibc 2.2 icc
CC=icc
CFLAGS= -O3 -tpp5 -I/usr/include/ncurses
LFLAGS= -s
LIBS= -lncurses
#LIBS= /usr/lib/libncurses.a
OBJ= buffer.o cursor.o display.o files.o help.o line.o main.o random.o \
search.o term.o window.o word.o
mex: $(OBJ)
$(CC) -o mex $(LFLAGS) $(OBJ) $(LIBS)
buffer.o: buffer.c ed.h
$(CC) $(CFLAGS) -c buffer.c
cursor.o: cursor.c ed.h
$(CC) $(CFLAGS) -c cursor.c
display.o: display.c ed.h
$(CC) $(CFLAGS) -c display.c
files.o: files.c ed.h
$(CC) $(CFLAGS) -c files.c
help.o: help.c ed.h
$(CC) $(CFLAGS) -c help.c
line.o: line.c ed.h
$(CC) $(CFLAGS) -c line.c
curkeys.h:
grep 'define[^K]*KEY_' </usr/include/ncurses.h >$@
main.o: main.c ed.h curkeys.h
$(CC) $(CFLAGS) -c main.c
random.o: random.c ed.h
$(CC) $(CFLAGS) -c random.c
search.o: search.c ed.h
$(CC) $(CFLAGS) -c search.c
term.o: term.c ed.h
$(CC) $(CFLAGS) -DCURSES -c term.c
window.o: window.c ed.h
$(CC) $(CFLAGS) -c window.c
word.o: word.c ed.h
$(CC) $(CFLAGS) -c word.c
help.c: help_c.eng
-ln -f $? $@
install: mex
strip mex
su bin -c "cp mex /usr/local/bin"
clean:
rm -f *.o core mex curkeys.h help.c