зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1916043 - Don't try to run clangd for artifact builds. r=sergesanspaille
This fixes the bad caller. Differential Revision: https://phabricator.services.mozilla.com/D220802
This commit is contained in:
Родитель
09d40fa51e
Коммит
54385cf32f
|
@ -33,12 +33,14 @@ from mozbuild.util import cpu_count
|
|||
def run(command_context, ide, no_interactive, args):
|
||||
interactive = not no_interactive
|
||||
|
||||
backend = None
|
||||
if ide == "eclipse":
|
||||
backend = "CppEclipse"
|
||||
elif ide == "visualstudio":
|
||||
backend = "VisualStudio"
|
||||
elif ide == "vscode":
|
||||
backend = "Clangd"
|
||||
if not command_context.config_environment.is_artifact_build:
|
||||
backend = "Clangd"
|
||||
|
||||
if ide == "eclipse" and not which("eclipse"):
|
||||
command_context.log(
|
||||
|
@ -90,15 +92,16 @@ def run(command_context, ide, no_interactive, args):
|
|||
if res != 0:
|
||||
return 1
|
||||
|
||||
# Generate or refresh the IDE backend.
|
||||
python = command_context.virtualenv_manager.python_path
|
||||
config_status = os.path.join(command_context.topobjdir, "config.status")
|
||||
args = [python, config_status, "--backend=%s" % backend]
|
||||
res = command_context._run_command_in_objdir(
|
||||
args=args, pass_thru=True, ensure_exit_code=False
|
||||
)
|
||||
if res != 0:
|
||||
return 1
|
||||
if backend:
|
||||
# Generate or refresh the IDE backend.
|
||||
python = command_context.virtualenv_manager.python_path
|
||||
config_status = os.path.join(command_context.topobjdir, "config.status")
|
||||
args = [python, config_status, "--backend=%s" % backend]
|
||||
res = command_context._run_command_in_objdir(
|
||||
args=args, pass_thru=True, ensure_exit_code=False
|
||||
)
|
||||
if res != 0:
|
||||
return 1
|
||||
|
||||
if ide == "eclipse":
|
||||
eclipse_workspace_dir = get_eclipse_workspace_path(command_context)
|
||||
|
|
Загрузка…
Ссылка в новой задаче