Skip to content
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

Module compiled with Swift 5.7 cannot be imported by the Swift 5.7.2 compiler #2628

Closed
StefanOltmann opened this issue Jan 19, 2023 · 2 comments · Fixed by #2636
Closed

Module compiled with Swift 5.7 cannot be imported by the Swift 5.7.2 compiler #2628

StefanOltmann opened this issue Jan 19, 2023 · 2 comments · Fixed by #2636

Comments

@StefanOltmann
Copy link

StefanOltmann commented Jan 19, 2023

Platform

iOS

Installed

Carthage

Version

8.0.0

Steps to Reproduce

Updated from 7.31.5 I get an error.

As far as I understand you may need to set BUILD_LIBRARY_FOR_DISTRIBUTION = YES; in the project.pbxproj, because otherwise newer compiler version can't use libraries compiled with an older version.

See https://stackoverflow.com/a/58656323

I use XCode 14.2, which includes Swift 5.7.2
Sentry seems to be build using an older XCode version

Expected Result

Compiling

Actual Result

Display of error Module compiled with Swift 5.7 cannot be imported by the Swift 5.7.2 compiler

@philipphofmann philipphofmann self-assigned this Jan 19, 2023
@philipphofmann philipphofmann moved this from Needs Discussion to In Progress in Mobile & Cross Platform SDK Jan 19, 2023
philipphofmann added a commit that referenced this issue Jan 19, 2023
Build XCFramework with Xcode 14.2, use BUILD_LIBRARY_FOR_DISTRIBUTION,
and validate that Xcode 14 and 13 can compile the sample project using
the XCFramework.

Fixes GH-2628
@philipphofmann
Copy link
Member

philipphofmann commented Jan 19, 2023

Thanks for reporting this, @StefanOltmann. Should be fixed with #2636.

philipphofmann added a commit that referenced this issue Jan 20, 2023
Build XCFramework with Xcode 14.2, use BUILD_LIBRARY_FOR_DISTRIBUTION,
and validate that Xcode 14 and 13 can compile the sample project using
the XCFramework.

Fixes GH-2628
@github-project-automation github-project-automation bot moved this from In Progress to Done in Mobile & Cross Platform SDK Jan 20, 2023
@StefanOltmann
Copy link
Author

That was quick! Great work! 👍

philipphofmann added a commit that referenced this issue Jan 23, 2023
Build XCFramework with Xcode 14.2, use BUILD_LIBRARY_FOR_DISTRIBUTION,
and validate that Xcode 14 and 13 can compile the sample project using
the XCFramework.

Fixes GH-2628
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants