Swiftsupport Folder Not Included in The IPA When Generating Build from Script

SwiftSupport folder not included in the IPA when generating build from script

After your PackageApplication step, you should have an .xcarchive and an .ipa. I can't be sure why you don't have a SwiftSupport folder in your original .ipa (in my case it was because it was exported for enterprise distribution), but you should be able to just copy the SwiftSupport folder from the .xcarchive into your unzipped .ipa, right after the unzip step:

unzip -q "$APP_IPA" -d "$IPA_DIR"

# Copies the SwiftSupport folder from the .xcarchive into the .ipa
mkdir -p "${IPA_DIR}/SwiftSupport/iphoneos"
cd "${archivePath}/SwiftSupport/iphoneos"
for file in *.dylib; do
cp "$file" "${IPA_DIR}/SwiftSupport/iphoneos"
done

You can also create the SwiftSupport folder using the Xcode toolchain like this:

# Creates the SwiftSupport folder from the Xcode toolchain and copies it into the .ipa
mkdir -p "${IPA_DIR}/SwiftSupport/iphoneos"
cd "${IPA_DIR}/Payload/${appName}.app/Frameworks"
for file in *.dylib; do
cp "${toolchainPath}/${file}" "${IPA_DIR}/SwiftSupport/iphoneos"
done

This looks in the .app/Frameworks folder to see which .dylib files should be in the SwiftSupport folder.

For Xcode 11, this should be the toolchain path:

/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift-5.0/iphoneos

Invalid Swift Support / The SwiftSupport folder is empty

important note: this only works for projects that do not use swift, see comment below

I just met the same issue and resolved it by making the following change -
If you used to have Swift files in your project but then removed them, you only need to set "Embedded Content Contains Swift Code" to NO in Build Options.

Invalid Swift Support - The SwiftSupport folder is missing

This issue has now be resolved, there is a new version of the Titanium SDK, 6.0.1.GA that specifically has a fix in for this issue. I have now created, submitted and have a Titanium app with associated watch app now published in the app store.

Invalid Swift Support - The SwiftSupport folder is missing with Xcode 7.3.1

The solution here was in this answer. We needed to use the new -exportOptionsPlist flag with xcodebuild instead of the older -exportFormat and -exportWithOriginalSigningIdentity flags. The plist just needs to have the method key set to app-store.

SwiftSupport folder when building Jenkins WatchKit app

When archiving an app the .xcarchive contains a SwiftSupport folder with those .dylib files. You can use this folder when creating your .ipa.

Just make sure the SwiftSupport folder is a sibling of the Payload folder in the .ipa, otherwise you will get an 'Invalid Swift Support' error in iTunes Connect.

Invalid Swift Support - The SwiftSupport folder is empty

This issue has been resolved by setting the deployment target same for all extensions added in project.

Initially RN project having 11.0 deployment target and newly added watch having latest one 13.0 so swift folder is not created automatically. after modifying all to 12.0, it works automatically without doing any manual step.

Invalid Swift Support - The SwiftSupport folder is missing with Xcode 7.3.1

The solution here was in this answer. We needed to use the new -exportOptionsPlist flag with xcodebuild instead of the older -exportFormat and -exportWithOriginalSigningIdentity flags. The plist just needs to have the method key set to app-store.



Related Topics



Leave a reply



Submit