Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR ITMS-90087: "Unsupported Architectures #10

Open
Allan-Nava opened this issue Aug 25, 2017 · 1 comment
Open

ERROR ITMS-90087: "Unsupported Architectures #10

Allan-Nava opened this issue Aug 25, 2017 · 1 comment

Comments

@Allan-Nava
Copy link

I have this problem when I i try to upload the Archive Release.

ERROR ITMS-90087: "Unsupported Architectures. The executable for Sportube.app/Frameworks/GoogleCast.framework contains unsupported architectures '[x86_64, i386]'."

But I use a Run Script in Pre-Actions:

#!/bin/bash

# This script strips unused architectures from any frameworks embedded in an
# app bundle. It should be called from an Xcode project as a post-build step.

if [ -z "${TARGET_BUILD_DIR}" ]; then
  echo "This script should be invoked from an Xcode project."
  exit 1
fi

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

framework_dirs=($(find "${app_dir}" -type d -name '*.framework'))
for framework_dir in "${framework_dirs[@]}"; do
  framework_name=$(defaults read "${framework_dir}/Info.plist" CFBundleExecutable)

  if [ !-z "$framework_name" ]; then
    framework_path="${framework_dir}/${framework_name}"

    echo "Removing unused architectures from framework: ${framework_name}"

    slice_paths=()
    for arch in ${ARCHS}; do
      slice_path="${framework_path}_${arch}"
      lipo "${framework_path}" -extract "${arch}" -output "${slice_path}"
      slice_paths+=("${slice_path}")
    done

    lipo "${slice_paths[@]}" -create -output "${framework_path}_thinned"
    rm -f "${slice_paths[@]}"

    rm -f "${framework_path}"
    mv "${framework_path}_thinned" "${framework_path}"
  fi
   
done
@Allan-Nava
Copy link
Author

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant