我尝试了这一步:
选择菜单选项“Project > New Build Phase > New Run Script Build Phase”,然后输入以下脚本(不要忘记将 /Users/youruser/bin 替换为 gen_entitlements.py 的正确路径):
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 中删除“运行脚本构建阶段”构建阶段?