| OLD | NEW | 
|---|
| 1 # Copyright 2011 the V8 project authors. All rights reserved. | 1 # Copyright 2011 the V8 project authors. All rights reserved. | 
| 2 # Redistribution and use in source and binary forms, with or without | 2 # Redistribution and use in source and binary forms, with or without | 
| 3 # modification, are permitted provided that the following conditions are | 3 # modification, are permitted provided that the following conditions are | 
| 4 # met: | 4 # met: | 
| 5 # | 5 # | 
| 6 #     * Redistributions of source code must retain the above copyright | 6 #     * Redistributions of source code must retain the above copyright | 
| 7 #       notice, this list of conditions and the following disclaimer. | 7 #       notice, this list of conditions and the following disclaimer. | 
| 8 #     * Redistributions in binary form must reproduce the above | 8 #     * Redistributions in binary form must reproduce the above | 
| 9 #       copyright notice, this list of conditions and the following | 9 #       copyright notice, this list of conditions and the following | 
| 10 #       disclaimer in the documentation and/or other materials provided | 10 #       disclaimer in the documentation and/or other materials provided | 
| (...skipping 13 matching lines...) Expand all  Loading... | 
| 24 # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 24 # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 
| 25 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 25 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 
| 26 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 26 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 
| 27 | 27 | 
| 28 import sys | 28 import sys | 
| 29 from os.path import join, dirname, abspath | 29 from os.path import join, dirname, abspath | 
| 30 root_dir = dirname(File('SConstruct').rfile().abspath) | 30 root_dir = dirname(File('SConstruct').rfile().abspath) | 
| 31 sys.path.append(join(root_dir, 'tools')) | 31 sys.path.append(join(root_dir, 'tools')) | 
| 32 import js2c | 32 import js2c | 
| 33 Import('context') | 33 Import('context') | 
|  | 34 Import('tools') | 
| 34 | 35 | 
| 35 | 36 | 
| 36 SOURCES = { | 37 SOURCES = { | 
| 37   'all': Split(""" | 38   'all': Split(""" | 
| 38     accessors.cc | 39     accessors.cc | 
| 39     allocation.cc | 40     allocation.cc | 
| 40     api.cc | 41     api.cc | 
| 41     assembler.cc | 42     assembler.cc | 
| 42     ast.cc | 43     ast.cc | 
| 43     atomicops_internals_x86_gcc.cc | 44     atomicops_internals_x86_gcc.cc | 
| (...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 298 debug-debugger.js | 299 debug-debugger.js | 
| 299 '''.split() | 300 '''.split() | 
| 300 | 301 | 
| 301 | 302 | 
| 302 def Abort(message): | 303 def Abort(message): | 
| 303   print message | 304   print message | 
| 304   sys.exit(1) | 305   sys.exit(1) | 
| 305 | 306 | 
| 306 | 307 | 
| 307 def ConfigureObjectFiles(): | 308 def ConfigureObjectFiles(): | 
| 308   env = Environment() | 309   env = Environment(tools=tools) | 
| 309   env.Replace(**context.flags['v8']) | 310   env.Replace(**context.flags['v8']) | 
| 310   context.ApplyEnvOverrides(env) | 311   context.ApplyEnvOverrides(env) | 
| 311   env['BUILDERS']['JS2C'] = Builder(action=js2c.JS2C) | 312   env['BUILDERS']['JS2C'] = Builder(action=js2c.JS2C) | 
| 312   env['BUILDERS']['Snapshot'] = Builder(action='$SOURCE $TARGET --logfile "$LOGF
     ILE" --log-snapshot-positions') | 313   env['BUILDERS']['Snapshot'] = Builder(action='$SOURCE $TARGET --logfile "$LOGF
     ILE" --log-snapshot-positions') | 
| 313 | 314 | 
| 314   # Build the standard platform-independent source files. | 315   # Build the standard platform-independent source files. | 
| 315   source_files = context.GetRelevantSources(SOURCES) | 316   source_files = context.GetRelevantSources(SOURCES) | 
| 316 | 317 | 
| 317   d8_files = context.GetRelevantSources(D8_FILES) | 318   d8_files = context.GetRelevantSources(D8_FILES) | 
| 318   d8_js = env.JS2C('d8-js.cc', 'd8.js', TYPE='D8') | 319   d8_js = env.JS2C('d8-js.cc', 'd8.js', TYPE='D8') | 
| (...skipping 28 matching lines...) Expand all  Loading... | 
| 347       snapshot_cc = 'snapshot.cc' | 348       snapshot_cc = 'snapshot.cc' | 
| 348     snapshot_obj = context.ConfigureObject(env, snapshot_cc, CPPPATH=['.']) | 349     snapshot_obj = context.ConfigureObject(env, snapshot_cc, CPPPATH=['.']) | 
| 349   else: | 350   else: | 
| 350     snapshot_obj = empty_snapshot_obj | 351     snapshot_obj = empty_snapshot_obj | 
| 351   library_objs = [non_snapshot_files, libraries_obj, snapshot_obj] | 352   library_objs = [non_snapshot_files, libraries_obj, snapshot_obj] | 
| 352   return (library_objs, d8_objs, [mksnapshot]) | 353   return (library_objs, d8_objs, [mksnapshot]) | 
| 353 | 354 | 
| 354 | 355 | 
| 355 (library_objs, d8_objs, mksnapshot) = ConfigureObjectFiles() | 356 (library_objs, d8_objs, mksnapshot) = ConfigureObjectFiles() | 
| 356 Return('library_objs d8_objs mksnapshot') | 357 Return('library_objs d8_objs mksnapshot') | 
| OLD | NEW | 
|---|