File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -40,10 +40,13 @@ include(TensorflowBase)
4040add_library (tensorflow_cc INTERFACE )
4141target_compile_features (tensorflow_cc INTERFACE ${TARGET_CXX_STANDARD} )
4242
43+ # The include folders are sometimes contained under bazel-bin/bin/ and sometimes just bazel-bin.
4344target_include_directories (
4445 tensorflow_cc INTERFACE
4546 "${CMAKE_INSTALL_PREFIX} /include/tensorflow/bazel-bin/tensorflow/include"
4647 "${CMAKE_INSTALL_PREFIX} /include/tensorflow/bazel-bin/tensorflow/include/src"
48+ "${CMAKE_INSTALL_PREFIX} /include/tensorflow/bazel-bin/bin/tensorflow/include"
49+ "${CMAKE_INSTALL_PREFIX} /include/tensorflow/bazel-bin/bin/tensorflow/include/src"
4750)
4851target_link_libraries (
4952 tensorflow_cc INTERFACE
Original file line number Diff line number Diff line change @@ -13,4 +13,10 @@ ExternalProject_Add(
1313 CONFIGURE_COMMAND ""
1414 BUILD_COMMAND "${CMAKE_CURRENT_BINARY_DIR} /build_tensorflow.sh"
1515 INSTALL_COMMAND "${CMAKE_CURRENT_SOURCE_DIR} /cmake/copy_links.sh" bazel-bin
16+ # The include folders are sometimes contained under bazel-bin/bin/ and sometimes just bazel-bin.
17+ # Later, we include both so let's make sure they both exist so that CMake does not complain.
18+ COMMAND mkdir -p "${CMAKE_CURRENT_BINARY_DIR} /tensorflow/bazel-bin/tensorflow/include/src"
19+ COMMAND mkdir -p "${CMAKE_CURRENT_BINARY_DIR} /tensorflow/bazel-bin/bin/tensorflow/include/src"
20+ COMMAND touch "${CMAKE_CURRENT_BINARY_DIR} /tensorflow/bazel-bin/tensorflow/include/src/__placeholder__.h"
21+ COMMAND touch "${CMAKE_CURRENT_BINARY_DIR} /tensorflow/bazel-bin/bin/tensorflow/include/src/__placeholder__.h"
1622)
You can’t perform that action at this time.
0 commit comments