Both for kicks and for budgetary reasons, I'd like to take a package that would normally require a developer account and build an app to run on a jailbroken iOS device.
I have a 5th gen iPod Touch, jailbroken using evasi0n, running iOS 6.1.
I am using Xcode 4.6 with OS X (10.8.2) Lion.
Best Answer
The following instructional steps to accomplish this purpose are taken from: http://iphonedevwiki.net/index.php/Xcode
My findings and actions are provided under each step.
1. Create a self-signed code-signing certificate with the name “iPhone Developer” on the “login” (default) keychain using Keychain Access.
2. Open
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Info.plist
(4.2 or below:/Developer/Platforms/iPhoneOS.platform/Info.plist
). You may need root permission..plist
file.3. Replace all occurrences of
XCiPhoneOSCodeSignContext
byXCCodeSignContext
. There are three of them (XCode Version 3.2.4+).4. Save the file and restart Xcode.
5. Make sure you have ldid on your Mac. Place a copy somewhere e.g. in
/usr/local/bin
./usr/local/bin
.6. Create the a Python script ldid3.py right next to the ldid program. Make it executable. Fill it with:
ldid3.py
and stored it in the/usr/local/bin
directory.chmod 777 /usr/local/bin/ldid3.py
.7. Open
iPhoneCodeSign.xcspec
. This file can be found in [For Xcode 4.6:/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Xcode/Specifications/iPhoneCodeSign.xcspec
]:8. Change the entry in the file from calling
codesign
toldid3.py
.sudo plutil -convert xml1 /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Xcode/Specifications/iPhoneCodeSign.xcspec
<key>CommandLine</key><string>/usr/bin/codesign</string>
with<key>CommandLine</key><string>/usr/local/bin/ldid3.py</string>
.9. Save the file and restart Xcode.
10. Create a file
/var/mobile/tdmtanf
on the device, to enable Apple's "TDMTANF bypass" in installd (warning: doing so will also put you in a sandboxed GameCenter).tdmtanf
, SSH'd into my iPod, uploaded it to/var/mobile/
, and reboot my iPod.Now that all that is over with...
I open my existing Xcode project and hit Run. It works in the iOS Simulator without any problems.
I make sure that Code Signing is set to use the certificate set up in step 1.
I build the app (Project > Build). A success message follows.
I grab my app folder
TicTacToe.app
from/Libary/Developer/Xcode/DerivedData/TicTacToe-cjgzmoxtflyegtfypsbxbuiuwxns/Build/Products/Debug-iphoneos/
and transfer it to my Windows machine to install onto my iPod.In an attempt to install the app to my iPod, I drag
TicTacToe.app
onto the applications section of iPhone Configuration Utility, but I received this error message saying that my app "is not a valid mobile application."I have also tried manually installing the app using iFunbox and the AppCake app found in Cydia. Both fail.
As a point of interest, because as I've Googled around, I've noticed many people mention the importance of this: I do have AppSync installed. (Sorry for the huge screenshot. If I should take it down, please let me know!)
Conclusion
So despite following the instructions closely, several times, my app is not recognized by iPhone Configuration Utility as a valid app. I cannot install the app manually using programs like iFunbox, or Cydia apps like AppCake.
I suspect the app is indeed invalid, but having followed the instructions carefully, I'm not sure why.
Can anyone tell me why my app is not valid, and what I can do to fix this, besides coughing up money that is?