Skip to content

Commit

Permalink
Collect data from objc_import (#2346)
Browse files Browse the repository at this point in the history
@keith, tossing up a quick PR per your suggestion in
bazelbuild/bazel#17018 (comment)
to lay the groundwork
  • Loading branch information
cpsauer authored Jan 2, 2024
1 parent 071463e commit 3fdba5a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions apple/internal/aspects/resource_aspect.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,9 @@ def _apple_resource_aspect_impl(target, ctx):
if ctx.rule.attr.srcs or ctx.rule.attr.non_arc_srcs or ctx.rule.attr.deps:
owner = str(ctx.label)

elif ctx.rule.kind == "objc_import":
collect_args["res_attrs"] = ["data"]

elif ctx.rule.kind == "swift_library":
module_names = [x.name for x in target[SwiftInfo].direct_modules if x.swift]
bucketize_args["swift_module"] = module_names[0] if module_names else None
Expand Down

0 comments on commit 3fdba5a

Please sign in to comment.