备注:
一.ios5.1.1越狱步骤
1.下载Absinthe 2.0 点击Jailbreak ,最后提示Done,enjoy!越狱完成
2.在Cydia中下载appsync for ios 5.0+
相关阅读:
iOS 5.1.1完美越狱(Absinthe 2.0)正式发布下载 http://www.linuxidc.com/Linux/2012-05/61148.htm
完美越狱工具Absinthe 2.0.1更新 修正Bug http://www.linuxidc.com/Linux/2012-05/61149.htm
二.xcode4.3.1真机调试步骤
1.创建证书
实用工具-钥匙串访问-证书助手-创建证书 名称填写:iPhone Developer 选中让我覆盖这些默认值 后面填好电子邮箱地址 选中代码签名 其他的默认就可以了

2.修改/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk目录下的 SDKSettings.plist文件
中<key>CODE_SIGNING_REQUIRED</key>
<string>YES</string>
<key>ENTITLEMENTS_REQUIRED</key>
<string>YES</string>
YES 改为NO

3.修改 /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform目录下 Info.plis中XCiPhoneOSCodeSignContext 修改为XCCodeSignContext
4.在命令提示符中执行下面代码(需联网)
mkdir /Applications/Xcode.app/Contents/Developer/iphoneentitlements
cd /Applications/Xcode.app/Contents/Developer/iphoneentitlements
curl -O http://www.alexwhittemore.com/iphone/gen_entitlements.txt
mv gen_entitlements.txt gen_entitlements.py
chmod 777 gen_entitlements.py

5.禁用Xcode自动的签名操作

6.添加自定义的生成后脚本,在Build Phases中添加一个Phase,右下角的Add Build Phase,然后单击Add Run Script,输入以下脚本
export CODESIGN_ALLOCATE=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/codesign_allocate
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" == "ipados" ]; then
/Applications/Xcode.app/Contents/Developer/iphoneentitlements/gen_entitlements.py "my.company.${PROJECT_NAME}" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent";
codesign -f -s "iPhone Developer" --entitlements "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/"
fi

7.连上ios设备,点击Product-Build For -Archiving 就可以在ios设备上真机进行调试。
未连接ios设备时 为灰色

三.ipa生成步骤
1.点击show in finder

2.将finder中以项目名命名的文件拖到iTunes中

3.再将iTunes中的应用拖到桌面上就可以生成ipa文件。
源码下载地址:
下载在Linux公社的1号FTP服务器里,下载地址:
FTP地址:ftp://www.linuxidc.com
用户名:www.linuxidc.com
密码:www.muu.cc
在 2012年LinuxIDC.com\6月\iOS版的Hello world
下载方法见 http://www.linuxidc.net/thread-1187-1-1.html
