-
Notifications
You must be signed in to change notification settings - Fork 539
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: make bootstrap_impl=script compute correct directory when RUNFIL…
…ES_MANIFEST_FILE set (#2177) The script-based bootstrap wasn't computing the correct runfiles directory when `RUNFILES_MANIFEST_FILE` was set. The path it computed stripped off the manifest file name, but didn't re-add the `.runfiles` suffix to point to the runfiles directory. To fix, just re-append the `.runfiles` suffix after it removes the manifest file name portion of the path. Reproducing this is a bit tricky and it's difficult to reproduce the necessary build flags in a test; all of the following must be met: * `--enable_runfiles=false`, but this cannot be set by transitions, only via command line * `--build_runfile_manifests=true` (this can be set in a transition, but see below) * Due to bazelbuild/bazel#7994, even if a manifest is created, the RUNFILES_MANIFEST_FILE env var won't be set _unless_ the test strategy is local (i.e. not sandboxed, which is the default). To work around those issues, the test just recreates the necessary envvar state and invokes the binary. The underlying files may not exist, but that's OK for the code paths were testing. Fixes #2186 --------- Co-authored-by: Richard Levasseur <rlevasseur@google.com>
- Loading branch information
1 parent
3fd5b83
commit 65d1326
Showing
3 changed files
with
48 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters