|
|
|
@ -412,15 +412,6 @@ def upb_proto_library_aspect_impl(target, ctx): |
|
|
|
|
def _upb_proto_reflection_library_aspect_impl(target, ctx): |
|
|
|
|
return _upb_proto_aspect_impl(target, ctx, "upbdefs", _UpbDefsWrappedCcInfo, _WrappedDefsGeneratedSrcsInfo, provide_cc_shared_library_hints = False) |
|
|
|
|
|
|
|
|
|
def _maybe_add(d): |
|
|
|
|
if _is_google3: |
|
|
|
|
d["_grep_includes"] = attr.label( |
|
|
|
|
allow_single_file = True, |
|
|
|
|
cfg = "exec", |
|
|
|
|
default = "@bazel_tools//tools/cpp:grep-includes", |
|
|
|
|
) |
|
|
|
|
return d |
|
|
|
|
|
|
|
|
|
# upb_proto_library() ########################################################## |
|
|
|
|
|
|
|
|
|
def _get_upb_proto_library_aspect_provides(): |
|
|
|
@ -438,7 +429,7 @@ def _get_upb_proto_library_aspect_provides(): |
|
|
|
|
return provides |
|
|
|
|
|
|
|
|
|
upb_proto_library_aspect = aspect( |
|
|
|
|
attrs = _maybe_add({ |
|
|
|
|
attrs = { |
|
|
|
|
"_copts": attr.label( |
|
|
|
|
default = "//:upb_proto_library_copts__for_generated_code_only_do_not_use", |
|
|
|
|
), |
|
|
|
@ -459,7 +450,7 @@ upb_proto_library_aspect = aspect( |
|
|
|
|
"//:generated_code_support__only_for_generated_code_do_not_use__i_give_permission_to_break_me", |
|
|
|
|
]), |
|
|
|
|
"_fasttable_enabled": attr.label(default = "//:fasttable_enabled"), |
|
|
|
|
}), |
|
|
|
|
}, |
|
|
|
|
implementation = upb_proto_library_aspect_impl, |
|
|
|
|
provides = _get_upb_proto_library_aspect_provides(), |
|
|
|
|
attr_aspects = ["deps"], |
|
|
|
@ -484,7 +475,7 @@ upb_proto_library = rule( |
|
|
|
|
# upb_proto_reflection_library() ############################################### |
|
|
|
|
|
|
|
|
|
_upb_proto_reflection_library_aspect = aspect( |
|
|
|
|
attrs = _maybe_add({ |
|
|
|
|
attrs = { |
|
|
|
|
"_copts": attr.label( |
|
|
|
|
default = "//:upb_proto_library_copts__for_generated_code_only_do_not_use", |
|
|
|
|
), |
|
|
|
@ -506,7 +497,7 @@ _upb_proto_reflection_library_aspect = aspect( |
|
|
|
|
"//:generated_reflection_support__only_for_generated_code_do_not_use__i_give_permission_to_break_me", |
|
|
|
|
], |
|
|
|
|
), |
|
|
|
|
}), |
|
|
|
|
}, |
|
|
|
|
implementation = _upb_proto_reflection_library_aspect_impl, |
|
|
|
|
provides = [ |
|
|
|
|
_UpbDefsWrappedCcInfo, |
|
|
|
|