2 nnas_find_package(TensorFlowSource EXACT 2.6.0 QUIET)
3 nnas_find_package(TensorFlowGEMMLowpSource EXACT 2.6.0 QUIET)
4 nnas_find_package(TensorFlowEigenSource EXACT 2.6.0 QUIET)
5 nnas_find_package(TensorFlowRuySource EXACT 2.6.0 QUIET)
7 if (NOT TensorFlowSource_FOUND)
8 message(STATUS "Skipping luci-interpreter: TensorFlow not found")
12 if (NOT TensorFlowGEMMLowpSource_FOUND)
13 message(STATUS "Skipping luci-interpreter: gemmlowp not found")
17 if (NOT TensorFlowEigenSource_FOUND)
18 message(STATUS "Skipping luci-interpreter: Eigen not found")
22 if (NOT TensorFlowRuySource_FOUND)
23 message(STATUS "Skipping luci-interpreter: Ruy not found")
27 find_package(Threads REQUIRED)
29 set(PAL_INITIALIZED TRUE)
32 macro(add_pal_to_target TGT)
33 target_include_directories(${TGT} PRIVATE "${PAL}")
34 target_include_directories(${TGT} SYSTEM PRIVATE
35 "${TensorFlowRuySource_DIR}"
36 "${TensorFlowGEMMLowpSource_DIR}"
37 "${TensorFlowEigenSource_DIR}"
38 "${TensorFlowSource_DIR}")
39 target_include_directories(${TGT} PRIVATE ${LUCI_INTERPRETER_PAL_DIR})
41 # TODO put it back, I changed my mind.
42 # instead add sources with visitors in this library
43 set(PAL_SOURCES ${TensorFlowSource_DIR}/tensorflow/lite/kernels/internal/quantization_util.cc)
44 add_library(luci_interpreter_linux_pal STATIC ${PAL_SOURCES})
45 set_target_properties(luci_interpreter_linux_pal PROPERTIES POSITION_INDEPENDENT_CODE ON)
46 target_include_directories(luci_interpreter_linux_pal SYSTEM PRIVATE
47 "${TensorFlowRuySource_DIR}"
48 "${TensorFlowGEMMLowpSource_DIR}"
49 "${TensorFlowEigenSource_DIR}"
50 "${TensorFlowSource_DIR}"
53 target_link_libraries(${TGT} PRIVATE Threads::Threads luci_interpreter_linux_pal)