aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Sloyan <matthew.sloyan@arm.com>2021-02-09 16:46:14 +0000
committerMatthew Sloyan <matthew.sloyan@arm.com>2021-02-09 16:46:14 +0000
commit29fde27f863ce82a2604270cfa7216904f1f171b (patch)
treec9afaa63e24438f0c172e42e15749f8b99983dc1
parentac6939a3334e9102fd9d11336221e234ebb29819 (diff)
downloadarmnn-29fde27f863ce82a2604270cfa7216904f1f171b.tar.gz
IVGCVSW-5679 Fix Android NDK OOB build
* Specific OOB builds will fail if flatc is not available. * flatc command is now only run if found. Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com> Change-Id: Iab6e082fe35dc3c3dfb78a29e1630c9edbb80be6
-rw-r--r--src/backends/cl/CMakeLists.txt14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/backends/cl/CMakeLists.txt b/src/backends/cl/CMakeLists.txt
index 60cdaa314d..78771a027e 100644
--- a/src/backends/cl/CMakeLists.txt
+++ b/src/backends/cl/CMakeLists.txt
@@ -8,15 +8,15 @@ if(ARMCOMPUTECL)
HINTS ${FLATC_DIR}
DOC "Path to 'flatc', the flatbuffers compiler")
if (NOT FLATC)
- message(SEND_ERROR "flatc not found. Specify the full path of the flatc executable with -DFLATC=<flatc path>")
+ message(WARNING "flatc not found. Specify the full path of the flatc executable with -DFLATC=<flatc path>")
+ else()
+ add_custom_command(
+ # Updates ClContextSchema_generated.h if changes are made.
+ OUTPUT ClContextSchema_generated.h DEPENDS ClContextSchema.fbs
+ COMMAND ${FLATC} -o ${CMAKE_CURRENT_BINARY_DIR} --cpp ${CMAKE_CURRENT_SOURCE_DIR}/ClContextSchema.fbs
+ )
endif()
- add_custom_command(
- # Generate an ClContextSchema_generated.h file if it doesn't exist, or update it when necessary otherwise
- OUTPUT ClContextSchema_generated.h DEPENDS ClContextSchema.fbs
- COMMAND ${FLATC} -o ${CMAKE_CURRENT_BINARY_DIR} --cpp ${CMAKE_CURRENT_SOURCE_DIR}/ClContextSchema.fbs
- )
-
list(APPEND armnnClBackend_sources
ClContextSchema_generated.h
ClBackend.cpp