Skip to content

Commit

Permalink
[rules_apple] Migrate static_framework_file to imported_library (#1697)
Browse files Browse the repository at this point in the history
STATIC_FRAMEWORK_FILE is a static archive, and we should be able to
migrate it to IMPORTED_LIBRARY. We will eventually migrate it to a
LibraryToLink in the CcLinkingContext.

If this migration breaks build, it is likely because there are two
~equivalent static frameworks in the dependency, that were
deduplicated when -F are used to find them. We should fix those builds
by eliminating the redundant dependency.

PiperOrigin-RevId: 472471843
(cherry picked from commit 08a6456)

Co-authored-by: Walter Lee <waltl@google.com>
  • Loading branch information
keith and googlewalt authored Oct 9, 2022
1 parent 0708580 commit 8d84134
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apple/internal/framework_import_support.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ def _objc_provider_with_dependencies(
objc_provider_fields["dynamic_framework_file"] = depset(dynamic_framework_file)

if static_framework_file:
objc_provider_fields["static_framework_file"] = depset(static_framework_file)
objc_provider_fields["imported_library"] = depset(static_framework_file)

if alwayslink:
objc_provider_fields["force_load_library"] = depset(static_framework_file)
Expand Down

0 comments on commit 8d84134

Please sign in to comment.