-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: do not generate a modulemap for Objc targets, if they provide one (
#710) The goal of this PR is to selectively generate modulemap files for ObjC targets. If an ObjC target provides a modulemap, we will not generate a modulemap. This avoids `redefinition of module` errors when running outside of the Bazel action sandbox. While we may not generate modulemaps for some ObjC targets, we must continue to create the `generate_modulemap` targets. The logic that assigns dependencies has no way to know whether a modulemap target has been generated (i.e., the ObjC target may be a dependency in another Swift package). Hence, `generate_modulemap` has been modified to have a noop mode. - Add `noop` attribute to `generate_modulemap` rule. If `True`, a modulemap is generated and the appropriate providers are populated. If `False, a modulemap is not generated and empty providers are returned. - Update `clang_files.collect_files()` to return the path of the modulemap file, if one is found. - Update the build file generation to set the `noop` attribute for `generate_modulemap` based upon whether a modulemap file was found for the module. - Update `firebase_example` to use `rules_xcodeproj` to generate an Xcode project and ensure that it builds using the `rules_xcodeproj` recommended build API> Related to MobileNativeFoundation/rules_xcodeproj#2703. Closes #712.
- Loading branch information
Showing
8 changed files
with
189 additions
and
5 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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