1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
|
# Description:
# S3 support for TensorFlow.
package(default_visibility = ["//visibility:public"])
licenses(["notice"]) # Apache 2.0
exports_files(["LICENSE"])
load(
"//tensorflow:tensorflow.bzl",
"tf_cc_binary",
"tf_cc_test",
)
filegroup(
name = "all_files",
srcs = glob(
["**/*"],
exclude = [
"**/METADATA",
"**/OWNERS",
],
),
visibility = ["//tensorflow:__subpackages__"],
)
tf_cc_binary(
name = "s3_file_system.so",
srcs = [
"aws_logging.cc",
"aws_logging.h",
"s3_crypto.cc",
"s3_crypto.h",
"s3_file_system.cc",
"s3_file_system.h",
],
copts = ["-Wno-sign-compare"],
defines = select({
"//conditions:default": [
"ENABLE_CURL_CLIENT",
"ENABLE_NO_ENCRYPTION",
],
}),
linkshared = 1,
deps = [
"//tensorflow/core:framework_headers_lib",
"@aws",
"@curl",
"@protobuf_archive//:protobuf_headers",
],
)
cc_library(
name = "s3_crypto",
srcs = [
"s3_crypto.cc",
],
hdrs = [
"s3_crypto.h",
],
deps = [
"//tensorflow/core:lib",
"//tensorflow/core:lib_internal",
"@aws",
"@boringssl//:crypto",
],
alwayslink = 1,
)
cc_library(
name = "aws_logging",
srcs = [
"aws_logging.cc",
],
hdrs = [
"aws_logging.h",
],
deps = [
"//tensorflow/core:lib",
"//tensorflow/core:lib_internal",
"@aws",
],
alwayslink = 1,
)
cc_library(
name = "s3_file_system",
srcs = [
"s3_file_system.cc",
],
hdrs = [
"s3_file_system.h",
],
deps = [
":aws_logging",
":s3_crypto",
"//tensorflow/core:lib",
"//tensorflow/core:lib_internal",
"@aws",
],
alwayslink = 1,
)
tf_cc_test(
name = "s3_file_system_test",
size = "small",
srcs = [
"s3_file_system_test.cc",
],
tags = [
"manual",
],
deps = [
":s3_file_system",
"//tensorflow/core:lib",
"//tensorflow/core:lib_internal",
"//tensorflow/core:test",
"//tensorflow/core:test_main",
"@aws",
],
)
|