mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-24 23:20:25 +08:00
20 lines
849 B
CMake
20 lines
849 B
CMake
|
if(TARGET tensorflow_cc::tensorflow_cc)
|
||
|
return()
|
||
|
endif()
|
||
|
|
||
|
set(tensorflow_cc_FOUND TRUE)
|
||
|
|
||
|
# Compute the installation prefix from this tensorflow-cc-config.cmake file location.
|
||
|
# CMAKE_CURRENT_LIST_DIR = [vcpkg_installed_dir]/[target_triplet]/share/tensorflow-cc
|
||
|
get_filename_component(TENSORFLOW_INSTALL_PREFIX "${CMAKE_CURRENT_LIST_DIR}" DIRECTORY)
|
||
|
# TENSORFLOW_INSTALL_PREFIX = [vcpkg_installed_dir]/[target_triplet]/share
|
||
|
get_filename_component(TENSORFLOW_INSTALL_PREFIX "${TENSORFLOW_INSTALL_PREFIX}" DIRECTORY)
|
||
|
# TENSORFLOW_INSTALL_PREFIX = [vcpkg_installed_dir]/[target_triplet]
|
||
|
|
||
|
add_library(tensorflow_cc::tensorflow_cc INTERFACE IMPORTED GLOBAL)
|
||
|
target_include_directories(tensorflow_cc::tensorflow_cc
|
||
|
INTERFACE
|
||
|
"${TENSORFLOW_INSTALL_PREFIX}/include/tensorflow-external"
|
||
|
"${TENSORFLOW_INSTALL_PREFIX}/include/tensorflow-external/src"
|
||
|
)
|