From 30618f1018457d6d9464ae09d60b092e77445444 Mon Sep 17 00:00:00 2001 From: Phil Ashby Date: Thu, 20 May 2021 20:10:48 +0100 Subject: [PATCH] Enable XNNPACK in CMake builds (#83) --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index ef94123..004d2f3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -3,6 +3,10 @@ project(deepbacksub CXX) find_package(OpenCV REQUIRED COMPONENTS core imgproc imgcodecs video videoio highgui) +# force compilation of XNNPACK delegate (without this the too clever-by-half use +# of weak/strong symbol linking fails in a static library) +add_compile_definitions(TFLITE_BUILD_WITH_XNNPACK_DELEGATE) + # This assumes that tensorflow got checked out as submodule. # True, if `git clone` had the additional option `--recursive`. add_subdirectory(tensorflow/tensorflow/lite