Merge pull request #43503 from volth/bazel-private-tmp

bazel: use per-user tmp directory to avoid conflict with other builders
This commit is contained in:
Pascal Wittmann 2018-07-15 22:22:47 +02:00 committed by GitHub
commit 4a35e7ef1d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 3 deletions

View file

@ -65,8 +65,9 @@ stdenv.mkDerivation rec {
];
buildPhase = ''
export TMPDIR=/tmp/.bazel-$UID
./compile.sh
./output/bazel --output_user_root=/tmp/.bazel build //scripts:bash_completion \
./output/bazel --output_user_root=$TMPDIR/.bazel build //scripts:bash_completion \
--spawn_strategy=standalone \
--genrule_strategy=standalone
cp bazel-bin/scripts/bazel-complete.bash output/

View file

@ -96,9 +96,9 @@ stdenv.mkDerivation rec {
# Change this to $(mktemp -d) as soon as we figure out why.
buildPhase = ''
export TMPDIR=/tmp
export TMPDIR=/tmp/.bazel-$UID
./compile.sh
./output/bazel --output_user_root=/tmp/.bazel build //scripts:bash_completion \
./output/bazel --output_user_root=$TMPDIR/.bazel build //scripts:bash_completion \
--spawn_strategy=standalone \
--genrule_strategy=standalone
cp bazel-bin/scripts/bazel-complete.bash output/