如何修复"IPA处理失败"?Xcode 11中的错误? [英] How to fix "IPA processing failed" error in xcode 11?

查看:70
本文介绍了如何修复"IPA处理失败"?Xcode 11中的错误?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我尝试使用Distribute APP选项创建IPA文件时.它给出了"IPA处理失败"错误.

When I tried to create IPA file using Distribute APP option. It gave "IPA processing failed" error.

我已经检查了日志文件: IDEDistribution.standard.log 文件.

I have checked logs file: IDEDistribution.standard.log file.

2019-08-06 18:36:52 +0000警告:配置问题:平台iPhoneSimulator.platform没有任何非模拟器SDK;忽略它正在扫描IPA ... 2019-08-06 18:36:52 +0000断言失败:otool输出中预期有4个弓:/var/folders/4t/rpjk7pd55t16jfrd32y98gf0lb2t68/T/IDEDistributionOptionThinning.~~~a4cZJc/Payload/demo.app/Frameworks/AppAuth.framework/AppAuth:马赫头魔术cputype cpusubtype caps文件类型ncmds sizeofcmds标志MH_MAGIC_64 X86_64 ALL 0x00 DYLIB 23
3680 NOUNDEFS DYLDLINK TWOLEVEL NO_REEXPORTED_DYLIBS加载命令0

2019-08-06 18:36:52 +0000 warning: Configuration issue: platform iPhoneSimulator.platform doesn't have any non-simulator SDKs; ignoring it Scanning IPA... 2019-08-06 18:36:52 +0000 Assertion failed: Expected 4 archs in otool output: /var/folders/4t/rpjk7pd55t16jfrd32y98gf0lb2t68/T/IDEDistributionOptionThinning.~~~a4cZJc/Payload/demo.app/Frameworks/AppAuth.framework/AppAuth: Mach header magic cputype cpusubtype caps filetype ncmds sizeofcmds flags MH_MAGIC_64 X86_64 ALL 0x00 DYLIB 23
3680 NOUNDEFS DYLDLINK TWOLEVEL NO_REEXPORTED_DYLIBS Load command 0

推荐答案

我遇到了同样的问题.我已使用此脚本修复了此问题.
请遵循相同的步骤.

I faced same issue.I have fix this issue used this script.
Please follow the same steps.

构建阶段->加号按钮->创建新的运行脚本阶段

Build Phases -> plus button -> to create New Run Script Phase

 APP_PATH="${TARGET_BUILD_DIR}/${WRAPPER_NAME}"

find "$APP_PATH" -name '*.framework' -type d | while read -r FRAMEWORK
do
FRAMEWORK_EXECUTABLE_NAME=$(defaults read "$FRAMEWORK/Info.plist" CFBundleExecutable)
FRAMEWORK_EXECUTABLE_PATH="$FRAMEWORK/$FRAMEWORK_EXECUTABLE_NAME"
echo "Executable is $FRAMEWORK_EXECUTABLE_PATH"
echo $(lipo -info "$FRAMEWORK_EXECUTABLE_PATH")

FRAMEWORK_TMP_PATH="$FRAMEWORK_EXECUTABLE_PATH-tmp"

case "${TARGET_BUILD_DIR}" in
*"iphonesimulator")
    echo "No need to remove archs"
    ;;
*)
    if $(lipo "$FRAMEWORK_EXECUTABLE_PATH" -verify_arch "i386") ; then
    lipo -output "$FRAMEWORK_TMP_PATH" -remove "i386" "$FRAMEWORK_EXECUTABLE_PATH"
    echo "i386 architecture removed"
    rm "$FRAMEWORK_EXECUTABLE_PATH"
    mv "$FRAMEWORK_TMP_PATH" "$FRAMEWORK_EXECUTABLE_PATH"
    fi
    if $(lipo "$FRAMEWORK_EXECUTABLE_PATH" -verify_arch "x86_64") ; then
    lipo -output "$FRAMEWORK_TMP_PATH" -remove "x86_64" "$FRAMEWORK_EXECUTABLE_PATH"
    echo "x86_64 architecture removed"
    rm "$FRAMEWORK_EXECUTABLE_PATH"
    mv "$FRAMEWORK_TMP_PATH" "$FRAMEWORK_EXECUTABLE_PATH"
    fi
    ;;
esac

echo "Completed for executable $FRAMEWORK_EXECUTABLE_PATH"
echo $(lipo -info "$FRAMEWORK_EXECUTABLE_PATH")

done

这篇关于如何修复"IPA处理失败"?Xcode 11中的错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆