From 1dcdf0d7ff0d03285fce4abeb9250432746793d8 Mon Sep 17 00:00:00 2001 From: Fergus Henderson Date: Wed, 4 Nov 2020 09:46:27 -0800 Subject: [PATCH] (lite) Fix include-what-you-use violations in TF Lite Java's builtin_ops_jni.cc: #include tensorflow/lite/core/api/op_resolver.h, for OpResolver, and #include , for std::unique_ptr. PiperOrigin-RevId: 340667630 Change-Id: I7ed9df7d3a939b54e6d2be9e9d7f9c6432886550 --- tensorflow/lite/java/src/main/native/BUILD | 1 + tensorflow/lite/java/src/main/native/builtin_ops_jni.cc | 3 +++ 2 files changed, 4 insertions(+) diff --git a/tensorflow/lite/java/src/main/native/BUILD b/tensorflow/lite/java/src/main/native/BUILD index aba288a314d..75e32dfc2a9 100644 --- a/tensorflow/lite/java/src/main/native/BUILD +++ b/tensorflow/lite/java/src/main/native/BUILD @@ -51,6 +51,7 @@ cc_library( deps = [ ":native_framework_only", "//tensorflow/lite:framework", + "//tensorflow/lite/core/api", "//tensorflow/lite/kernels:builtin_ops", ], alwayslink = 1, diff --git a/tensorflow/lite/java/src/main/native/builtin_ops_jni.cc b/tensorflow/lite/java/src/main/native/builtin_ops_jni.cc index 95bc0a4fa8d..aa654046ef4 100644 --- a/tensorflow/lite/java/src/main/native/builtin_ops_jni.cc +++ b/tensorflow/lite/java/src/main/native/builtin_ops_jni.cc @@ -13,6 +13,9 @@ See the License for the specific language governing permissions and limitations under the License. ==============================================================================*/ +#include + +#include "tensorflow/lite/core/api/op_resolver.h" #include "tensorflow/lite/kernels/register.h" namespace tflite {