diff options
author | Tracy Narine <tracy.narine@arm.com> | 2024-02-26 15:05:11 +0000 |
---|---|---|
committer | Tracy Narine <tracy.narine@arm.com> | 2024-02-28 14:17:52 +0000 |
commit | 2883a86c5a167aea3c736529bff5921ab6cbc99c (patch) | |
tree | d9e000d96246c622d82e185af186a0bf64b2896c /build-tool/scripts/common.sh | |
parent | c24577b21f4e8f4a1253632e31dea5d39a17ca26 (diff) | |
download | armnn-2883a86c5a167aea3c736529bff5921ab6cbc99c.tar.gz |
IVGCVSW-8172 Add macOS support to build tool setup
* Updates build rules for platform
* Failing unit tests excluded (dynamic backends, profiling)
* install-packages.sh generates manual setup information
Signed-off-by: Tracy Narine <tracy.narine@arm.com>
Change-Id: I2d3d434aa615a8796c0cb94cd5b9c35a5acfd148
Diffstat (limited to 'build-tool/scripts/common.sh')
-rwxr-xr-x | build-tool/scripts/common.sh | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/build-tool/scripts/common.sh b/build-tool/scripts/common.sh index e68de99c9d..0c34c7e7df 100755 --- a/build-tool/scripts/common.sh +++ b/build-tool/scripts/common.sh @@ -1,6 +1,6 @@ #!/bin/bash # -# Copyright © 2022-2023 Arm Ltd and Contributors. All rights reserved. +# Copyright © 2022-2024 Arm Ltd and Contributors. All rights reserved. # SPDX-License-Identifier: MIT # @@ -34,9 +34,16 @@ TARGET_ARCH="$target_arch" NATIVE_BUILD=0 if [ "$TARGET_ARCH" == "$HOST_ARCH" ]; then NATIVE_BUILD=1 +elif [ "$TARGET_ARCH" == "aarch64" ]; then + if [ "$HOST_ARCH" == "arm64" ]; then + NATIVE_BUILD=1 + fi fi AARCH64_COMPILER_FLAGS+="CC=/usr/bin/aarch64-linux-gnu-gcc CXX=/usr/bin/aarch64-linux-gnu-g++ " +if [ "$HOST_ARCH" == "arm64" ]; then + AARCH64_COMPILER_FLAGS+="CC=/usr/bin/clang CXX=/usr/bin/clang++ " +fi # NDK NDK_VERSION=26b @@ -74,7 +81,11 @@ PROTOBUF_BUILD_ROOT="$BUILD_DIR"/protobuf PROTOBUF_BUILD_HOST="$PROTOBUF_BUILD_ROOT"/"$HOST_ARCH"_build PROTOCOL_COMPILER_HOST="$PROTOBUF_BUILD_HOST"/bin/protoc PROTOBUF_BUILD_TARGET="$PROTOBUF_BUILD_ROOT"/"$TARGET_ARCH"_build -PROTOBUF_LIBRARY_TARGET="$PROTOBUF_BUILD_TARGET"/lib/libprotobuf.so.23.0.0 +if [ "$osname" == "Darwin" ]; then + PROTOBUF_LIBRARY_TARGET="$PROTOBUF_BUILD_HOST"/lib/libprotobuf.dylib +else + PROTOBUF_LIBRARY_TARGET="$PROTOBUF_BUILD_TARGET"/lib/libprotobuf.so.23.0.0 +fi PROTOBUF_ANDROID_LIB_TARGET="$PROTOBUF_BUILD_TARGET"/lib/libprotobuf.so # ONNX |