cargo-install-all: use full path for sourcing (#34525)

Use full path for sourcing
This commit is contained in:
Tyera 2023-12-19 12:58:16 -07:00 committed by GitHub
parent 97f02fa05d
commit 51c9963a60
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -17,7 +17,8 @@ if [[ $OSTYPE == darwin* ]]; then
fi
fi
cargo="$("${readlink_cmd}" -f "${here}/../cargo")"
SOLANA_ROOT="$("${readlink_cmd}" -f "${here}/..")"
cargo="${SOLANA_ROOT}/cargo"
set -e
@ -150,7 +151,7 @@ mkdir -p "$installDir/bin"
# Exclude `spl-token` binary for net.sh builds
if [[ -z "$validatorOnly" ]]; then
# shellcheck source=scripts/spl-token-cli-version.sh
source "$here"/spl-token-cli-version.sh
source "$SOLANA_ROOT"/scripts/spl-token-cli-version.sh
# the patch-related configs are needed for rust 1.69+ on Windows; see Cargo.toml
# shellcheck disable=SC2086 # Don't want to double quote $rust_version