Documentation

iOS App Store submissions

If you are building your app with Xcode 12, you will need to remove strip_wikitude_framework.sh and wikitude_bitcode.sh from the framework before archiving your build. Move them somewhere else in your system and follow the steps in the following sections.

Removing simulator architectures

To work around an Xcode App Store submission bug, the WikitudeNativeSDK.framework contains a shell script that removes the simulator architectures from the .framework. This script can either be run from the Terminal application or a Run Script Phase in Xcode.

Here is a snippet for the Terminal application. Note that the path to the script and the path to the WikitudeNativeSDK.framework needs to be known.

sh *PATH/TO/THE/WIKITUDE/SDK/PACKAGE*/Tools/Scripts/strip_wikitude_framework.sh -s -p *PATH/TO/THE/WikitudeNativeSDK.framework

To run this script in a Run Script Phase, simply copy the following snippet into a new Run Script Phase text field. Please make sure that the Run Script Phase is positioned right after the Embed Frameworks build phase (You can reorder individual build phases).

sh "${BUILT_PRODUCTS_DIR}/${FRAMEWORKS_FOLDER_PATH}/WikitudeNativeSDK.framework/strip_wikitude_framework.sh" -s -p "${BUILT_PRODUCTS_DIR}/${FRAMEWORKS_FOLDER_PATH}/WikitudeNativeSDK.framework"

If you are using Xcode 12 and have moved strip_wikitude_framework.sh from the framework to elsewhere in your system, the final Run Script Phase command will look like this: sh sh *PATH/TO/THE/SCRIPT*/strip_wikitude_framework.sh -s -p "${BUILT_PRODUCTS_DIR}/${FRAMEWORKS_FOLDER_PATH}/WikitudeSDK.framework"

Bitcode

The WikitudeNativeSDK.framework contains Bitcode information to support App Thinning. Building a .framework with bitcode enabled leads to a larger file size. In case the application that uses the WikitudeNativeSDK.framework does not support bitcode and file size is a problem, bitcode information can be removed using the wikitude_bitcode.sh shell script. This script can either be run from the Terminal application or a Run Script Phase in Xcode. Wikitude recommends to use the Terminal application to not unnecessarily increase build time.

Here is a snippet for the Terminal application. Note that the path to the script and the path to the WikitudeNativeSDK.framework needs to be known.

sh *PATH/TO/THE/WIKITUDE/SDK/PACKAGE*/Tools/Scripts/wikitude_bitcode.sh -s -p *PATH/TO/THE/WikitudeNativeSDK.framework

Here is a snippet for the Run Script Phase. Simply copy this snippet into the script phase text field:

sh "${BUILT_PRODUCTS_DIR}/${FRAMEWORKS_FOLDER_PATH}/WikitudeNativeSDK.framework/wikitude_bitcode.sh" -s -p "${BUILT_PRODUCTS_DIR}/${FRAMEWORKS_FOLDER_PATH}/WikitudeNativeSDK.framework"
If you are using Xcode 12 and have moved wikitude_bitcode.sh from the framework to elsewhere in your system, the final Run Script Phase command will look like this: sh sh *PATH/TO/THE/SCRIPT*/wikitude_bitcode.sh -s -p "${BUILT_PRODUCTS_DIR}/${FRAMEWORKS_FOLDER_PATH}/WikitudeSDK.framework"