Skip to content

Commit

Permalink
[cmake] Introduce TensorFlowSource-2.3.0-rc0Config (#2742)
Browse files Browse the repository at this point in the history
This will introduce TensorFlowSource-2.3.0-rc0Config.cmake file to aquire 2.3.0-rc0 with `nnas_find_package()` method

ONE-DCO-1.0-Signed-off-by: SaeHie Park <[email protected]>
  • Loading branch information
seanshpark authored Jul 1, 2020
1 parent f13d2c5 commit d40f62c
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions infra/cmake/packages/TensorFlowSource-2.3.0-rc0Config.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# find_package rejects version with extra string like "2.3.0-rc0"
#
# TODO Find a better way
function(_import)
if(NOT DOWNLOAD_TENSORFLOW)
set(TensorFlowSource_FOUND FALSE PARENT_SCOPE)
return()
endif(NOT DOWNLOAD_TENSORFLOW)

nnas_include(ExternalSourceTools)
nnas_include(OptionTools)

envoption(TENSORFLOW_2_3_0_RC0_URL https://github.com/tensorflow/tensorflow/archive/v2.3.0-rc0.tar.gz)

ExternalSource_Download(TENSORFLOW DIRNAME TENSORFLOW-2.3.0-RC0 ${TENSORFLOW_2_3_0_RC0_URL})

set(TensorFlowSource_DIR ${TENSORFLOW_SOURCE_DIR} PARENT_SCOPE)
set(TensorFlowSource_FOUND TRUE PARENT_SCOPE)
endfunction(_import)

_import()

0 comments on commit d40f62c

Please sign in to comment.