-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile.linux32
executable file
·61 lines (47 loc) · 1.55 KB
/
Makefile.linux32
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
##
#
# AnV LZVN/LZSS kernel cache decompressor V1.0
#
# Linux version
#
##
PREFIX=/usr/local
LIBPREFIX=Linux
NASM=nasm
CC=clang -m32 -I$(PREFIX)/include -I$(LIBPREFIX)
YACC=/usr/local/bin/bison -y
AR=ar
RANLIB=ranlib
LIBS=-L. -llzvn -L"$(PREFIX)/lib32" -lCoreFoundation -licuuc -licudata -licui18n -lBlocksRuntime -ldispatch -lstdc++ -lsupc++ -lkqueue -lc -lpthread -lm -lrt
INSTALL=install
ARFLAGS=cru
CFLAGS=-Os
ASFLAGS=$(CFLAGS)
all: decompkernelcache decompkernelcache-kc
# .asm.o:
# $(NASM) -o $@ -f macho64 $<
# .s.o:
# $(CC) $(ASFLAGS) -c $< -o $@
# .S.o:
# $(CC) $(ASFLAGS) -c $< -o $@
.c.o:
$(CC) $(CFLAGS) -c $< -o $@
#IOCFUnserialize.c: IOCFUnserialize.yacc
# $(YACC) -o $@ $<
lzvndec.o: lzvndec.c
lzvn_encode.o: lzvn_encode.c
WINSUPSRC/IOCFUnserialize.o: WINSUPSRC/IOCFUnserialize.c
liblzvn.a: lzvndec.o lzvn_encode.o
$(AR) $(ARFLAGS) $@ $^
$(RANLIB) liblzvn.a
decompkernelcache: decompkernelcache.o WINSUPSRC/IOCFUnserialize.o liblzvn.a
$(CC) $(CFLAGS) -o $@ decompkernelcache.o WINSUPSRC/IOCFUnserialize.o $(LIBS)
decompkernelcache-kc: decompkernelcache-kc.o WINSUPSRC/IOCFUnserialize.o liblzvn.a
$(CC) $(CFLAGS) -o $@ decompkernelcache.o WINSUPSRC/IOCFUnserialize.o $(LIBS)
clean:
rm -f *.o WINSUPSRC/IOCFUnserialize.o liblzvn.a decompkernelcache decompkernelcache-kc
install: decompkernelcache decompkernelcache-kc lzvn.h liblzvn.a
$(INSTALL) decompkernelcache $(PREFIX)/bin
$(INSTALL) decompkernelcache-kc $(PREFIX)/bin
$(INSTALL) liblzvn.a $(PREFIX)/lib
$(INSTALL) lzvn.h $(PREFIX)/include