Add example of mixed-source app and fix module name bug#10
Closed
Add example of mixed-source app and fix module name bug#10
Conversation
segiddins
reviewed
Feb 20, 2020
| fail("Unable to compile %s in apple_framework %s" % (f, name)) | ||
|
|
||
| module_name = kwargs.pop("module_name", name) | ||
| module_name = _normalize_module_name(kwargs.pop("module_name", name)) |
Member
There was a problem hiding this comment.
I think we should only normalize in the fallback case, i.e.
kwargs.pop("module_name", _normalize_module_name(name))
Member
Author
There was a problem hiding this comment.
Hmm... good point. I'll change it.
segiddins
reviewed
Feb 20, 2020
| // Copyright © 2018 Oscar Bonilla. All rights reserved. | ||
| // | ||
|
|
||
| public class SwiftObj : NSObject { |
Member
Author
There was a problem hiding this comment.
Shouldn't that come from the Objective-C headers?
Member
There was a problem hiding this comment.
I don't think Swift will pull in transitive modules like that?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add a mixed source example and get it closer to compiling.
Without this PR, I get:
After normalizing the module name, I get:
This is because the name of the module is actually
mixed_test_swift-Swift.h. Unfortunately,rules_swift'sswift_libraryrule doesn't allow changing the name of the header generated (see this PR for a possible solution there).Putting this up here while we decide whether to push on that
swift_libraryPR and bump our dependency (preferred) or work around it.