From f064ff8848e75b034e1e567e73a8b8e35c3a9eab Mon Sep 17 00:00:00 2001 From: David Biancolin Date: Wed, 8 Sep 2021 21:06:05 +0000 Subject: [PATCH] [CI] Update setup for firesim tests --- .circleci/run-firesim-scala-tests.sh | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/.circleci/run-firesim-scala-tests.sh b/.circleci/run-firesim-scala-tests.sh index 23c4d08a..a848df62 100755 --- a/.circleci/run-firesim-scala-tests.sh +++ b/.circleci/run-firesim-scala-tests.sh @@ -13,13 +13,20 @@ source $SCRIPT_DIR/defaults.sh # call clean on exit trap clean EXIT +# Directory locations for handling firesim-local installations of libelf/libdwarf +# This would generally be handled by build-setup.sh/firesim-setup.sh +firesim_sysroot=lib-install +local_firesim_sysroot=$LOCAL_FIRESIM_DIR/$firesim_sysroot +remote_firesim_sysroot=$REMOTE_FIRESIM_DIR/$firesim_sysroot + cd $LOCAL_CHIPYARD_DIR ./scripts/init-submodules-no-riscv-tools.sh cd $LOCAL_CHIPYARD_DIR/sims/firesim/sim/firesim-lib/src/main/cc/lib git submodule update --init elfutils libdwarf cd $LOCAL_CHIPYARD_DIR/sims/firesim -./scripts/build-libelf.sh -./scripts/build-libdwarf.sh +mkdir -p $local_firesim_sysroot +./scripts/build-libelf.sh $local_firesim_sysroot +./scripts/build-libdwarf.sh $local_firesim_sysroot cd $LOCAL_CHIPYARD_DIR # replace the workspace dir with a local dir so you can copy around @@ -42,8 +49,8 @@ run "cp -r ~/.ivy2 $REMOTE_WORK_DIR" run "cp -r ~/.sbt $REMOTE_WORK_DIR" TOOLS_DIR=$REMOTE_RISCV_DIR -LD_LIB_DIR=$REMOTE_RISCV_DIR/lib +LD_LIB_DIR=$remote_firesim_sysroot/lib:$REMOTE_RISCV_DIR/lib # Run Firesim Scala Tests run "export RISCV=\"$TOOLS_DIR\"; \