Commit 125a91be authored by Jisi Liu's avatar Jisi Liu

Format code.

parent ee8131a6
...@@ -33,17 +33,17 @@ def _proto_srcs_impl(ctx): ...@@ -33,17 +33,17 @@ def _proto_srcs_impl(ctx):
if args: if args:
ctx.action( ctx.action(
inputs= srcs + deps, inputs=srcs + deps,
outputs=ctx.outputs.outs, outputs=ctx.outputs.outs,
arguments= args + import_flags + [s.path for s in srcs], arguments=args + import_flags + [s.path for s in srcs],
executable=ctx.executable.protoc executable=ctx.executable.protoc
) )
return struct( return struct(
proto=struct( proto=struct(
srcs = srcs, srcs=srcs,
import_flags = import_flags, import_flags=import_flags,
deps = deps, deps=deps,
), ),
) )
...@@ -79,32 +79,32 @@ def cc_proto_library( ...@@ -79,32 +79,32 @@ def cc_proto_library(
# For pre-checked-in generated files, we add the internal_bootstrap_hack # For pre-checked-in generated files, we add the internal_bootstrap_hack
# which will skip the codegen action. # which will skip the codegen action.
_proto_srcs( _proto_srcs(
name = name + "_genproto", name=name + "_genproto",
srcs = srcs, srcs=srcs,
deps = [s + "_genproto" for s in proto_deps], deps=[s + "_genproto" for s in proto_deps],
prefix = prefix, prefix=prefix,
protoc = protoc, protoc=protoc,
) )
# An empty cc_library to make rule dependency consistent. # An empty cc_library to make rule dependency consistent.
native.cc_library( native.cc_library(
name = name, name=name,
**kargs) **kargs)
return return
outs = CcOuts(srcs) outs = CcOuts(srcs)
_proto_srcs( _proto_srcs(
name = name + "_genproto", name=name + "_genproto",
srcs = srcs, srcs=srcs,
deps = [s + "_genproto" for s in proto_deps], deps=[s + "_genproto" for s in proto_deps],
prefix = prefix, prefix=prefix,
protoc = protoc, protoc=protoc,
gen_cc = 1, gen_cc=1,
outs = outs, outs=outs,
) )
native.cc_library( native.cc_library(
name = name, name=name,
srcs = outs, srcs=outs,
deps = deps + proto_deps, deps=deps + proto_deps,
includes = [prefix], includes=[prefix],
**kargs) **kargs)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment