@ -146,6 +146,13 @@ def _update_visibility(visibility):
final_visibility . append ( rule )
return [ x for x in final_visibility ]
def _include_prefix ( ) :
include_prefix = " "
if native . package_name ( ) :
for _ in native . package_name ( ) . split ( " / " ) :
include_prefix + = " ../ "
return include_prefix
def grpc_cc_library (
name ,
srcs = [ ] ,
@ -193,6 +200,7 @@ def grpc_cc_library(
if select_deps :
for select_deps_entry in select_deps :
deps + = select ( select_deps_entry )
include_prefix = _include_prefix ( )
native . cc_library (
name = name ,
srcs = srcs ,
@ -217,9 +225,9 @@ def grpc_cc_library(
testonly = testonly ,
linkopts = linkopts ,
includes = [
" include " ,
" src/core/ext/upb-gen " , # Once upb code-gen issue is resolved, remove this.
" src/core/ext/upbdefs-gen " , # Once upb code-gen issue is resolved, remove this.
include_prefix + " include " ,
include_prefix + " src/core/ext/upb-gen " , # Once upb code-gen issue is resolved, remove this.
include_prefix + " src/core/ext/upbdefs-gen " , # Once upb code-gen issue is resolved, remove this.
] ,
alwayslink = alwayslink ,
data = data ,