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
[SR-13803] Can’t archive App that uses a swift package with an xcframework #4481
Comments
@swift-ci create |
Comment by Uttam Pandey (JIRA) I'm having problem with archiving the project when I use xcframework as binary dependency inside Swift Package, tried to archive with different build configurations like Release, Debug, and Custom configurations. I'm getting error: "No such module found". I checked this in Xcode 12.4 but problem is still not solved. |
Comment by Fabio Tacke (JIRA) Same here. The issue is still present in Xcode 12.5 beta 3. |
fabiotacke (JIRA User) could you clarify what error you are seeing? This particular issue should be fixed in Xcode 12.5 beta 2, but it's possible you're seeing a different issue. |
Comment by Fabio Tacke (JIRA) That's interesting. I checked out the example project in the description above and tried archiving using Xcode 12.5 beta 3 and it indeed succeeded. However in my own project (iOS project using SPM) I'm dealing with a dependency which itself has dependency on swift-sodium which includes an XCFramework. I thought this was the same setup as described in the thread referenced in the description above but the issue ("No such module") remains even in beta 3. For more details about the specific case and a minimal example to reproduce the issue you can take a look at the recent comments of the GitHub issue. |
Comment by Rick M (JIRA) I'm running into this issue with Braintree. They claim a workaround, but it doesn't work for me. |
rmann (JIRA User), could you file a separate bug report with more details on how to reproduce your setup, the error you are seeing and what you've tried? You can link this one as related if you'd like. |
Comment by Rick M (JIRA) theindigamer (JIRA User) I posted the full project to Apple's bug reporter FB9121480. It's proprietary and didn't want to share it with the world. |
That works too, thanks! |
Comment by Rick M (JIRA) Another user out there has posted this small project that reproduces the problem: https://github.com/simonpierreroy/xcframework-issue He wrote this: braintree/braintree_ios#679 (comment) This seems to be a bug in the Xcode build system for swiftPM integration![]( Try this https://github.com/simonpierreroy/xcframework-issue and always clean in between it should fail) It does the same with my own local package that has an XCframework! Here is my feedback FB9125479 . I used this repo for my feedback to apple, since I was having the same issues with close source package I can not share. |
Comment by Simon McLoughlin (JIRA) I'm facing a very similar issue. When importing this swift package: https://github.com/jedisct1/swift-sodium which contains an `xcframework`. I regularly get build failures (locally and on CI) whenever its the first run or has been cleaned. To reproduce, create a package, add this as a dependency. Clean and build to see the issue. Build again and it will succeed. Clean and build again sometimes fails, sometimes passes. The sodium package is importing the C code from an xcframework. It looks like theres an issue in the build / import order. I'm building and running tests on my package via github actions, and its failing 50-70% of the time due to this. Becoming hugely problematic for us. Action is running on the latest Xcode 12.4. I've reproduced the issue locally on Xcode 12.5 |
Comment by Simon McLoughlin (JIRA) theindigamer (JIRA User) is there any update on this? The ticket not been assigned to anyone, has no labels etc. Xcode 12.5.1 seems to have made the issue worse, breaking the only workaround available |
There was an initial fix for this in Xcode 13 beta 3 (e.g. this release note)
But it looks like the fix only made the issue less frequent, but it still happens sometimes, as Rick M noted earlier in the thread. |
Comment by tigran ghazinyan (JIRA) The errors are different from Xcode 12 to 13, hopefully, this will be assigned to somebody soon |
Comment by Canius Chu (JIRA) There is another bug similar with the origin bug, |
This has been fixed in Xcode 12.5. |
Environment
Xcode Version 12.3 (12C33)
Additional Detail from JIRA
md5: c6a1645c0dfce3d2940b09dc2a5c8d57
Issue Description:
thread:
https://developer.apple.com/forums/thread/662247
reproduce project:
https://github.com/canius/ArchiveErrorDemo
feedback:
https://feedbackassistant.apple.com/feedback/8932696
The text was updated successfully, but these errors were encountered: