未验证 提交 c251e838 编写于 作者: Y Yifei Feng 提交者: GitHub

Merge pull request #37464 from tensorflow/ggadde-cp1-2-2

[TF XLA AOT] Make sure required sources are included in pip package.
......@@ -2710,7 +2710,7 @@ def tf_external_workspace_visible(visibility):
# External workspaces can see this target.
return ["//visibility:public"]
def _filegroup_as_file(ctx):
def _filegroup_as_file_impl(ctx):
out = ctx.actions.declare_file(ctx.label.name)
ctx.actions.write(
output = out,
......@@ -2718,9 +2718,18 @@ def _filegroup_as_file(ctx):
)
return DefaultInfo(files = depset([out]))
filegroup_as_file = rule(
implementation = _filegroup_as_file,
_filegroup_as_file = rule(
implementation = _filegroup_as_file_impl,
attrs = {
"dep": attr.label(),
},
)
def filegroup_as_file(name, dep, visibility = []):
"""Creates a filegroup ${name}_file which contains the file ${name}."""
_filegroup_as_file(name = name, dep = dep)
native.filegroup(
name = name + "_file",
srcs = [name],
visibility = visibility,
)
......@@ -82,7 +82,7 @@ COMMON_PIP_DEPS = [
"README",
"setup.py",
":included_headers",
":xla_compiled_cpu_runtime_srcs.txt",
":xla_compiled_cpu_runtime_srcs.txt_file",
"//tensorflow:tensorflow_py",
"//tensorflow/compiler/tf2xla:xla_compiled_cpu_runtime_hdrs",
"//tensorflow/compiler/tf2xla:xla_compiled_cpu_runtime_srcs",
......
......@@ -20,4 +20,5 @@ recursive-include tensorflow/include/google *.inc
recursive-include tensorflow/include/include *.h
recursive-include tensorflow/include/third_party *
recursive-include tensorflow/include/unsupported *
recursive-include tensorflow/xla_aot_runtime_src *
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册