Invalid Swift Support when submitting App - swift

A while back I was trying to submit an App using Xcode version 11.1 (11A1027) but I received an email from Apple with the following message:
ITMS-90424: Invalid Swift Support - The SwiftSupport folder is empty. Rebuild your app using the current public (GM) version of Xcode and resubmit it.
From what I know, 11A1027 is already a released version and so I am not very sure why there is a need to use the GM version of Xcode. Does anyone have any idea?
I tried some of the methods suggested in other posts but somehow could not resolve it.
Is this a bug in Xcode?

Solved for me in June 2020.
MacOS Catalina 10.15.5
Xcode Version 11.5 (11E608c)
Check that Command line tools(Xcode->Preferences->Locations) have this value
Configure PROJECT in project settings
Click to you project in Xcode.
Select project name
Set filter to Basic and Levels
Find Always Embed Swift Standard Libraries field (if not found - play with filters)
Set YES to this field for PROJECT(debug and release)
Configure TAGET in target settings
Click to you project in Xcode.
Select target name
Set filter to Basic and Levels
Find Always Embed Swift Standard Libraries field (if not found - play with filters)
Set YES to this field for PROJECT(debug and release) and set NO to this field for TARGET(debug and release)
see example
Clean project and create archive(Product->Archive)
In the dialog window right click to the created archive name -> Show in Finder
Right click to the archive name in Finder -> Show Package Contents
Delete SwiftSupport folder here
After that upload your build using AppStore Connect in Xcode with default settings.

I received this same email after uploading an .ipa file to App Store Connect through the Transporter app. The following is where I went wrong: I distributed the app using ad hoc.
The following steps are the solution for my error:
Archive app
Distribute on TestFlight and the App Store
Export
Open ExportOptions.plist in the newly created folder from the export.
Make sure the method property has the value app-store if you are uploading to App Store Connect/TestFlight like me.
Drag and drop the exported .ipa file to Transporter.
Deliver your app to upload it.
And that's it!
Original answer here: https://stackoverflow.com/a/62568526/10374366

I don’t think it’s a bug. But the best thing you can do is to just reinstall Xcode from the AppStore.

The solution here was in this "Invalid Swift Support - The SwiftSupport folder is missing" with Xcode 7.3.1. 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.

Try upgrading to swift 5.0 and going to workspace settings, build system and set it to New Build System. This solved it for me in a React Native project using native iOS views. As far as I know swift 5 makes doesn't use the swift support folder any more.

Related

XCode - ITMS-90426: Invalid Swift Support

I receive the following mail after the upload of my app form xCode to the Apple Connect platform.
Dear Developer,
We identified one or more issues with a recent delivery for your app, <APPNAME> 0.23.0 (10). Please correct the following issues, then upload again.
ITMS-90426: Invalid Swift Support - The SwiftSupport folder is missing. Rebuild your app using the current public (GM) version of Xcode and resubmit it.
Best regards,
The App Store Team
Before uploading, I correctly validate the version, and xcode gives me the validation.
Do someone know how resolve this issue?
I have tried to follow some other Stakoverflow answers:
Go to Targets > YourApp > Build Settings
Defines Module: No
Always Embed Swift Standard Libraries: Yes
With no results
I'm running MacOS Ventura 13.1 and Xcode 14.2

Invalid Swift Support - The SwiftSupport folder is missing

I have updated a currently submitted Titanium app and added a watch extension using swift.
Everything works fine if I build and test on sim and build directly to device. I only get an issue when I submit the app to the Apple app store (via XCode Organizer).
The binary submits, passing validation but I get am email from iTunes Connect as follows:
Dear developer,
We have discovered one or more issues with your recent delivery for "xxxxxxxxxxx". To process your delivery, the following issues must be corrected:
Invalid Swift Support - The SwiftSupport folder is missing. Rebuild your app using the current public (GM) version of Xcode and resubmit it.
Once these issues have been corrected, you can then redeliver the corrected binary.
It seems as though it may be related to a build setting: Embedded Content Contains Swift Code.
It looks like this needs to be set to Yes if the Titanium project contains embedded Swift.
As of now I am stuck as I cannot submit the app. Is this a Ti problem or is there another step I should follow?
XCode: 7.3, SDK: 5.2.2.GA - Project created and built using only the Ti CLI.
First you should check your .ipa file by
unzip yourapp.ipa
If the only Payload exists, the Apple reject your app.
You should create SwiftSupport/iphoneos directory and put the appropriate
swift library files.
You can know which libraries are necessary by checking Payload/yourapp.app/Framesworks. But this library files can not be used as SwiftSupport/iphoneos.
You must copy the appropriate libraries from your mac's /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphoneos directory. The file names are same as the above Payload/yourapp.app/Frameworks but the contents are different.
After you get the Payload and SwiftSupport directory, do package these directories by
$ zip -r yournewapp.ipa Payload SwiftSupport
(Remark: remove all .DS_Store files if exist)
Then Apple accespt yournewapp.ipa.
For future reference: I had to Archive the Titanium project through Xcode because one of my third-party libraries requested to execute a script in the Build phases.
Received the same message from Apple and fortunately fixed it just changing the Embedded Content Contains Swift Code to No.
You should choose "Save for iOS App Store Deployment" option at the time of exporting ipa file.
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.

avoid SwiftSupport folder in .ipa

In latest Xcode 7.1.1, ipa created has SwiftSupport folder. It increased ipa size around 20MB.
Old Xcode not added SwiftSupport folder inside ipa
How to avoid SwiftSupport folder in ipa ?
Disable "Embedded Content Contains Swift Code" in your application build settings.
As #Rob Napier mentioned, but you can also set this flag to NO if you have a swift code project. The flag only means if you have an ObjC project which includes Swift code via a framework to indicate that you need swift support.
HOWEVER, it does not matter how big your IPA file is (if that's your concern) because Apple removes the folders on processing via iTunes connect As stated by an Apple Developer in the forums: https://forums.developer.apple.com/thread/16339
In addition to the other explanations I would also recommend to upgrade to Xcode 7.2. According to my research, there is no "SwiftSupport" folder included when building the ipa file when using Xcode 7.2. (As indicated by other answers, it is assumed you are not using Swift in the project.)
Disable "Embedded Content Contains Swift Code" in your application build settings.
This of course assumes that you don't have any Swift code in your project. If you do, then you need to include the Swift standard libraries, which are contained in that folder.
The default for this setting is "No" so it's likely that something you're importing (CocoaPods?) is setting it. Or that something you're importing actually has Swift code in it....

Cannot find location of realease file

I've recently upgraded my XCode to 4.3.2 and also my OS to Lion so that my apps can work with IOS 5.1 plus. I'm now trying to upgrade a couple of old apps and I can't find where the app files are to upload to Apple.
The strange thing is that I can use Terminal to locate where my DerivedData folder is but when I try to use Finder the Library folder does not exist. Is there anything I am missing because Xcode tells me the path to me build file is /Users/SC/Library/Developer/XCode/DerivedData/MyAppFolder/... but I cannot find it when using Finder. When I use Finder the Library folder does not appear even though it shows up when I use Terminal.
After you build and archive in XCode 4, you can go to Window>Organizer>Archives to view all your builds. You can validate and submit any build from there or right click and choose 'Show in Finder' to locate the app.
Ps. See my comment regarding the user library in Lion

SDK Verision dont match

hi my IPhone device has 4.2.1 version, my xcode is saying 4.2 version. Is this any issue because i cant debug my app on device. also the developer folder has iphoneentitlements401 folder, shouldnt it be 4.2 instead of 401?
i am getting cannot read entitlements data ERROR. please help!
SDK Support:
You need to set your IOS Deployment Target to the lowest SDK you want to support. So you would need to set yours to at least 4.2.
Go to Project -> Edit Project Settings -> Scroll down to Deployment, then find IOS Deployment Target
For Entitlements:
Your entitlements file, if it exists, may be corrupt, remove it if you have it, then add a new one:
Right-click on your Project, then click Add, then New File and under iOS click on Code Signing and choose Entitlements.