]> git.saurik.com Git - cydget.git/blob - makefile
Update copyright date and correct name in license.
[cydget.git] / makefile
1 webcore := WebCore-514
2 jscore := JavaScriptCore-521
3
4 cycc = cycc -i2.0 -o$@ -- $(filter %.mm,$^) -Xarch_armv6 -marm -g0 -O2 -I. -F/System/Library/PrivateFrameworks
5
6 all: CydgetLoader.dylib WebCycript WebCycriptLockScreen CydgetSettings
7
8 clean::
9 rm -f CydgetLoader.dylib CydgetSettings WebCycriptLockScreen
10
11 CydgetLoader.dylib: CydgetLoader.mm makefile
12 $(cycc) -dynamiclib -framework Foundation -framework UIKit -framework CydiaSubstrate
13
14 CydgetSettings: CydgetSettings.mm makefile
15 $(cycc) -dynamiclib -framework Foundation -framework UIKit -framework Preferences
16
17 WebCycript: WebCycript.mm yieldToSelector.mm makefile
18 $(cycc) -dynamiclib -isystem sysroot/usr/include \
19 -install_name /Library/Frameworks/WebCycript.framework/WebCycript \
20 -framework Foundation -framework UIKit \
21 -framework CydiaSubstrate -framework CFNetwork \
22 -framework JavaScriptCore -framework WebKit \
23 -Wl,-U,__ZN3JSC7UString3Rep7destroyEv \
24 -Wl,-U,__ZN3JSC7UStringC1EPKc \
25 -Wl,-U,__ZN3JSC7UStringC1EPKti \
26 -Wl,-U,__ZNK3JSC7UString6substrEii
27 install_name_tool -change /System/Library/{,Private}Frameworks/JavaScriptCore.framework/JavaScriptCore $@
28 ldid -S $@
29
30 WebCycriptLockScreen: WebCycript LockScreen.mm makefile
31 $(cycc) -bundle -isystem sysroot/usr/include \
32 -framework Foundation -framework UIKit \
33 -framework CydiaSubstrate WebCycript \
34 -framework TelephonyUI -framework SpringBoardUI \
35 -Xarch_armv6 -Lsysroot/usr/lib -Xarch_armv6 -lpcre \
36 -Xarch_arm64 -DUSE_ICU_REGEX -Xarch_arm64 -licucore
37
38 webcycript-deb: all
39 sudo rm -rf package
40 mkdir -p package/DEBIAN
41 mkdir -p package/Library/MobileSubstrate/DynamicLibraries
42 sed -e 's/%/$(shell cycc -V)/' webcycript.in >package/DEBIAN/control
43 mkdir -p package/Library/Frameworks/WebCycript.framework/Headers
44 cp -a WebCycript.plist package/Library/Frameworks/WebCycript.framework/Info.plist
45 cp -a WebCycript package/Library/Frameworks/WebCycript.framework
46 cp -a WebCycript.h package/Library/Frameworks/WebCycript.framework/Headers
47 sudo chown -R 0 package
48 sudo chgrp -R 0 package
49 deb=$$(grep ^Package: package/DEBIAN/control | cut -d ' ' -f 2-)_$$(grep ^Version: package/DEBIAN/control | cut -d ' ' -f 2)_iphoneos-arm.deb; dpkg-deb -b package "$$deb"; ln -sfv "$$deb" webcycript.deb
50
51 cydget-deb: all
52 sudo rm -rf package
53 mkdir -p package/DEBIAN
54 mkdir -p package/Library/MobileSubstrate/DynamicLibraries
55 sed -e 's/%/$(shell cycc -V)/' cydget.in >package/DEBIAN/control
56 cp -a preinst package/DEBIAN
57 mkdir -p package/Library/PreferenceLoader/Preferences;
58 cp -a CydgetLoader.{dylib,plist} package/Library/MobileSubstrate/DynamicLibraries
59 mkdir -p package/System/Library/LockCydgets
60 cp -a Welcome.cydget package/System/Library/LockCydgets/Welcome.cydget
61 cp -a AwayView.cydget package/System/Library/LockCydgets/AwayView.cydget
62 cp -a PhotoExample.cydget package/System/Library/LockCydgets/PhotoExample.cydget
63 cp -a PhotoExamplePlus.cydget package/System/Library/LockCydgets/PhotoExamplePlus.cydget
64 mkdir -p package/System/Library/SpringBoardPlugins/WebCycriptLockScreen.bundle
65 cp -a WebCycriptLockScreen.plist package/System/Library/SpringBoardPlugins/WebCycriptLockScreen.bundle/Info.plist
66 cp -a WebCycriptLockScreen package/System/Library/SpringBoardPlugins/WebCycriptLockScreen.bundle
67 mkdir -p package/Library/PreferenceLoader/Preferences
68 mkdir -p package/System/Library/PreferenceBundles
69 cp -a CydgetSettings.plist package/Library/PreferenceLoader/Preferences
70 cp -a CydgetSettings.bundle package/System/Library/PreferenceBundles/CydgetSettings.bundle
71 cp -a Icon-Small.png package/System/Library/PreferenceBundles/CydgetSettings.bundle/icon.png
72 cp -a SearchResultsCheckmarkClear.png CydgetSettings package/System/Library/PreferenceBundles/CydgetSettings.bundle
73 sudo chown -R 0 package
74 sudo chgrp -R 0 package
75 deb=$$(grep ^Package: package/DEBIAN/control | cut -d ' ' -f 2-)_$$(grep ^Version: package/DEBIAN/control | cut -d ' ' -f 2)_iphoneos-arm.deb; dpkg-deb -b package "$$deb"; ln -sfv "$$deb" cydget.deb
76
77 deb: webcycript-deb cydget-deb