-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmkfile.lua
76 lines (66 loc) · 1.25 KB
/
mkfile.lua
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
64
65
66
67
68
69
70
71
72
73
74
75
76
</$objtype/mkfile
LIB=liblua.a
OFILES=\
lzio.$O\
lctype.$O\
lopcodes.$O\
lmem.$O\
lundump.$O\
ldump.$O\
lstate.$O\
lgc.$O\
llex.$O\
lcode.$O\
lparser.$O\
ldebug.$O\
lfunc.$O\
lobject.$O\
ltm.$O\
lstring.$O\
ltable.$O\
ldo.$O\
lvm.$O\
lapi.$O\
lauxlib.$O\
lbaselib.$O\
lcorolib.$O\
ldblib.$O\
liolib.$O\
lmathlib.$O\
loadlib.$O\
loslib.$O\
lstrlib.$O\
ltablib.$O\
lutf8lib.$O\
linit.$O\
UPDATE=\
mkfile\
$HFILES\
${OFILES:%.$O=%.c}\
${LIB:/$objtype/%=/386/%}\
</sys/src/cmd/mksyslib
CC=pcc
LD=pcc
CFLAGS= -c -I. -D_C99_SNPRINTF_EXTENSION -D_POSIX_SOURCE \
-D_SUSV2_SOURCE -DLUA_POSIX -DENABLE_CJSON_GLOBAL \
-DMAKE_LIB -DPlan9
%.$O: %.c
$CC $CFLAGS $stem.c
install:V:
cp liblua.a /$objtype/lib/ape/liblua.a
cp lauxlib.h /sys/include/ape/lauxlib.h
cp lua.h /sys/include/ape/lua.h
cp luaconf.h /sys/include/ape/luaconf.h
cp lualib.h /sys/include/ape/lualib.h
@{
mk -f mkfile_bin install
}
clean:V:
rm -f *.[$OS]
nuke:V:
rm -f $LIB
rm -f /$objtype/lib/ape/liblua.a
rm -f $HFILES
@{
mk -f mkfile_bin nuke
}