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

Unified Diff: Source/core/core.gyp/scripts/action_makenames.py

Issue 14456006: Fixes to make scripts generate includes with paths. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Updated to a newer chromium version Created 7 years, 8 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 | « Source/core/core.gyp/core_derived_sources.gyp ('k') | Source/core/scripts/InFilesCompiler.pm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/core.gyp/scripts/action_makenames.py
diff --git a/Source/core/core.gyp/scripts/action_makenames.py b/Source/core/core.gyp/scripts/action_makenames.py
index 4cf45cd6c988328d6b2acdc9f3eff1746f656f62..bd07af4941b4e80d37724b2b74c2cefa94c726e1 100644
--- a/Source/core/core.gyp/scripts/action_makenames.py
+++ b/Source/core/core.gyp/scripts/action_makenames.py
@@ -87,7 +87,11 @@ def SplitArgsIntoSections(args):
def main(args):
- sections = SplitArgsIntoSections(args[1:])
+ if args[1] != "--idlToPathFile" or len(args) < 3:
+ print "FATAL: Missing --idlToPathFile argument: " + str(args)
+ return 1
+ idlToPathFile = args[2]
+ sections = SplitArgsIntoSections(args[3:])
assert len(sections) == 2 or len(sections) == 3
(outputs, inputs) = sections[:2]
if len(sections) == 3:
@@ -131,10 +135,10 @@ def main(args):
eventsInput = inputAbsPosix
elif inputBasename.endswith('Names.in'):
options.append(inputAbsPosix)
- elif inputBasename.endswith('.pm'):
+ elif inputBasename.endswith('.pm') or inputBasename.endswith('.py'):
continue
else:
- assert False
+ assert False, "Unexcepted file type "+ inputeBasename
assert makeNamesInput != None
assert tagInput != None or attrInput != None or eventsInput != None or ('--fonts' in options)
@@ -144,18 +148,23 @@ def main(args):
scriptsPath = os.path.normpath(
os.path.join(os.path.dirname(makeNamesInput), os.pardir, 'scripts'))
+ # bindingsScriptPath is a Perl include directory for some helper libraries make_names.pl uses.
+ bindingsScriptPath = os.path.normpath(
+ os.path.join(os.path.dirname(makeNamesInput), os.pardir, os.pardir, 'bindings', 'scripts'))
+
# Change to the output directory because make_names.pl puts output in its
# working directory.
os.chdir(outputDir)
# Build up the command.
- command = ['perl', '-I', scriptsPath, makeNamesInput]
+ command = ['perl', '-I', scriptsPath, '-I', bindingsScriptPath, makeNamesInput]
if tagInput != None:
command.extend(['--tags', tagInput])
if attrInput != None:
command.extend(['--attrs', attrInput])
if eventsInput != None:
command.extend(['--input', eventsInput])
+ command.extend(['--idltopathfile', idlToPathFile])
command.extend(options)
# Do it. check_call is new in 2.5, so simulate its behavior with call and
« no previous file with comments | « Source/core/core.gyp/core_derived_sources.gyp ('k') | Source/core/scripts/InFilesCompiler.pm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698