提交 e51a68c6 编写于 作者: T TensorFlower Gardener

Merge pull request #25967 from vladmos:incompatible

PiperOrigin-RevId: 235218660
...@@ -1357,7 +1357,7 @@ def _py_wrap_cc_impl(ctx): ...@@ -1357,7 +1357,7 @@ def _py_wrap_cc_impl(ctx):
args += ["-I" + i for i in swig_include_dirs.to_list()] args += ["-I" + i for i in swig_include_dirs.to_list()]
args += [src.path] args += [src.path]
outputs = [ctx.outputs.cc_out, ctx.outputs.py_out] outputs = [ctx.outputs.cc_out, ctx.outputs.py_out]
ctx.action( ctx.actions.run(
executable = ctx.executable._swig, executable = ctx.executable._swig,
arguments = args, arguments = args,
inputs = inputs.to_list(), inputs = inputs.to_list(),
...@@ -1655,8 +1655,7 @@ _append_init_to_versionscript = rule( ...@@ -1655,8 +1655,7 @@ _append_init_to_versionscript = rule(
attrs = { attrs = {
"module_name": attr.string(mandatory = True), "module_name": attr.string(mandatory = True),
"template_file": attr.label( "template_file": attr.label(
allow_files = True, allow_single_file = True,
single_file = True,
mandatory = True, mandatory = True,
), ),
"is_version_script": attr.bool( "is_version_script": attr.bool(
......
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
# substitutions: A dictionary mapping strings to their substitutions # substitutions: A dictionary mapping strings to their substitutions
def template_rule_impl(ctx): def template_rule_impl(ctx):
ctx.template_action( ctx.actions.expand_template(
template = ctx.file.src, template = ctx.file.src,
output = ctx.outputs.out, output = ctx.outputs.out,
substitutions = ctx.attr.substitutions, substitutions = ctx.attr.substitutions,
...@@ -31,8 +31,7 @@ template_rule = rule( ...@@ -31,8 +31,7 @@ template_rule = rule(
attrs = { attrs = {
"src": attr.label( "src": attr.label(
mandatory = True, mandatory = True,
allow_files = True, allow_single_file = True,
single_file = True,
), ),
"substitutions": attr.string_dict(mandatory = True), "substitutions": attr.string_dict(mandatory = True),
"out": attr.output(mandatory = True), "out": attr.output(mandatory = True),
......
...@@ -107,7 +107,7 @@ def _proto_gen_impl(ctx): ...@@ -107,7 +107,7 @@ def _proto_gen_impl(ctx):
inputs += [plugin] inputs += [plugin]
if args: if args:
ctx.action( ctx.actions.run(
inputs = inputs, inputs = inputs,
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],
...@@ -132,7 +132,7 @@ proto_gen = rule( ...@@ -132,7 +132,7 @@ proto_gen = rule(
"protoc": attr.label( "protoc": attr.label(
cfg = "host", cfg = "host",
executable = True, executable = True,
single_file = True, allow_single_file = True,
mandatory = True, mandatory = True,
), ),
"plugin": attr.label( "plugin": attr.label(
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册