Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(194)

Unified Diff: build/gyp_chromium

Issue 103193003: Convert GN hyphens to underscores when passing command line args. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/gyp_chromium
diff --git a/build/gyp_chromium b/build/gyp_chromium
index 8409a28de114918e09ce23a46caaebe2a10c7e33..2d13d1566ffde8314e1f22258eedd2b4cc759eba 100755
--- a/build/gyp_chromium
+++ b/build/gyp_chromium
@@ -79,12 +79,14 @@ def GetVarsStringForGN(supplemental_files):
items = shlex.split(env_string)
for item in items:
tokens = item.split('=', 1)
+ # Some GYP variables have hyphens, which we don't support.
+ key = tokens[0].replace("-", "_")
if len(tokens) == 2:
# Escape $ characters which have special meaning to GN.
- vars_dict[tokens[0]] = '"' + tokens[1].replace("$", "\\$") + '"'
+ vars_dict[key] = '"' + tokens[1].replace("$", "\\$") + '"'
else:
# No value supplied, treat it as a boolean and set it.
- vars_dict[tokens[0]] = 'true'
+ vars_dict[key] = 'true'
vars_string = ''
for v in vars_dict:
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698