Invalid Swift Support - Files not in right location

最后都变了- 提交于 2019-12-22 07:03:26

问题


I've been trying to upload a new build to iTunes Connect to update an app. I first used xCode 6 but got a email from Apple stating this:

Dear Developer,

We have discovered one or more issues with your recent delivery for "App". To process your delivery, the following issues must be corrected:

Invalid Swift Support - The files libswiftDarwin.dylib, libswiftDispatch.dylib, libswiftCoreGraphics.dylib, libswiftUIKit.dylib, libswiftContacts.dylib, libswiftCore.dylib, libswiftCoreAudio.dylib, libswiftFoundation.dylib, libswiftXCTest.dylib, libswiftCoreImage.dylib, libswiftObjectiveC.dylib aren’t at the expected location /Payload/App.app/Frameworks.

Move the file to the expected location, 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.

I thought it was a simple fix, so I just updated to the latest GM (Xcode 7.2) & completed the Swift 2 migration, however I received the same email. Could someone explain how to solve this and what those files are? This isn't a "files don't match" problem as seen in other questions.


回答1:


I stumbled upon this as I've encountered the same problem. It's the first time I've been tasked with handling the release of a Swift app to the App Store.

I found that this answer by TALAA works a treat: https://stackoverflow.com/a/26949219/1567836

There is an "Embedded Content Contains Swift Code" flag in the Build Settings that needs to be set to YES. After setting this, clean the project before building again.

After the clean, you'll have to recreate a build to upload to the App Store. You might find that the new upload will get rejected claiming that a binary already exists for that number. If you update the build number (has to be larger than the previous one) then the new upload will be accepted.




回答2:


As per the @Thomas You need to enable that flag and after that for the "Invalid Swift Support", I had the issues with Application Loader since Xcode 6.4. So, I started uploading the app from the "Organizer" (Xcode > Window > Organizer > Upload to App Store).

This solves the problem.




回答3:


Inspect the payload and also the SwiftSupport folder in the .ipa file (by converting it to a .zip) and make sure the libraries in the email match across both those directories. Those need to match apparently.

You should probably not have libswiftXCTest.dylib in the Payload/App.app/Frameworks or SwiftSupport folders in something you're submitting to Apple. If you do, check the build section of the scheme for your App target and make sure you aren't including any test targets in your Archive step.



来源:https://stackoverflow.com/questions/34602859/invalid-swift-support-files-not-in-right-location

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!