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

Side by Side Diff: tools/dom/scripts/dartdomgenerator.py

Issue 1768853002: Match version of idl_parser and WebCore so go.sh can be run from a Dart only enlistment. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Updated commnet Created 4 years, 9 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 unified diff | Download patch
« no previous file with comments | « tools/.gitignore ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/python 1 #!/usr/bin/python
2 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 2 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
3 # for details. All rights reserved. Use of this source code is governed by a 3 # for details. All rights reserved. Use of this source code is governed by a
4 # BSD-style license that can be found in the LICENSE file. 4 # BSD-style license that can be found in the LICENSE file.
5 5
6 """This is the entry point to create Dart APIs from the IDL database.""" 6 """This is the entry point to create Dart APIs from the IDL database."""
7 7
8 import css_code_generator 8 import css_code_generator
9 import os 9 import os
10 import sys 10 import sys
(...skipping 11 matching lines...) Expand all
22 third_party_dir = os.path.join(dart_dir, 'third_party') 22 third_party_dir = os.path.join(dart_dir, 'third_party')
23 23
24 ply_dir = os.path.join(third_party_dir, 'ply') 24 ply_dir = os.path.join(third_party_dir, 'ply')
25 # If ply directory found then we're a Dart enlistment; third_party location 25 # If ply directory found then we're a Dart enlistment; third_party location
26 # is dart-git/dart/third_party 26 # is dart-git/dart/third_party
27 if not os.path.exists(ply_dir): 27 if not os.path.exists(ply_dir):
28 # For Dartium (ply directory is dartium-git/src/third_party/ply) third_party 28 # For Dartium (ply directory is dartium-git/src/third_party/ply) third_party
29 # location is dartium-git/src/third_party 29 # location is dartium-git/src/third_party
30 third_party_dir = os.path.join(dart_dir, '..', 'third_party') 30 third_party_dir = os.path.join(dart_dir, '..', 'third_party')
31 assert(os.path.exists(third_party_dir)) 31 assert(os.path.exists(third_party_dir))
32 else:
33 # It's Dart we need to make sure that tools in injected in our search path
34 # because this is where idl_parser is located for a Dart enlistment. Dartium
35 # can firgure out the tools directory because of the location of where the
36 # scripts blink scripts are located.
37 tools_dir = os.path.join(dart_dir, 'tools')
38 sys.path.insert(1, tools_dir)
39
32 sys.path.insert(1, third_party_dir) 40 sys.path.insert(1, third_party_dir)
33 41
34 sys.path.insert(1, os.path.join(dart_dir, 'tools/dom/scripts')) 42 sys.path.insert(1, os.path.join(dart_dir, 'tools/dom/scripts'))
35 43
36 import dartgenerator 44 import dartgenerator
37 import database 45 import database
38 import fremontcutbuilder 46 import fremontcutbuilder
39 import logging 47 import logging
40 import monitored 48 import monitored
41 import multiemitter 49 import multiemitter
(...skipping 286 matching lines...) Expand 10 before | Expand all | Expand 10 after
328 os.path.join('..', '..', '..', 'sdk', 'lib', '_blink', 'dartium')) 336 os.path.join('..', '..', '..', 'sdk', 'lib', '_blink', 'dartium'))
329 337
330 print '\nGenerating single file %s seconds' % round(time.time() - file_generat ion_start_time, 2) 338 print '\nGenerating single file %s seconds' % round(time.time() - file_generat ion_start_time, 2)
331 339
332 end_time = time.time() 340 end_time = time.time()
333 341
334 print '\nDone (dartdomgenerator) %s seconds' % round(end_time - start_time, 2) 342 print '\nDone (dartdomgenerator) %s seconds' % round(end_time - start_time, 2)
335 343
336 if __name__ == '__main__': 344 if __name__ == '__main__':
337 sys.exit(main()) 345 sys.exit(main())
OLDNEW
« no previous file with comments | « tools/.gitignore ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698