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

Unified Diff: webkit/build/rule_binding.py

Issue 149207: Proper fix for the "thousands of macro names must be identifiers" bug.... (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/trunk/src/
Patch Set: Removed obsolete comment. Created 11 years, 5 months 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: webkit/build/rule_binding.py
===================================================================
--- webkit/build/rule_binding.py (revision 19952)
+++ webkit/build/rule_binding.py (working copy)
@@ -19,6 +19,7 @@
import errno
import os
+import shlex
import shutil
import subprocess
import sys
@@ -68,14 +69,21 @@
if not include_dir in include_dirs:
include_dirs.append(include_dir)
+ # The defines come in as one flat string. Split it up into distinct arguments.
+ if '--defines' in options:
+ defines_index = options.index('--defines')
+ if defines_index + 1 < len(options):
+ split_options = shlex.split(options[defines_index + 1])
+ if split_options:
+ options[defines_index + 1:defines_index + 2] = \
Mark Mentovai 2009/07/06 18:26:47 If we're just doing ' '.join, you don't need to sp
+ [' '.join(split_options)]
+
# Build up the command.
command = ['perl', '-w']
for include_dir in include_dirs:
command.extend(['-I', include_dir])
command.append(generate_bindings)
- # Remove any qouble qoutes that may have gotten in here. We know that none of
- # the options will have meaningful double qoutes.
- command.extend([option.replace('"', '') for option in options])
+ command.extend(options)
command.extend(['--outputDir', cppdir, input])
# Do it. check_call is new in 2.5, so simulate its behavior with call and
« 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