diff options
Diffstat (limited to 'cmake')
-rw-r--r-- | cmake/AddDllCopyCommands.cmake | 8 | ||||
-rw-r--r-- | cmake/GlobalConfig.cmake | 22 | ||||
-rw-r--r-- | cmake/ParserVersion.cmake | 18 |
3 files changed, 2 insertions, 46 deletions
diff --git a/cmake/AddDllCopyCommands.cmake b/cmake/AddDllCopyCommands.cmake index 6190170dbc..b32215adc8 100644 --- a/cmake/AddDllCopyCommands.cmake +++ b/cmake/AddDllCopyCommands.cmake @@ -39,14 +39,6 @@ macro(addDllCopyCommands target) addDllCopyCommand(${target} "$<TARGET_FILE_DIR:armnn>/armnn.dll" "$<TARGET_FILE_DIR:armnn>/armnn.dll") endif() - # armnnTfParser.dll - if ("armnnTfParser" IN_LIST target_deps) - addDllCopyCommand(${target} "$<TARGET_FILE_DIR:armnnTfParser>/armnnTfParser.dll" - "$<TARGET_FILE_DIR:armnnTfParser>/armnnTfParser.dll") - addDllCopyCommand(${target} "${PROTOBUF_ROOT}/bin/libprotobufd.dll" - "${PROTOBUF_ROOT}/bin/libprotobuf.dll") - endif() - # armnnTfLiteParser.dll if ("armnnTfLiteParser" IN_LIST target_deps) addDllCopyCommand(${target} "$<TARGET_FILE_DIR:armnnTfLiteParser>/armnnTfLiteParser.dll" diff --git a/cmake/GlobalConfig.cmake b/cmake/GlobalConfig.cmake index ca02284509..e932020bce 100644 --- a/cmake/GlobalConfig.cmake +++ b/cmake/GlobalConfig.cmake @@ -3,7 +3,6 @@ # Copyright 2020 NXP # SPDX-License-Identifier: MIT # -option(BUILD_TF_PARSER "Build Tensorflow parser" OFF) option(BUILD_ONNX_PARSER "Build Onnx parser" OFF) option(BUILD_UNIT_TESTS "Build unit tests" ON) option(BUILD_TESTS "Build test applications" OFF) @@ -157,7 +156,7 @@ endif() find_dependency(Threads) # Favour the protobuf passed on command line -if(BUILD_TF_PARSER OR BUILD_ONNX_PARSER) +if(BUILD_ONNX_PARSER) find_library(PROTOBUF_LIBRARY_DEBUG NAMES "protobufd" PATHS ${PROTOBUF_ROOT}/lib NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH) @@ -177,21 +176,7 @@ if(BUILD_TF_PARSER OR BUILD_ONNX_PARSER) include_directories(SYSTEM "${PROTOBUF_INCLUDE_DIRS}") add_definitions(-DPROTOBUF_USE_DLLS) -endif() - -if(BUILD_TF_PARSER) - add_definitions(-DARMNN_TF_PARSER) - find_path(TF_GENERATED_SOURCES "tensorflow/core/protobuf/saved_model.pb.cc") - - # C++ sources generated for tf protobufs - file(GLOB_RECURSE TF_PROTOBUFS "${TF_GENERATED_SOURCES}/*.pb.cc") - - # C++ headers generated for tf protobufs - include_directories(SYSTEM "${TF_GENERATED_SOURCES}") -endif() - -if(BUILD_ONNX_PARSER) add_definitions(-DARMNN_ONNX_PARSER) find_path(ONNX_GENERATED_SOURCES "onnx/onnx.pb.cc") @@ -405,11 +390,6 @@ else() endif() - -if(NOT BUILD_TF_PARSER) - message(STATUS "Tensorflow parser support is disabled") -endif() - if(NOT BUILD_TF_LITE_PARSER) message(STATUS "Tensorflow Lite parser support is disabled") endif() diff --git a/cmake/ParserVersion.cmake b/cmake/ParserVersion.cmake index 2120bf7057..44b1709880 100644 --- a/cmake/ParserVersion.cmake +++ b/cmake/ParserVersion.cmake @@ -32,20 +32,4 @@ set(TFLITE_PARSER_MINOR_VERSION ${CMAKE_MATCH_1}) set(TFLITE_PARSER_LIB_VERSION "${TFLITE_PARSER_MAJOR_VERSION}.${TFLITE_PARSER_MINOR_VERSION}") # Define LIB soversion -set(TFLITE_PARSER_LIB_SOVERSION "${TFLITE_PARSER_MAJOR_VERSION}") - - -# Read the TfParser version components from file -file(READ ${CMAKE_CURRENT_LIST_DIR}/../include/armnnTfParser/Version.hpp tfVersion) - -# Parse the TfParser version components -string(REGEX MATCH "#define TF_PARSER_MAJOR_VERSION ([0-9]*)" _ ${tfVersion}) -set(TF_PARSER_MAJOR_VERSION ${CMAKE_MATCH_1}) -string(REGEX MATCH "#define TF_PARSER_MINOR_VERSION ([0-9]*)" _ ${tfVersion}) -set(TF_PARSER_MINOR_VERSION ${CMAKE_MATCH_1}) - -# Define LIB version -set(TF_PARSER_LIB_VERSION "${TF_PARSER_MAJOR_VERSION}.${TF_PARSER_MINOR_VERSION}") - -# Define LIB soversion -set(TF_PARSER_LIB_SOVERSION "${TF_PARSER_MAJOR_VERSION}")
\ No newline at end of file +set(TFLITE_PARSER_LIB_SOVERSION "${TFLITE_PARSER_MAJOR_VERSION}")
\ No newline at end of file |