]> git.saurik.com Git - uikittools.git/blame - makefile
Add ldrestart for safe restart from app jailbreak.
[uikittools.git] / makefile
CommitLineData
68d2b30b 1uikittools = uiduid uicache uiopen gssc sbdidlaunch sbreload cfversion iomfsetgamma ldrestart
2a72f832
JF
2
3all: $(uikittools)
4
5clean:
e0d6a30e 6 rm -f $(uikittools) extrainst_
2a72f832
JF
7
8.PHONY: all clean package
a60b86de 9
a830525c
JF
10private := -F/System/Library/PrivateFrameworks
11
54798aa7
JF
12flags := -Os -Werror
13flags += -framework CoreFoundation
14flags += -framework Foundation
61bc7627
JF
15flags += -miphoneos-version-min=2.0
16flags += -arch armv6
54798aa7 17
68d2b30b 18ldrestart := -std=c++11
54798aa7 19gssc := -lobjc
a830525c 20iomfsetgamma := -I. $(private) -framework IOKit -framework IOMobileFramebuffer
54798aa7
JF
21sbdidlaunch := $(private) -framework SpringBoardServices
22uicache := -framework UIKit # XXX: UIKit -> MobileCoreServices
85a77f07
JF
23uiduid := -framework UIKit
24uiopen := -framework UIKit
54798aa7 25uishoot := -framework UIKit
7141b425 26
4ab9b1c7 27uicache: csstore.cpp
ee2ee18b 28extrainst_: csstore.cpp
4ab9b1c7 29
a60b86de 30%: %.mm
61bc7627 31 cycc -- -o $@ $^ $(flags) $($@)
43318ffe 32 ldid -S$(wildcard $@.xml) $@
2a72f832 33
68d2b30b
JF
34%: %.cpp
35 cycc -- -o $@ $^ $(flags) $($@)
36 ldid -S$(wildcard $@.xml) $@
37
2618b3e9 38%: %.c
61bc7627 39 cycc -- -o $@ -x c $^ $(flags) $($@)
43318ffe 40 ldid -S$(wildcard $@.xml) $@
d9e253f6 41
ee2ee18b 42package: all extrainst_
a830525c 43 sudo rm -rf _
57ebf0d9 44 mkdir -p _/usr/bin
10fd0e0c 45 cp -a $(filter-out %.dylib,$(uikittools)) _/usr/bin
57ebf0d9
JF
46 mkdir -p _/DEBIAN
47 ./control.sh _ >_/DEBIAN/control
ee2ee18b 48 cp -a extrainst_ _/DEBIAN/
57ebf0d9
JF
49 mkdir -p debs
50 ln -sf debs/uikittools_$$(./version.sh)_iphoneos-arm.deb uikittools.deb
a830525c
JF
51 sudo chown -R 0 _
52 sudo chgrp -R 0 _
57ebf0d9
JF
53 dpkg-deb -b _ uikittools.deb
54 readlink uikittools.deb