Skip to content

Commit

Permalink
Do not find protobuf for python
Browse files Browse the repository at this point in the history
In conda-forge's recent released tensorflow, protobuf is external
from tensorflow and not inside the tensorflow directory.
  • Loading branch information
njzjz committed Apr 19, 2021
1 parent b3ebfc1 commit f66c78e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions source/cmake/Findtensorflow.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ find_path(TensorFlow_INCLUDE_DIRS
PATH_SUFFIXES "/include"
NO_DEFAULT_PATH
)
if (BUILD_CPP_IF)
find_path(TensorFlow_INCLUDE_DIRS_GOOGLE
NAMES
google/protobuf/type.pb.h
Expand All @@ -40,6 +41,7 @@ find_path(TensorFlow_INCLUDE_DIRS_GOOGLE
NO_DEFAULT_PATH
)
list(APPEND TensorFlow_INCLUDE_DIRS ${TensorFlow_INCLUDE_DIRS_GOOGLE})
endif ()

if (NOT TensorFlow_INCLUDE_DIRS AND tensorflow_FIND_REQUIRED)
message(FATAL_ERROR
Expand Down

0 comments on commit f66c78e

Please sign in to comment.