set CARGO_HOME to $SRCDEST/cargo

CARGO_HOME tells cargo where to store installed dependencies, save it to
a directory in $SRCDEST so we don't need to download all dependencies
again when compiling a rust package.
This commit is contained in:
Leo 2020-02-12 15:56:24 -03:00 committed by Sören Tempel
parent e125a76489
commit af0c88e6ab

View File

@ -2643,6 +2643,7 @@ aportsgit=${APORTSDIR:-${startdir}}
repo_template=$aportsgit/$repo/.rootbld-repositories repo_template=$aportsgit/$repo/.rootbld-repositories
SRCDEST=${SRCDEST:-$startdir} SRCDEST=${SRCDEST:-$startdir}
CARGO_HOME=$SRCDEST/cargo
BUILD_ROOT= BUILD_ROOT=
@ -2661,7 +2662,7 @@ if [ -z "$REPODEST" ]; then
fi fi
# for recursive action # for recursive action
export REPODEST SRCDEST export REPODEST SRCDEST CARGO_HOME
# add dbg subpackage if its enabled globally # add dbg subpackage if its enabled globally
if [ -n "$DEFAULT_DBG" ] && ! subpackage_types_has "dbg" && ! options_has "!dbg" && [ "$arch" != "noarch" ]; then if [ -n "$DEFAULT_DBG" ] && ! subpackage_types_has "dbg" && ! options_has "!dbg" && [ "$arch" != "noarch" ]; then