OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 #include "vm/bootstrap.h" | 5 #include "vm/bootstrap.h" |
6 | 6 |
7 #include "include/dart_api.h" | 7 #include "include/dart_api.h" |
8 | 8 |
9 #include "vm/bootstrap_natives.h" | 9 #include "vm/bootstrap_natives.h" |
10 #include "vm/class_finalizer.h" | 10 #include "vm/class_finalizer.h" |
11 #include "vm/compiler.h" | 11 #include "vm/compiler.h" |
12 #include "vm/dart_api_impl.h" | 12 #include "vm/dart_api_impl.h" |
13 #if !defined(DART_PRECOMPILED_RUNTIME) | 13 #if !defined(DART_PRECOMPILED_RUNTIME) |
14 #include "vm/kernel.h" | 14 #include "vm/kernel.h" |
15 #include "vm/kernel_reader.h" | 15 #include "vm/kernel_reader.h" |
16 #endif | 16 #endif |
17 #include "vm/object.h" | 17 #include "vm/object.h" |
18 #include "vm/object_store.h" | 18 #include "vm/object_store.h" |
19 #include "vm/symbols.h" | 19 #include "vm/symbols.h" |
20 | 20 |
21 namespace dart { | 21 namespace dart { |
22 | 22 |
23 DEFINE_FLAG(bool, | 23 DEFINE_FLAG(bool, |
24 use_corelib_source_files, | 24 use_corelib_source_files, |
25 false, | 25 kDefaultCorelibSourceFlag, |
26 "Attempt to use source files directly when loading in the core " | 26 "Attempt to use source files directly when loading in the core " |
27 "libraries during the bootstrap process"); | 27 "libraries during the bootstrap process"); |
28 | 28 |
29 struct BootstrapLibProps { | 29 struct BootstrapLibProps { |
30 ObjectStore::BootstrapLibraryId index; | 30 ObjectStore::BootstrapLibraryId index; |
31 const char* uri; | 31 const char* uri; |
32 const char** source_paths; | 32 const char** source_paths; |
33 const char* patch_uri; | 33 const char* patch_uri; |
34 const char** patch_paths; | 34 const char** patch_paths; |
35 }; | 35 }; |
(...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
393 lib.Register(thread); | 393 lib.Register(thread); |
394 isolate->object_store()->set_bootstrap_library(id, lib); | 394 isolate->object_store()->set_bootstrap_library(id, lib); |
395 } | 395 } |
396 } | 396 } |
397 | 397 |
398 return (kernel_program == NULL) ? BootstrapFromSource(thread) | 398 return (kernel_program == NULL) ? BootstrapFromSource(thread) |
399 : BootstrapFromKernel(thread, kernel_program); | 399 : BootstrapFromKernel(thread, kernel_program); |
400 } | 400 } |
401 | 401 |
402 } // namespace dart | 402 } // namespace dart |
OLD | NEW |