]> git.saurik.com Git - cydia.git/blame - makefile
Don't show role::cydia packages in Expert mode of the installed page.
[cydia.git] / makefile
CommitLineData
89b0ea4a
JF
1ifeq (o,O)
2ios := 2.0
3gcc := 4.0
4else
c21004b9 5ios := 3.2
89b0ea4a
JF
6gcc := 4.2
7endif
c21004b9
JF
8
9flags :=
10link :=
11
12#dpkg := /Library/Cydia/bin/dpkg-deb -Zlzma
13dpkg := dpkg-deb
14
ee4120ad
JF
15sdk := /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS$(ios).sdk
16
17flags += -F$(sdk)/System/Library/PrivateFrameworks
c21004b9
JF
18flags += -I. -isystem sysroot/usr/include -Lsysroot/usr/lib
19flags += -Wall -Werror -Wno-deprecated-declarations
20flags += -fmessage-length=0
21flags += -g0 -O2
22flags += -fobjc-call-cxx-cdtors -fobjc-exceptions
23
24link += -framework CoreFoundation
25link += -framework CoreGraphics
26link += -framework Foundation
27link += -framework GraphicsServices
28link += -framework IOKit
29link += -framework JavaScriptCore
30link += -framework QuartzCore
31link += -framework SystemConfiguration
c21004b9
JF
32link += -framework WebCore
33link += -framework WebKit
34
35link += -lapr-1
36link += -lapt-pkg
37link += -lpcre
38
39link += -multiply_defined suppress
5f6bff8c 40
e17a8c4f
JF
41uikit :=
42uikit += -framework UIKit
43
44backrow :=
45backrow += -FAppleTV -framework BackRow -framework AppleTV
46
ee4120ad 47#cycc = cycc -r4.2 -i$(ios) -o$@
89b0ea4a 48gxx := /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/g++-$(gcc)
ee4120ad
JF
49cycc = $(gxx) -arch armv6 -o $@ -mcpu=arm1176jzf-s -miphoneos-version-min=$(ios) -isysroot $(sdk) -idirafter /usr/include -F/Library/Frameworks
50
e17a8c4f 51all: MobileCydia
dc5812ec 52
5f6bff8c 53clean:
e17a8c4f 54 rm -f MobileCydia
5f6bff8c 55
b7cc8ce2 56MobileCydia: MobileCydia.mm UICaboodle/*.h UICaboodle/*.mm iPhonePrivate.h
e17a8c4f 57 $(cycc) $(filter %.mm,$^) $(flags) $(link) $(uikit)
b7cc8ce2 58 ldid -Slaunch.xml $@ || { rm -f $@ && false; }
03c0f7a9 59
e17a8c4f
JF
60CydiaAppliance: CydiaAppliance.mm
61 $(cycc) $(filter %.mm,$^) $(flags) -bundle $(link) $(backrow)
62
63package: MobileCydia
7e2bd591 64 sudo rm -rf _
03c0f7a9
JF
65 mkdir -p _/var/lib/cydia
66
67 mkdir -p _/usr/libexec
c21004b9 68 cp -a Library _/usr/libexec/cydia
7e2bd591 69 cp -a sysroot/usr/bin/du _/usr/libexec/cydia
03c0f7a9
JF
70
71 mkdir -p _/System/Library
c21004b9 72 cp -a LaunchDaemons _/System/Library/LaunchDaemons
03c0f7a9
JF
73
74 mkdir -p _/Applications
e17a8c4f
JF
75 cp -a MobileCydia.app _/Applications/Cydia.app
76 cp -a MobileCydia _/Applications/Cydia.app/MobileCydia
77
78 #mkdir -p _/Applications/Lowtide.app/Appliances
79 #cp -a Cydia.frappliance _/Applications/Lowtide.app/Appliances
80 #cp -a CydiaAppliance _/Applications/Lowtide.app/Appliances/Cydia.frappliance
03c0f7a9
JF
81
82 mkdir -p _/System/Library/PreferenceBundles
c21004b9 83 cp -a CydiaSettings.bundle _/System/Library/PreferenceBundles/CydiaSettings.bundle
03c0f7a9
JF
84
85 mkdir -p _/DEBIAN
86 echo "$$(cat control)"$$'\nInstalled-Size: '"$$(du -s _ | cut -f 1)" > _/DEBIAN/control
87
7e2bd591
JF
88 sudo chown -R 0 _
89 sudo chgrp -R 0 _
e17a8c4f 90 sudo chmod 6755 _/Applications/Cydia.app/MobileCydia
7e2bd591 91
c21004b9 92 $(dpkg) -b _ $(shell grep ^Package: control | cut -d ' ' -f 2-)_$(shell grep ^Version: control | cut -d ' ' -f 2)_iphoneos-arm.deb
8cc774c5
JF
93
94.PHONY: all clean sign