From 9e891b1624e73382f502d6d5b26798c7b887bd02 Mon Sep 17 00:00:00 2001 From: Patrick Gartung Date: Thu, 2 Nov 2023 12:26:40 -0500 Subject: [PATCH] Use spack_source_dir to indicate the relative path of the spack installation to spack_env_top_dir --- bin/build-spack-env.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/bin/build-spack-env.sh b/bin/build-spack-env.sh index b300393..6a117c7 100755 --- a/bin/build-spack-env.sh +++ b/bin/build-spack-env.sh @@ -561,7 +561,7 @@ _copy_back_logs() { mkdir -p "$tar_tmp/"{spack_env,spack-stage} cd "$spack_env_top_dir" _cmd $DEBUG_3 spack clean -dmp - _cmd $DEBUG_3 $PIPE tar -c *.log *-out.txt *.yaml etc var/spack/environments \ + _cmd $DEBUG_3 $PIPE tar -c $spack_source_dir/*.log $spack_source_dir/*-out.txt $spack_source_dir/*.yaml $spack_source_dir/etc $spack_source_dir/spack/environments \ | _cmd $DEBUG_3 tar -C "$tar_tmp/spack_env" -x _cmd $DEBUG_3 $PIPE tar -C "$(spack location -S)" -c . \ | _cmd $DEBUG_3 tar -C "$tar_tmp/spack-stage" -x @@ -1213,9 +1213,9 @@ local_caches=( spack_env_top_dir="$working_dir/spack_env" case "$ups_opt" in - -p) spack_env_top_dir="$working_dir/spack_env";; - -u) spack_env_top_dir="$working_dir/spack_env/spack/$spack_ver/NULL/spack/$spack_ver/NULL/";; - -t) spack_env_top_dir="$working_dir/spack_env/spack/$spack_ver/NULL/spack/$spack_ver/NULL/";; + -p) spack_source_dir="./";; + -u) spack_source_dir="./spack/$spack_ver/NULL/";; + -t) spack_source_dir="./spack/$spack_ver/NULL/";; -*) _die $EXIT_CONFIG_FAILURE "unrecognized --ups option $ups_opt\n$(usage)";; *) break esac