diff --git a/setup_odin.sh b/setup_odin.sh index 7c30abd..967e48e 100755 --- a/setup_odin.sh +++ b/setup_odin.sh @@ -5,8 +5,9 @@ ODIN_RELEASE_ID=dev-2024-03 echo "Setting up LLVM 14 and Odin ${ODIN_RELEASE_ID}..." wget -O odin.zip -q https://github.com/odin-lang/Odin/releases/download/${ODIN_RELEASE_ID}/odin-ubuntu-amd64-${ODIN_RELEASE_ID}.zip -unzip odin.zip -d /home/runner/odin -chmod +x /home/runner/odin/odin +unzip odin.zip +unzip dist.zip +cp -r dist/* /home/runner/odin echo "/home/runner/odin" >>$GITHUB_PATH echo "/usr/lib/llvm-14/bin" >>$GITHUB_PATH @@ -17,3 +18,21 @@ echo "Done!" echo "llvm: $(llvm-config --version)" echo "wasm-ld: $(wasm-ld --version)" echo "odin: $(odin version)" + +if ! command -v llvm-config &> /dev/null +then + echo "llvm-config could not be found" + exit 1 +fi + +if ! command -v wasm-ld &> /dev/null +then + echo "wasm-ld could not be found" + exit 1 +fi + +if ! command -v odin &> /dev/null +then + echo "odin could not be found" + exit 1 +fi \ No newline at end of file