blob: e36dc17831187c8ef736daeaa34c3659149d1ad1 [file] [log] [blame]
include_defs('//bucklets/grpc.bucklet')
fetch_grpc_plugin(version = '1.3.1')
# Repackaging of gRPC 1.3.* to solve the OSGI split package issue.
# If bumping the gRPC version, please write a new rule.
def grpc_core_repkg_131():
repkg_deps = [
'//lib:COMPILE',
'//lib:google-instrumentation-0.3.0',
"//lib:google-errorprone-2.0.19"
]
remote_file(
name = "grpc-src-zip-131",
url = "https://github.com/grpc/grpc-java/archive/v1.3.1.zip",
sha1 = "03dc21440fdfa920aa0e905da17df35b0d6c9a44",
)
srcs = []
for pkg in ['core', 'context']:
name = 'grpc-' + pkg + '-130'
genrule(
name = name,
bash = 'jar xf $(location :grpc-src-zip-131) grpc-java-1.3.1/' + pkg + '/src/main/java '
+ '&& cd grpc-java-1.3.1/' + pkg + '/src/main/java '
+ '&& jar -cf $OUT *',
out = pkg + '.src.zip',
)
srcs.append(':' + name)
osgi_jar(
name = 'grpc-core-repkg-1.3.1',
srcs = srcs,
deps = repkg_deps,
package_name_root = 'io.grpc',
import_packages = '!javax.annotation,!com.google.errorprone.annotations,*',
export_packages = '*',
do_javadocs = False,
do_checkstyle = False,
)
grpc_core_repkg_131()