集齐召唤本帅哥...
-
ERROR ITMS-90087 、90209 、90125
原因:
这个SDK里面包含了x86_64, i386 [架构],当然这个AppStore是不允许的,所有会在上传的时候报错,解决办
法就是要这个SDK剔除掉x86_64, i386这两个架构。
怎么解决呢?
尝试解决办法1:
TARGETS->Build Phases->点击加号选择New Run Script Phase->然后复制粘贴下面代码
----------------------------------------------------------------------
APP_PATH="${TARGET_BUILD_DIR}/${WRAPPER_NAME}"
# This script loops through the frameworks embedded in the application and
# removes unused architectures.
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"
EXTRACTED_ARCHS=()
for ARCH in $ARCHS
do
echo "Extracting $ARCH from $FRAMEWORK_EXECUTABLE_NAME"
lipo -extract "$ARCH" "$FRAMEWORK_EXECUTABLE_PATH" -o "$FRAMEWORK_EXECUTABLE_PATH-$ARCH"
EXTRACTED_ARCHS+=("$FRAMEWORK_EXECUTABLE_PATH-$ARCH")
done
echo "Merging extracted architectures: ${ARCHS}"
lipo -o "$FRAMEWORK_EXECUTABLE_PATH-merged" -create "${EXTRACTED_ARCHS[@]}"
rm "${EXTRACTED_ARCHS[@]}"
echo "Replacing original executable with thinned version"
rm "$FRAMEWORK_EXECUTABLE_PATH"
mv "$FRAMEWORK_EXECUTABLE_PATH-merged" "$FRAMEWORK_EXECUTABLE_PATH"
done
---------------------------------------------------------------------------
运行时出现:Command /bin/sh failed with exit code 2 报错
想了一会才发现我这个是环信的sdk,文档里有见到过这个错误解决办法 o。0
所以 按上图操作
1、cd 到存在sdk的根目录(cd /Users/linhuaqin/Downloads/iOS_IM_SDK_V3.4.2/HyphenateFullSDK)
2、键入 lipo Hyphenate.framework/Hyphenate -thin armv7 -output Hyphenate_armv7
3、键入 lipo Hyphenate.framework/Hyphenate -thin arm64 -output Hyphenate_arm64
4、lipo -create Hyphenate_armv7 Hyphenate_arm64 -output Hyphenate
5、mv Hyphenate Hyphenate.framework/
运行成功后下图就是最后的结果,再把之前的删掉,重新把文件导进去,并且工程要设置编译二进制文件General->Embedded Bunaries
编译成功