From e9e6706da31168073022f0bba3dbc7af5647a92f Mon Sep 17 00:00:00 2001 From: Al Liu Date: Sun, 15 Sep 2024 14:31:23 +0800 Subject: [PATCH] Update miri_tb.sh --- ci/miri_tb.sh | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/ci/miri_tb.sh b/ci/miri_tb.sh index 963a8ac..22095de 100755 --- a/ci/miri_tb.sh +++ b/ci/miri_tb.sh @@ -1,13 +1,24 @@ #!/bin/bash set -e +# Check if TARGET and FEATURES are provided, otherwise panic +if [ -z "$1" ]; then + echo "Error: TARGET is not provided" + exit 1 +fi + +if [ -z "$2" ]; then + echo "Error: FEATURES are not provided" + exit 1 +fi + +TARGET=$1 +FEATURES=$2 + rustup toolchain install nightly --component miri rustup override set nightly cargo miri setup -# Default target platform and features if none are passed -TARGET=${1:-x86_64-unknown-linux-gnu} -FEATURES=${2:-test-swmr} export MIRIFLAGS="-Zmiri-symbolic-alignment-check -Zmiri-disable-isolation -Zmiri-tree-borrows"