From f55793c830fb9250c97717a15bb9866603c110da Mon Sep 17 00:00:00 2001 From: byteZorvin Date: Sat, 22 Jun 2024 20:37:17 +0530 Subject: [PATCH] fix build error on apple darwin --- scripts/setup.sh | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/scripts/setup.sh b/scripts/setup.sh index 1418482..dde1e15 100755 --- a/scripts/setup.sh +++ b/scripts/setup.sh @@ -30,8 +30,15 @@ printf "${COLOR_OFF}" mkdir -p .downloads cd .downloads -wget -c https://github.com/starkware-libs/cairo/releases/download/v2.6.3/release-x86_64-unknown-linux-musl.tar.gz -O - | tar -xz -curl https://binaries.soliditylang.org/linux-amd64/solc-linux-amd64-v0.8.20+commit.a1b79de6 -o solc-0.8.20 && chmod +x solc-0.8.20 + +if [ "$(uname)" == "Darwin" ]; then + # Do something under Mac OS X platform + wget -c https://github.com/starkware-libs/cairo/releases/download/v2.6.3/release-aarch64-apple-darwin.tar -O - | tar -xz + curl https://binaries.soliditylang.org/linux-amd64/solc-macos-amd64-v0.8.20+commit.a1b79de6 -o solc-0.8.20 && chmod +x solc-0.8.20 +else + wget -c https://github.com/starkware-libs/cairo/releases/download/v2.6.3/release-x86_64-unknown-linux-musl.tar.gz -O - | tar -xz + curl https://binaries.soliditylang.org/linux-amd64/solc-linux-amd64-v0.8.20+commit.a1b79de6 -o solc-0.8.20 && chmod +x solc-0.8.20 +fi cd .. rm -rf starkware