Bug 1730619: Associate build commands with "build" venv r=ahal

The `build-backend` command uses
`command_context.virtualenv_manager`, which by default
is associated with the "common" virtualenv.

This patch aligns `virtualenv_manager` with the "build"
virtualenv as set up within `init.configure`.

Differential Revision: https://phabricator.services.mozilla.com/D125592
This commit is contained in:
Mitchell Hentges 2021-09-16 14:15:04 +00:00
parent fba105d5de
commit 59f1f60c4d

View File

@ -78,6 +78,7 @@ class Build(MachCommandBase):
category="build",
description="Build the tree.",
metrics_path=MOZBUILD_METRICS_PATH,
virtualenv_name="build",
)
@CommandArgument(
"--jobs",
@ -238,6 +239,7 @@ class Build(MachCommandBase):
category="build",
description="Configure the tree (run configure and config.status).",
metrics_path=MOZBUILD_METRICS_PATH,
virtualenv_name="build",
)
@CommandArgument(
"options", default=None, nargs=argparse.REMAINDER, help="Configure options"
@ -265,6 +267,7 @@ class Build(MachCommandBase):
"resource-usage",
category="post-build",
description="Show information about system resource usage for a build.",
virtualenv_name="build",
)
@CommandArgument(
"--address",
@ -320,6 +323,7 @@ class Build(MachCommandBase):
"build-backend",
category="build",
description="Generate a backend used to build the tree.",
virtualenv_name="build",
)
@CommandArgument(
"-d", "--diff", action="store_true", help="Show a diff of changes."