diff options
author | James Conroy <james.conroy@arm.com> | 2022-11-01 15:01:06 +0000 |
---|---|---|
committer | ryan.oshea3 <ryan.oshea3@arm.com> | 2022-11-02 10:50:37 +0000 |
commit | 2e950f4fa774ac995230addea898f3b11bf146cc (patch) | |
tree | 34fd319c0cb71898898fbf9445541004e8de2711 /build-tool/scripts/setup-armnn.sh | |
parent | a38da5989dc51fe2665480d18a9dd9dff6bb1115 (diff) | |
download | armnn-2e950f4fa774ac995230addea898f3b11bf146cc.tar.gz |
Fix TF Lite cross compile for build-tool
* Build Flatc only on x86_64 when cross compiling
* Add Linux CMAKE System name
Signed-off-by: Ryan OShea <ryan.oshea3@arm.com>
Change-Id: Ibd0f636b3cc149e0492d66330baf0e3707a9d3f7
Diffstat (limited to 'build-tool/scripts/setup-armnn.sh')
-rwxr-xr-x | build-tool/scripts/setup-armnn.sh | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/build-tool/scripts/setup-armnn.sh b/build-tool/scripts/setup-armnn.sh index b016b53bd0..67dcd1b843 100755 --- a/build-tool/scripts/setup-armnn.sh +++ b/build-tool/scripts/setup-armnn.sh @@ -113,7 +113,7 @@ build_flatbuffers() find . -mindepth 1 -name "*_build" -prune -o -exec rm -rf {} + eval "$cmake_flags" \ - cmake -DFLATBUFFERS_BUILD_FLATC=1 \ + cmake -DFLATBUFFERS_BUILD_FLATC="$native_build" \ -DCMAKE_INSTALL_PREFIX:PATH="$build_dir" \ -DFLATBUFFERS_BUILD_TESTS=0 \ "$FLATBUFFERS_SRC" @@ -145,7 +145,8 @@ build_tflite() case "$TARGET_ARCH" in "aarch64") cmake_flags+="$AARCH64_COMPILER_FLAGS" - target_arch_cmd="-DCMAKE_SYSTEM_PROCESSOR=aarch64 " + target_arch_cmd="-DCMAKE_SYSTEM_PROCESSOR=aarch64 \ + -DCMAKE_SYSTEM_NAME=Linux " if [ "$NATIVE_BUILD" -eq 0 ]; then cmake_flags+="ARMCC_FLAGS='-funsafe-math-optimizations' " |