Allow build dir to be changed from /tmp
Adds an env var TMP_DIR which will override mktemp's default location. Fixes bug 1168432 Change-Id: I60c63389bb2a639f948e7e96bf9aaea0ea73e27d
This commit is contained in:
parent
66b563e466
commit
8a22115c6d
@ -14,7 +14,7 @@
|
|||||||
# under the License.
|
# under the License.
|
||||||
|
|
||||||
function mk_build_dir () {
|
function mk_build_dir () {
|
||||||
export TMP_BUILD_DIR=$(mktemp -t -d image.XXXXXXXX)
|
export TMP_BUILD_DIR=$(mktemp -t -d --tmpdir=${TMP_DIR:-/tmp} image.XXXXXXXX)
|
||||||
[ $? -eq 0 ] || die "Failed to create tmp directory"
|
[ $? -eq 0 ] || die "Failed to create tmp directory"
|
||||||
trap cleanup EXIT
|
trap cleanup EXIT
|
||||||
echo Building in $TMP_BUILD_DIR
|
echo Building in $TMP_BUILD_DIR
|
||||||
|
Loading…
Reference in New Issue
Block a user