]>
Commit | Line | Data |
---|---|---|
1 | uikittools = uiduid uicache uiopen gssc sbdidlaunch sbreload cfversion iomfsetgamma ldrestart | |
2 | ||
3 | all: $(uikittools) | |
4 | ||
5 | clean: | |
6 | rm -f $(uikittools) extrainst_ | |
7 | ||
8 | .PHONY: all clean package | |
9 | ||
10 | private := -F/System/Library/PrivateFrameworks | |
11 | ||
12 | flags := -Os -Werror | |
13 | flags += -framework CoreFoundation | |
14 | flags += -framework Foundation | |
15 | flags += -miphoneos-version-min=2.0 | |
16 | flags += -arch armv6 | |
17 | ||
18 | ldrestart := -std=c++11 | |
19 | gssc := -lobjc | |
20 | iomfsetgamma := -I. $(private) -framework IOKit -framework IOMobileFramebuffer | |
21 | sbdidlaunch := $(private) -framework SpringBoardServices | |
22 | uicache := -framework UIKit # XXX: UIKit -> MobileCoreServices | |
23 | uiduid := -framework UIKit | |
24 | uiopen := -framework UIKit | |
25 | uishoot := -framework UIKit | |
26 | ||
27 | uicache: csstore.cpp | |
28 | extrainst_: csstore.cpp | |
29 | ||
30 | %: %.mm | |
31 | cycc -- -o $@ $^ $(flags) $($@) | |
32 | ldid -S$(wildcard $@.xml) $@ | |
33 | ||
34 | %: %.cpp | |
35 | cycc -- -o $@ $^ $(flags) $($@) | |
36 | ldid -S$(wildcard $@.xml) $@ | |
37 | ||
38 | %: %.c | |
39 | cycc -- -o $@ -x c $^ $(flags) $($@) | |
40 | ldid -S$(wildcard $@.xml) $@ | |
41 | ||
42 | package: all extrainst_ | |
43 | sudo rm -rf _ | |
44 | mkdir -p _/usr/bin | |
45 | cp -a $(filter-out %.dylib,$(uikittools)) _/usr/bin | |
46 | mkdir -p _/DEBIAN | |
47 | ./control.sh _ >_/DEBIAN/control | |
48 | cp -a extrainst_ _/DEBIAN/ | |
49 | mkdir -p debs | |
50 | ln -sf debs/uikittools_$$(./version.sh)_iphoneos-arm.deb uikittools.deb | |
51 | sudo chown -R 0 _ | |
52 | sudo chgrp -R 0 _ | |
53 | dpkg-deb -b _ uikittools.deb | |
54 | readlink uikittools.deb |