Open Allan-Nava opened 7 years ago
If you run the script manually do you see any errors?
When I try to run the script manually i got:
This script should be invoked from an Xcode project
And I use this guide to install GoogleCastFramework: https://developers.google.com/cast/docs/ios_sender_setup It is a dependency for jwplayer ios sdk
I change the bash script with:
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
And I use ionic build ios --release but when I try to upload in app store I have the same issue.
Thanks
That is the recommended of stripping unwanted architecture. Do you have the same issue with other apps that don't use the Cast SDK?
@entertailion Cast SDK is dependency for jwplayer iOS SDK
We don't have any other developers who are having this issue. There must be something particular about your apps dependencies that might be causing an issue with stripping the architectures. Have you reached out to the jwplayer team?
I know but the errors are:
ERROR ITMS-90087: "Unsupported Architectures. The executable for Sportube.app/Frameworks/GoogleCast.framework contains unsupported architectures '[x86_64, i386]'."
ERROR ITMS-90209: "Invalid Segment Alignment. The app binary at 'Sportube.app/Frameworks/GoogleCast.framework/GoogleCast' does not have proper segment alignment. Try rebuilding the app with the latest Xcode version."
ERROR ITMS-90125: "The binary is invalid. The encryption info in the LC_ENCRYPTION_INFO load command is either missing or invalid, or the binary is already encrypted. This binary does not seem to have been built with Apple's linker."
WARNING ITMS-90080: "The executable 'Payload/Sportube.app/Frameworks/GoogleCast.framework' is not a Position Independent Executable. Please ensure that your build settings are configured to create PIE executables. For more information refer to Technical Q&A QA1788 - Building a Position Independent Executable in the iOS Developer Library."
I donwload the manually GoogleCastFramework SDK from https://developers.google.com/cast/downloads/GoogleCastSDK-Public-3.5.3-Release-ios.zip
When I try to install the app manually it works, but when I try to upload to store I get errrors.
Just realized you are running this as a pre-build step. The script needs to run as a post build step.
Do I insert the script bash in Pre-Actions and Post-Actions for Archive Release?
@entertailion Still not working...
The script needs to be invoked in the post actions.
Also, the way your are running the script from the command line won't work, because $ARCHS won't be set. It's set by Xcode. If you wanted to run it manually you'd have to set it to the list of architectures that your'e building for, minus the x86 one.
@entertailion I add in post-actions but when I try to upload in App Store still not working..
Having Same problem
ERROR ITMS-90087: "Unsupported Architectures. The executable for Sportube.app/Frameworks/GoogleCast.framework contains unsupported architectures '[x86_64, i386]'." ERROR ITMS-90209: "Invalid Segment Alignment. The app binary at 'Sportube.app/Frameworks/GoogleCast.framework/GoogleCast' does not have proper segment alignment. Try rebuilding the app with the latest Xcode version."
Any one can help plz?
Any joy with this issue?
My app didn't pass automatic Apple Review because it 'contains unsupported architectures '[x86_64, i386]'. Are there any updates? It would helpful to add any script to strict 'unsupported architectures' to the 'Setup for Developing with the Cast Application Framework (CAF) for iOS' page
Opened a ticket to update to new unsupported architectures.
Anyone have a solution for this issue? I'm still getting it in 2021...
I have this problem when I i try to upload the Archive Release.
But I use a Run Script in Pre-Actions: