aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/core/platform
diff options
context:
space:
mode:
Diffstat (limited to 'tensorflow/core/platform')
-rw-r--r--tensorflow/core/platform/default/build_config.bzl18
-rw-r--r--tensorflow/core/platform/default/build_config_root.bzl2
-rw-r--r--tensorflow/core/platform/gif.h2
-rw-r--r--tensorflow/core/platform/jpeg.h2
-rw-r--r--tensorflow/core/platform/platform.h5
-rw-r--r--tensorflow/core/platform/png.h2
6 files changed, 16 insertions, 15 deletions
diff --git a/tensorflow/core/platform/default/build_config.bzl b/tensorflow/core/platform/default/build_config.bzl
index 5db0fe423c..73e8cb8c50 100644
--- a/tensorflow/core/platform/default/build_config.bzl
+++ b/tensorflow/core/platform/default/build_config.bzl
@@ -1,7 +1,7 @@
# Platform-specific build configurations.
-load("@protobuf//:protobuf.bzl", "cc_proto_library")
-load("@protobuf//:protobuf.bzl", "py_proto_library")
+load("@protobuf_archive//:protobuf.bzl", "cc_proto_library")
+load("@protobuf_archive//:protobuf.bzl", "py_proto_library")
load("//tensorflow:tensorflow.bzl", "if_not_mobile")
load("//tensorflow:tensorflow.bzl", "if_not_windows")
@@ -44,15 +44,15 @@ def tf_proto_library_cc(name, srcs = [], has_services = None,
cc_proto_library(
name = name + "_cc",
srcs = srcs,
- deps = tf_deps(protodeps, "_cc") + ["@protobuf//:cc_wkt_protos"],
- cc_libs = cc_libs + ["@protobuf//:protobuf"],
+ deps = tf_deps(protodeps, "_cc") + ["@protobuf_archive//:cc_wkt_protos"],
+ cc_libs = cc_libs + ["@protobuf_archive//:protobuf"],
copts = if_not_windows([
"-Wno-unknown-warning-option",
"-Wno-unused-but-set-variable",
"-Wno-sign-compare",
]),
- protoc = "@protobuf//:protoc",
- default_runtime = "@protobuf//:protobuf",
+ protoc = "@protobuf_archive//:protoc",
+ default_runtime = "@protobuf_archive//:protobuf",
use_grpc_plugin = use_grpc_plugin,
testonly = testonly,
visibility = visibility,
@@ -65,9 +65,9 @@ def tf_proto_library_py(name, srcs=[], protodeps=[], deps=[], visibility=[],
name = name + "_py",
srcs = srcs,
srcs_version = srcs_version,
- deps = deps + tf_deps(protodeps, "_py") + ["@protobuf//:protobuf_python"],
- protoc = "@protobuf//:protoc",
- default_runtime = "@protobuf//:protobuf_python",
+ deps = deps + tf_deps(protodeps, "_py") + ["@protobuf_archive//:protobuf_python"],
+ protoc = "@protobuf_archive//:protoc",
+ default_runtime = "@protobuf_archive//:protobuf_python",
visibility = visibility,
testonly = testonly,
)
diff --git a/tensorflow/core/platform/default/build_config_root.bzl b/tensorflow/core/platform/default/build_config_root.bzl
index e1f123a0a0..04bf2aeca6 100644
--- a/tensorflow/core/platform/default/build_config_root.bzl
+++ b/tensorflow/core/platform/default/build_config_root.bzl
@@ -28,7 +28,7 @@ def tf_additional_verbs_deps():
"//tensorflow:with_verbs_support": [
"//tensorflow/contrib/verbs:verbs_server_lib",
"//tensorflow/contrib/verbs:grpc_verbs_client",
- ],
+ ],
"//conditions:default": [],
})
diff --git a/tensorflow/core/platform/gif.h b/tensorflow/core/platform/gif.h
index 8a719a8cf1..9c72d34ff5 100644
--- a/tensorflow/core/platform/gif.h
+++ b/tensorflow/core/platform/gif.h
@@ -20,7 +20,7 @@ limitations under the License.
#if defined(PLATFORM_GOOGLE)
#include "tensorflow/core/platform/google/build_config/gif.h"
-#elif (defined(PLATFORM_POSIX) && !defined(IS_MOBILE_PLATFORM)) || defined(PLATFORM_WINDOWS)
+#elif defined(PLATFORM_POSIX)|| defined(PLATFORM_WINDOWS) ||defined(PLATFORM_POSIX_ANDROID)
#include <gif_lib.h>
#else
#error Define the appropriate PLATFORM_<foo> macro for this platform
diff --git a/tensorflow/core/platform/jpeg.h b/tensorflow/core/platform/jpeg.h
index f5b4deed55..edbcbd960a 100644
--- a/tensorflow/core/platform/jpeg.h
+++ b/tensorflow/core/platform/jpeg.h
@@ -20,7 +20,7 @@ limitations under the License.
#if defined(PLATFORM_GOOGLE)
#include "tensorflow/core/platform/google/build_config/jpeg.h"
-#elif (defined(PLATFORM_POSIX) && !defined(IS_MOBILE_PLATFORM)) || defined(PLATFORM_WINDOWS)
+#elif defined(PLATFORM_POSIX)|| defined(PLATFORM_WINDOWS) ||defined(PLATFORM_POSIX_ANDROID)
#include <stddef.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/tensorflow/core/platform/platform.h b/tensorflow/core/platform/platform.h
index 7c44b22eff..12120c4ab9 100644
--- a/tensorflow/core/platform/platform.h
+++ b/tensorflow/core/platform/platform.h
@@ -43,9 +43,10 @@ limitations under the License.
#elif defined(__arm__)
#define PLATFORM_POSIX
-// Since there's no macro for the Raspberry Pi, assume we're on a mobile
-// platform if we're compiling for the ARM CPU.
+// Require an outside macro to tell us if we're building for Raspberry Pi.
+#if !defined(RASPBERRY_PI)
#define IS_MOBILE_PLATFORM
+#endif // !defined(RASPBERRY_PI)
#else
// If no platform specified, use:
diff --git a/tensorflow/core/platform/png.h b/tensorflow/core/platform/png.h
index 4500d9abe2..5b0203c343 100644
--- a/tensorflow/core/platform/png.h
+++ b/tensorflow/core/platform/png.h
@@ -20,7 +20,7 @@ limitations under the License.
#if defined(PLATFORM_GOOGLE)
#include "tensorflow/core/platform/google/build_config/png.h"
-#elif (defined(PLATFORM_POSIX) && !defined(IS_MOBILE_PLATFORM)) || defined(PLATFORM_WINDOWS)
+#elif defined(PLATFORM_POSIX)|| defined(PLATFORM_WINDOWS) ||defined(PLATFORM_POSIX_ANDROID)
#include <png.h>
#else
#error Define the appropriate PLATFORM_<foo> macro for this platform