-
-
Notifications
You must be signed in to change notification settings - Fork 6k
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
Compiler issue Xcode 11.4 swift 5.2 using Carthage #4335
Comments
Can you post the full log? |
BTW I will check some PRs and perhaps merge a few and release a new version. That's on my todo list this week or next. |
Even with the new update it has not fixed the issue. still have the same problem |
I need some logs to understand. From my understanding, carthage will build from source, not from a prebuilt binary. |
I'm getting the exact same problem as @afridikhalid I'm using the latest Xcode 11.4.1 |
Well, I seem to have found the cause of the problem;
So for my own curiosity, I tried this. I took the Charts project workspace and changed the target name to be different, eg: Chartz.framework and built the framework with Xcode 11.4.1. Brought that into my Xcode 11.4.1 project & bingo! You don't get that error anymore and everything works with Swift compiler 5.2.2. I did not have to set the Build Libraries for Distribution to YES either in the Charts project. I seems the above Apple bug report is indeed correct. I'm not sure what it is that's clashing, but it seems there is a clash between the name of the framework & some component within the codebase itself. |
@gheatley @liuxuan30 I fixed the issue. |
@afridikhalid so carthage maintain a binary of Charts on their side? I don't think they designed this way. we didn't provide a prebuilt binary for carthage. I might be wrong but I remember if carthage don't find an available binary, they will build from source. But you explictly add --no-use-binaries |
I checked our project, BUILD_LIBRARIES_FOR_DISTRIBUTION is set to NO. So I think this does not apply? |
Indeed your BUILD_LIBRARIES_FOR_DISTRIBUTION is set to NO. But what the bug report says there is not quite accurate, in that BUILD_LIBRARIES_FOR_DISTRIBUTION needs to be YES for this to apply. It does not need to be set to YES for this problem to affect Charts. The solution however, works! |
What did you do?
Updated to Xcode 11.4 and run Carthage update iOS platform
What did you expect to happen?
Everything should work as intended
What happened instead?
Module compiled with Swift 5.1.2 cannot be imported by the Swift 5.2 compiler
I had opened an issue but someone has closed the issue without any fix
Charts Environment
**Charts version/Branch/Commit Number: 3.4.0
**Xcode version: 11.4
**Swift version: 5.2
**Platform(s) running Charts: iOS
macOS version running Xcode:
The text was updated successfully, but these errors were encountered: