我尝试了这一步:
选择菜单选项"Project> New Build Phase> New Run Script Build Phase",然后输入以下脚本(不要忘记用gen_entitlements.py的正确路径替换/ Users/youruser/bin):
export CODESIGN_ALLOCATE=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/codesign_allocate if [ "${PLATFORM_NAME}" == "iphoneos" ]; then /Users/youruser/bin/gen_entitlements.py "my.company.${PROJECT_NAME}" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent"; codesign -f -s "iPhone developer" --resource-rules "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/ResourceRules.plist" \ --entitlements "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/" fi
(来自链接)
现在我想从我的项目中删除这个脚本.如何从Xcode中删除"运行脚本构建阶段"构建阶段?
在目标中选择"运行脚本"阶段并将其删除.
对于xcode 4.5.1,外观略有不同,在运行脚本阶段单击一次,同时按功能+退格键(在mac上)删除.弹出对话框时,单击"删除".