]>
Commit | Line | Data |
---|---|---|
1e59de90 TL |
1 | diff --git a/tensorflow/core/platform/macros.h b/tensorflow/core/platform/macros.h |
2 | --- a/tensorflow/core/platform/macros.h | |
3 | +++ b/tensorflow/core/platform/macros.h | |
4 | @@ -57,16 +57,7 @@ | |
5 | #define TF_SCANF_ATTRIBUTE(string_index, first_to_check) | |
6 | #endif | |
7 | ||
8 | -// Control visibility outside .so | |
9 | -#if defined(_WIN32) | |
10 | -#ifdef TF_COMPILE_LIBRARY | |
11 | -#define TF_EXPORT __declspec(dllexport) | |
12 | -#else | |
13 | -#define TF_EXPORT __declspec(dllimport) | |
14 | -#endif // TF_COMPILE_LIBRARY | |
15 | -#else | |
16 | -#define TF_EXPORT __attribute__((visibility("default"))) | |
17 | -#endif // _WIN32 | |
18 | +#define TF_EXPORT | |
19 | ||
20 | #ifdef __has_builtin | |
21 | #define TF_HAS_BUILTIN(x) __has_builtin(x) | |
22 | ||
23 | diff --git a/tensorflow/c/c_api.h b/tensorflow/c/c_api.h | |
24 | --- a/tensorflow/c/c_api.h | |
25 | +++ b/tensorflow/c/c_api.h | |
26 | @@ -71,24 +71,7 @@ | |
27 | // and the API just provides high level controls over the number of | |
28 | // devices of each type. | |
29 | ||
30 | -// Macro to control visibility of exported symbols in the shared library (.so, | |
31 | -// .dylib, .dll). | |
32 | -// This duplicates the TF_EXPORT macro definition in | |
33 | -// tensorflow/core/platform/macros.h in order to keep this .h file independent | |
34 | -// of any other includes. | |
35 | -#ifdef SWIG | |
36 | #define TF_CAPI_EXPORT | |
37 | -#else | |
38 | -#if defined(_WIN32) | |
39 | -#ifdef TF_COMPILE_LIBRARY | |
40 | -#define TF_CAPI_EXPORT __declspec(dllexport) | |
41 | -#else | |
42 | -#define TF_CAPI_EXPORT __declspec(dllimport) | |
43 | -#endif // TF_COMPILE_LIBRARY | |
44 | -#else | |
45 | -#define TF_CAPI_EXPORT __attribute__((visibility("default"))) | |
46 | -#endif // _WIN32 | |
47 | -#endif // SWIG | |
48 | ||
49 | #ifdef __cplusplus | |
50 | extern "C" { | |
51 | ||
52 | diff --git a/tensorflow/c/c_api_experimental.h b/tensorflow/c/c_api_experimental.h | |
53 | --- a/tensorflow/c/c_api_experimental.h | |
54 | +++ b/tensorflow/c/c_api_experimental.h | |
55 | @@ -28,24 +28,7 @@ | |
56 | // The API here is subject to changes in the future. | |
57 | // -------------------------------------------------------------------------- | |
58 | ||
59 | -// Macro to control visibility of exported symbols in the shared library (.so, | |
60 | -// .dylib, .dll). | |
61 | -// This duplicates the TF_EXPORT macro definition in | |
62 | -// tensorflow/core/platform/macros.h in order to keep this .h file independent | |
63 | -// of any other includes.$a | |
64 | -#ifdef SWIG | |
65 | #define TF_CAPI_EXPORT | |
66 | -#else | |
67 | -#if defined(_WIN32) | |
68 | -#ifdef TF_COMPILE_LIBRARY | |
69 | -#define TF_CAPI_EXPORT __declspec(dllexport) | |
70 | -#else | |
71 | -#define TF_CAPI_EXPORT __declspec(dllimport) | |
72 | -#endif // TF_COMPILE_LIBRARY | |
73 | -#else | |
74 | -#define TF_CAPI_EXPORT __attribute__((visibility("default"))) | |
75 | -#endif // _WIN32 | |
76 | -#endif // SWIG | |
77 | ||
78 | #ifdef __cplusplus | |
79 | extern "C" { | |
80 | ||
81 | diff --git a/tensorflow/c/c_api_macros.h b/tensorflow/c/c_api_macros.h | |
82 | --- a/tensorflow/c/c_api_macros.h | |
83 | +++ b/tensorflow/c/c_api_macros.h | |
84 | @@ -16,17 +16,5 @@ | |
85 | #ifndef TENSORFLOW_C_C_API_MACROS_H_ | |
86 | #define TENSORFLOW_C_C_API_MACROS_H_ | |
87 | ||
88 | -#ifdef SWIG | |
89 | #define TF_CAPI_EXPORT | |
90 | -#else | |
91 | -#if defined(_WIN32) | |
92 | -#ifdef TF_COMPILE_LIBRARY | |
93 | -#define TF_CAPI_EXPORT __declspec(dllexport) | |
94 | -#else | |
95 | -#define TF_CAPI_EXPORT __declspec(dllimport) | |
96 | -#endif // TF_COMPILE_LIBRARY | |
97 | -#else | |
98 | -#define TF_CAPI_EXPORT __attribute__((visibility("default"))) | |
99 | -#endif // _WIN32 | |
100 | -#endif // SWIG | |
101 | ||
102 | ||
103 | diff --git a/tensorflow/c/kernels.h b/tensorflow/c/kernels.h | |
104 | --- a/tensorflow/c/kernels.h | |
105 | +++ b/tensorflow/c/kernels.h | |
106 | @@ -23,24 +23,7 @@ | |
107 | #include "tensorflow/c/tf_status.h" | |
108 | #include "tensorflow/c/tf_tensor.h" | |
109 | ||
110 | -// Macro to control visibility of exported symbols in the shared library (.so, | |
111 | -// .dylib, .dll). | |
112 | -// This duplicates the TF_EXPORT macro definition in | |
113 | -// tensorflow/core/platform/macros.h in order to keep this .h file independent | |
114 | -// of any other includes. | |
115 | -#ifdef SWIG | |
116 | #define TF_CAPI_EXPORT | |
117 | -#else | |
118 | -#if defined(_WIN32) | |
119 | -#ifdef TF_COMPILE_LIBRARY | |
120 | -#define TF_CAPI_EXPORT __declspec(dllexport) | |
121 | -#else | |
122 | -#define TF_CAPI_EXPORT __declspec(dllimport) | |
123 | -#endif // TF_COMPILE_LIBRARY | |
124 | -#else | |
125 | -#define TF_CAPI_EXPORT __attribute__((visibility("default"))) | |
126 | -#endif // _WIN32 | |
127 | -#endif // SWIG | |
128 | ||
129 | #ifdef __cplusplus | |
130 | extern "C" { | |
131 | ||
132 | diff --git a/tensorflow/c/ops.h b/tensorflow/c/ops.h | |
133 | --- a/tensorflow/c/ops.h | |
134 | +++ b/tensorflow/c/ops.h | |
135 | @@ -76,19 +76,7 @@ | |
136 | #include "tensorflow/c/tf_datatype.h" | |
137 | #include "tensorflow/c/tf_status.h" | |
138 | ||
139 | -#ifdef SWIG | |
140 | #define TF_CAPI_EXPORT | |
141 | -#else | |
142 | -#if defined(_WIN32) | |
143 | -#ifdef TF_COMPILE_LIBRARY | |
144 | -#define TF_CAPI_EXPORT __declspec(dllexport) | |
145 | -#else | |
146 | -#define TF_CAPI_EXPORT __declspec(dllimport) | |
147 | -#endif // TF_COMPILE_LIBRARY | |
148 | -#else | |
149 | -#define TF_CAPI_EXPORT __attribute__((visibility("default"))) | |
150 | -#endif // _WIN32 | |
151 | -#endif // SWIG | |
152 | ||
153 | #ifdef __cplusplus | |
154 | extern "C" { | |
155 | ||
156 | diff --git a/tensorflow/c/tf_datatype.h b/tensorflow/c/tf_datatype.h | |
157 | --- a/tensorflow/c/tf_datatype.h | |
158 | +++ b/tensorflow/c/tf_datatype.h | |
159 | @@ -18,24 +18,7 @@ | |
160 | ||
161 | #include <stddef.h> | |
162 | ||
163 | -// Macro to control visibility of exported symbols in the shared library (.so, | |
164 | -// .dylib, .dll). | |
165 | -// This duplicates the TF_EXPORT macro definition in | |
166 | -// tensorflow/core/platform/macros.h in order to keep this .h file independent | |
167 | -// of any other includes. | |
168 | -#ifdef SWIG | |
169 | #define TF_CAPI_EXPORT | |
170 | -#else | |
171 | -#if defined(_WIN32) | |
172 | -#ifdef TF_COMPILE_LIBRARY | |
173 | -#define TF_CAPI_EXPORT __declspec(dllexport) | |
174 | -#else | |
175 | -#define TF_CAPI_EXPORT __declspec(dllimport) | |
176 | -#endif // TF_COMPILE_LIBRARY | |
177 | -#else | |
178 | -#define TF_CAPI_EXPORT __attribute__((visibility("default"))) | |
179 | -#endif // _WIN32 | |
180 | -#endif // SWIG | |
181 | ||
182 | #ifdef __cplusplus | |
183 | extern "C" { | |
184 | ||
185 | diff --git a/tensorflow/c/tf_status.h b/tensorflow/c/tf_status.h | |
186 | --- a/tensorflow/c/tf_status.h | |
187 | +++ b/tensorflow/c/tf_status.h | |
188 | @@ -16,19 +16,7 @@ | |
189 | #ifndef TENSORFLOW_C_TF_STATUS_H_ | |
190 | #define TENSORFLOW_C_TF_STATUS_H_ | |
191 | ||
192 | -#ifdef SWIG | |
193 | #define TF_CAPI_EXPORT | |
194 | -#else | |
195 | -#if defined(_WIN32) | |
196 | -#ifdef TF_COMPILE_LIBRARY | |
197 | -#define TF_CAPI_EXPORT __declspec(dllexport) | |
198 | -#else | |
199 | -#define TF_CAPI_EXPORT __declspec(dllimport) | |
200 | -#endif // TF_COMPILE_LIBRARY | |
201 | -#else | |
202 | -#define TF_CAPI_EXPORT __attribute__((visibility("default"))) | |
203 | -#endif // _WIN32 | |
204 | -#endif // SWIG | |
205 | ||
206 | #ifdef __cplusplus | |
207 | extern "C" { | |
208 | ||
209 | diff --git a/tensorflow/c/tf_tensor.h b/tensorflow/c/tf_tensor.h | |
210 | --- a/tensorflow/c/tf_tensor.h | |
211 | +++ b/tensorflow/c/tf_tensor.h | |
212 | @@ -23,24 +23,7 @@ | |
213 | #include "tensorflow/c/tf_datatype.h" | |
214 | #include "tensorflow/c/tf_status.h" | |
215 | ||
216 | -// Macro to control visibility of exported symbols in the shared library (.so, | |
217 | -// .dylib, .dll). | |
218 | -// This duplicates the TF_EXPORT macro definition in | |
219 | -// tensorflow/core/platform/macros.h in order to keep this .h file independent | |
220 | -// of any other includes. | |
221 | -#ifdef SWIG | |
222 | #define TF_CAPI_EXPORT | |
223 | -#else | |
224 | -#if defined(_WIN32) | |
225 | -#ifdef TF_COMPILE_LIBRARY | |
226 | -#define TF_CAPI_EXPORT __declspec(dllexport) | |
227 | -#else | |
228 | -#define TF_CAPI_EXPORT __declspec(dllimport) | |
229 | -#endif // TF_COMPILE_LIBRARY | |
230 | -#else | |
231 | -#define TF_CAPI_EXPORT __attribute__((visibility("default"))) | |
232 | -#endif // _WIN32 | |
233 | -#endif // SWIG | |
234 | ||
235 | #ifdef __cplusplus | |
236 | extern "C" { | |
237 | ||
238 | diff --git a/tensorflow/c/eager/c_api.h b/tensorflow/c/eager/c_api.h | |
239 | --- a/tensorflow/c/eager/c_api.h | |
240 | +++ b/tensorflow/c/eager/c_api.h | |
241 | @@ -22,24 +22,7 @@ | |
242 | ||
243 | #include "tensorflow/c/c_api.h" | |
244 | ||
245 | -// Macro to control visibility of exported symbols in the shared library (.so, | |
246 | -// .dylib, .dll). | |
247 | -// This duplicates the TF_EXPORT macro definition in | |
248 | -// tensorflow/core/platform/macros.h in order to keep this .h file independent | |
249 | -// of any other includes.$a | |
250 | -#ifdef SWIG | |
251 | #define TF_CAPI_EXPORT | |
252 | -#else | |
253 | -#if defined(_WIN32) | |
254 | -#ifdef TF_COMPILE_LIBRARY | |
255 | -#define TF_CAPI_EXPORT __declspec(dllexport) | |
256 | -#else | |
257 | -#define TF_CAPI_EXPORT __declspec(dllimport) | |
258 | -#endif // TF_COMPILE_LIBRARY | |
259 | -#else | |
260 | -#define TF_CAPI_EXPORT __attribute__((visibility("default"))) | |
261 | -#endif // _WIN32 | |
262 | -#endif // SWIG | |
263 | ||
264 | #ifdef __cplusplus | |
265 | extern "C" { |