What do you need ?
Software in computer
Software in iPhone
* Those programs are in /usr/bin of Jailbreak iPhone.
Step 1 : Program Folder
(1) Create a folder to make a package such as 'myprogram'
(2) Copy the program files for install, the folder structure is identical with / of iPhone. Such as If you put ‘myapplication.app’. This folder should be located in myprogram/Applications/myapplicaiton.app.
(3) Create ‘DEBIAN’ folder and make a ‘control’, ‘prerm’, and ‘postinst’ files. ‘prerm’ and ‘postinst’ files are optional.
Step 2 : Create ‘control’ file.
you should create a ‘control’ file using any TextEditor such as WordPad in windows. ‘dpkg-deb’ program will use this file to make a program database.
Example of ‘control’
Description: this is the sample ‘control’ file for me.
this is additional line with one space in beginning of this sentence.
Maintainer: bomijoa <email@example.com>
Pre-Depends: firmware (>= 3.0)
Depends: mobilesubstrate (>= 0.9.3228-1)
- Package: this is a unique identifier for the program, and it is same as ‘bundleIdentifier’ in Info.plist.
- Name: the program name. This name will be listed in Cydia
- Version: just version string
- Architecture: just use ‘iphoneos-arm’
- Description: the description of packages. You can use multiple line description. But, you should insert a space of each line. And, you cannot use ‘:’ in your description.
- Homepage: it is optional; you can put your homepage for this program. this information will display by ‘More Info’ button in Cydia
- Depiction: it is optional; this is used for external link or screen shot. And, same as Homepage
- Sponsor: it is optional; Website of sponsor
- Maintainer: The person who builds and maintains this package. Email address can be input in ‘< >’
- Author: the name and email address of programmer.
- Section: the section name in Cydia.
- Pre-depends: it is optonal; any requirements or additional software to run with you your program.
- Depends: it is optional; you can specify a package identifier of the additional software to run with your program.
* you have to insert a blank line at end of control file.
Step 3 : Create ‘postinst’ and ‘prerm’
Those files are just simple text file. And It includes some commands to run before the install (prerm) or after install (postinst) your program.
example of 'prerm'
example of 'postinst'
Step 4 : Create DEB file using iPhone.
- Connect your iPhone using WinSCP
- Create a temporary folder such as ‘work’
- Copy [myprogram] folder which created in Step 1: into the temporary folder.
- and, Run this comman
chmod -R 775 myprogram
pkg-deb -b myprogram
myprogram.deb file wil be created in work folder.
You will get some warning messages, just igore it.
Reference : http://www.saurik.com/id/7