@@ -148,34 +148,16 @@ def _common_linking_api_attrs(*, deps_cfg):
148148 ),
149149 })
150150
151- def _j2objc_binary_linking_attrs (* , deps_cfg ):
151+ def _j2objc_binary_linking_attrs ():
152152 """Returns a dictionary of required attributes for J2ObjC processing code in native linking.
153-
154- Args:
155- deps_cfg: Bazel split transition to use on binary attrs, such as deps and split toolchains.
156- To satisfy native Bazel linking prerequisites, `deps` and this `deps_cfg` attribute must
157- use the same transition.
158153 """
159154 return {
160- "_dummy_lib" : attr .label (
161- cfg = deps_cfg ,
162- default = Label ("@bazel_tools//tools/objc:dummy_lib" ),
163- ),
164- "_j2objc_dead_code_pruner" : attr .label (
165- executable = True ,
166- # Setting `allow_single_file=True` would be more correct. Unfortunately,
167- # doing so prevents using py_binary as the underlying target because py_binary
168- # produces at least _two_ output files (the executable plus any files in srcs)
169- allow_files = True ,
170- cfg = "exec" ,
171- default = Label ("@bazel_tools//tools/objc:j2objc_dead_code_pruner_binary" ),
172- ),
173155 # xcrunwrapper is no longer used by rules_apple, but the underlying implementation of
174156 # apple_common.link_multi_arch_binary and j2objc_dead_code_pruner require this attribute.
175157 # See CompilationSupport.java:
176158 # - `registerJ2ObjcDeadCodeRemovalActions()`
177159 # - `registerLinkActions()` --> `registerBinaryStripAction()`
178- # TODO(b/117932394): Remove this attribute once Bazel no longer uses xcrunwrapper .
160+ # TODO(b/117932394): Remove this once Bazel 6 support is dropped .
179161 "_xcrunwrapper" : attr .label (
180162 cfg = "exec" ,
181163 executable = True ,
@@ -236,7 +218,7 @@ def _binary_linking_attrs(
236218 return dicts .add (
237219 extra_attrs ,
238220 _common_linking_api_attrs (deps_cfg = deps_cfg ),
239- _j2objc_binary_linking_attrs (deps_cfg = deps_cfg ),
221+ _j2objc_binary_linking_attrs (),
240222 {
241223 "codesign_inputs" : attr .label_list (
242224 doc = """
0 commit comments