MobileCydia
CydiaAppliance
_
+__
Cydia.deb
debs
.DS_Store
+++ /dev/null
-Package: cydia
-Priority: required
-Section: Packaging
-Maintainer: Jay Freeman (saurik) <saurik@saurik.com>
-Architecture: iphoneos-arm
-Version:
-Replaces: com.sosiphone.addcydia
-Depends: apr-lib, apt7-lib, apt7-key, darwintools, pcre, sed, shell-cmds, system-cmds, uikittools (>= 1.1.0)
-Pre-Depends: dpkg (>= 1.14.25-8)
-Conflicts: com.sosiphone.addcydia
-Description: graphical iPhone front-end for APT
-Name: Cydia Installer
-Author: Jay Freeman (saurik) <saurik@saurik.com>
-Depiction: http://cydia.saurik.com/info/cydia/
-Tag: purpose::uikit, cydia::essential, role::enduser
#!/bin/bash
-dir=$1
+src=$1
+dir=$2
dir=${dir:=_}
-sed -e "s@^\(Version:\).*@\1 $(./version.sh)@" control
+sed -e "s@^\(Version:\).*@\1 $(./version.sh)@" "${src}"
echo "Installed-Size: $(du -s "${dir}" | cut -f 1)"
--- /dev/null
+Package: cydia
+Priority: required
+Section: Packaging
+Maintainer: Jay Freeman (saurik) <saurik@saurik.com>
+Architecture: iphoneos-arm
+Version:
+Replaces: com.sosiphone.addcydia
+Depends: apr-lib, apt7-lib, apt7-key, cydia-lproj, darwintools, pcre, sed, shell-cmds, system-cmds, uikittools (>= 1.1.0)
+Pre-Depends: dpkg (>= 1.14.25-8)
+Conflicts: com.sosiphone.addcydia
+Description: graphical iPhone front-end for APT
+Name: Cydia Installer
+Author: Jay Freeman (saurik) <saurik@saurik.com>
+Depiction: http://cydia.saurik.com/info/cydia/
+Tag: purpose::uikit, cydia::essential, role::enduser
images := $(shell find MobileCydia.app -name '*.png')
images := $(images:%=Images/%)
+lproj_deb := debs/cydia-lproj_$(version)_iphoneos-arm.deb
+
all: MobileCydia
clean:
mkdir -p _/Applications
cp -a MobileCydia.app _/Applications/Cydia.app
+ rm -rf _/Applications/Cydia.app/*.lproj
cp -a MobileCydia _/Applications/Cydia.app/MobileCydia
cd MobileCydia.app && find . -name '*.png' -exec cp -af ../Images/MobileCydia.app/{} ../_/Applications/Cydia.app/{} ';'
#ln -s {/Applications/AppleTV,_/Applications/Lowtide}.app/Appliances/Cydia.frappliance
mkdir -p _/DEBIAN
- ./control.sh _ >_/DEBIAN/control
+ ./control.sh cydia.control _ >_/DEBIAN/control
cp -a preinst _/DEBIAN/
find _ -exec touch -t "$$(date -j -f "%s" +"%Y%m%d%H%M.%S" "$$(git show --format='format:%ct' | head -n 1)")" {} ';'
$(dpkg) -b _ Cydia.deb
@echo "$$(stat -L -f "%z" Cydia.deb) $$(stat -f "%Y" Cydia.deb)"
-package: debs/cydia_$(version)_iphoneos-arm.deb
+$(lproj_deb): $(shell find MobileCydia.app -name '*.strings')
+ sudo rm -rf __
+ mkdir -p __/Applications/Cydia.app
+
+ cp -a MobileCydia.app/*.lproj __/Applications/Cydia.app
+
+ mkdir -p __/DEBIAN
+ ./control.sh cydia-lproj.control __ >__/DEBIAN/control
+ cp -a preinst __/DEBIAN/
+
+ sudo chown -R 0 __
+ sudo chgrp -R 0 __
+
+ mkdir -p debs
+ ln -sf debs/cydia-lproj_$(version)_iphoneos-arm.deb Cydia_.deb
+ $(dpkg) -b __ Cydia_.deb
+ @echo "$$(stat -L -f "%z" Cydia_.deb) $$(stat -f "%Y" Cydia_.deb)"
+
+package: debs/cydia_$(version)_iphoneos-arm.deb $(lproj_deb)
.PHONY: all clean package sign