From 2436633f53194448285743a9f5580997f6a09642 Mon Sep 17 00:00:00 2001 From: raul-marquez-csa Date: Fri, 19 Jan 2024 01:27:43 -0800 Subject: [PATCH] Adds chip_enable_icd_server=true for lock app gn command Renames GnBuildArgs to GnBuildArgsLocal in gn.py as it was being overriden by HostBuilder in host.py --- scripts/build/builders/gn.py | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/scripts/build/builders/gn.py b/scripts/build/builders/gn.py index 75f6bb02c4231e..17dd65c628cc27 100644 --- a/scripts/build/builders/gn.py +++ b/scripts/build/builders/gn.py @@ -30,12 +30,18 @@ def __init__(self, root, runner): self.build_command = None - def GnBuildArgs(self): + def GnBuildArgsLocal(self): """Extra gn build `--args` If used, returns a list of arguments. """ - return None + + extra_args = [] + + if "/lock-app" in self.root: + extra_args.append("chip_enable_icd_server=true") + + return extra_args def GnBuildEnv(self): """Extra environment variables needed for the GN build to run. @@ -67,7 +73,7 @@ def generate(self): if self.options.pregen_dir: extra_args.append('chip_code_pre_generated_directory="%s"' % self.options.pregen_dir) - extra_args.extend(self.GnBuildArgs() or []) + extra_args.extend(self.GnBuildArgsLocal()) if extra_args: cmd += ['--args=%s' % ' '.join(extra_args)]