Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 23d4dcb

Browse files
committed
allow supplying custom gn args in gn wrapper
1 parent 393b564 commit 23d4dcb

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tools/gn

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1119,6 +1119,8 @@ def parse_args(args):
11191119
# Verbose output.
11201120
parser.add_argument('--verbose', default=False, action='store_true')
11211121

1122+
parser.add_argument('--gn-args', default=[], action='append')
1123+
11221124
return parser.parse_args(args)
11231125

11241126

@@ -1174,6 +1176,7 @@ def main(argv):
11741176
command.append('--export-compile-commands=default')
11751177

11761178
gn_args = to_command_line(to_gn_args(args))
1179+
gn_args.extend(args.gn_args or [])
11771180
out_dir = get_out_dir(args)
11781181
command.append(out_dir)
11791182
command.append('--args=%s' % ' '.join(gn_args))

0 commit comments

Comments
 (0)