function(_TensorFlow_import)
# Find the header & lib
find_library(TensorFlow_LIB NAMES tensorflow PATHS "${TENSORFLOW_PREFIX}/lib")
- find_path(TenorFlow_INCLUDE_DIR NAMES tensorflow/c/c_api.h PATHS "${TENSORFLOW_PREFIX}/include")
+ find_path(TensorFlow_INCLUDE_DIR NAMES tensorflow/c/c_api.h PATHS "${TENSORFLOW_PREFIX}/include")
# TODO Check TensorFlow version (if possible)
- if(NOT TensorFlow_LIB OR NOT TenorFlow_INCLUDE_DIR)
+ if(NOT TensorFlow_LIB OR NOT TensorFlow_INCLUDE_DIR)
message(STATUS "Found TensorFlow: FALSE")
set(TensorFlow_FOUND FALSE PARENT_SCOPE)
return()
- endif(NOT TensorFlow_LIB OR NOT TenorFlow_INCLUDE_DIR)
+ endif(NOT TensorFlow_LIB OR NOT TensorFlow_INCLUDE_DIR)
# Add tensorflow target (if necessary)
if(NOT TARGET tensorflow)
- message(STATUS "Found TensorFlow (include: ${TenorFlow_INCLUDE_DIR}, library: ${TensorFlow_LIB})")
+ message(STATUS "Found TensorFlow (include: ${TensorFlow_INCLUDE_DIR}, library: ${TensorFlow_LIB})")
# NOTE IMPORTED target may be more appropriate for this case
add_library(tensorflow INTERFACE)
target_link_libraries(tensorflow INTERFACE ${TensorFlow_LIB})
- target_include_directories(tensorflow INTERFACE ${TenorFlow_INCLUDE_DIR})
+ target_include_directories(tensorflow INTERFACE ${TensorFlow_INCLUDE_DIR})
endif(NOT TARGET tensorflow)
set(TensorFlow_FOUND TRUE PARENT_SCOPE)