Index: runtime/vm/vm.gypi |
diff --git a/runtime/vm/vm.gypi b/runtime/vm/vm.gypi |
index ddb0db7396e62c6f510c167f657b03a57b6ffd08..3bc540793f5714ddba086b8b7bc59b844de202ea 100644 |
--- a/runtime/vm/vm.gypi |
+++ b/runtime/vm/vm.gypi |
@@ -29,6 +29,8 @@ |
'snapshot_test_dart_file': 'snapshot_test.dart', |
'typed_data_cc_file': '<(gen_source_dir)/typed_data_gen.cc', |
'typed_data_patch_cc_file': '<(gen_source_dir)/typed_data_patch_gen.cc', |
+ 'profiler_cc_file': '<(gen_source_dir)/profiler_gen.cc', |
+ 'profiler_patch_cc_file': '<(gen_source_dir)/profiler_patch_gen.cc', |
}, |
'targets': [ |
{ |
@@ -111,6 +113,8 @@ |
'generate_mirrors_patch_cc_file#host', |
'generate_typed_data_cc_file#host', |
'generate_typed_data_patch_cc_file#host', |
+ 'generate_profiler_cc_file#host', |
+ 'generate_profiler_patch_cc_file#host', |
], |
'includes': [ |
'../lib/async_sources.gypi', |
@@ -120,6 +124,7 @@ |
'../lib/math_sources.gypi', |
'../lib/mirrors_sources.gypi', |
'../lib/typed_data_sources.gypi', |
+ '../lib/profiler_sources.gypi', |
], |
'sources': [ |
'bootstrap.cc', |
@@ -142,6 +147,8 @@ |
'<(mirrors_patch_cc_file)', |
'<(typed_data_cc_file)', |
'<(typed_data_patch_cc_file)', |
+ '<(profiler_cc_file)', |
+ '<(profiler_patch_cc_file)', |
], |
'include_dirs': [ |
'..', |
@@ -159,6 +166,7 @@ |
'../lib/math_sources.gypi', |
'../lib/mirrors_sources.gypi', |
'../lib/typed_data_sources.gypi', |
+ '../lib/profiler_sources.gypi', |
], |
'sources': [ |
'bootstrap_nocorelib.cc', |
@@ -887,6 +895,86 @@ |
] |
}, |
{ |
+ 'target_name': 'generate_profiler_cc_file', |
+ 'type': 'none', |
+ 'toolsets':['host'], |
+ 'includes': [ |
+ # Load the shared library sources. |
+ '../../sdk/lib/profiler/profiler_sources.gypi', |
+ ], |
+ 'sources/': [ |
+ # Exclude all .[cc|h] files. |
+ # This is only here for reference. Excludes happen after |
+ # variable expansion, so the script has to do its own |
+ # exclude processing of the sources being passed. |
+ ['exclude', '\\.cc|h$'], |
+ ], |
+ 'actions': [ |
+ { |
+ 'action_name': 'generate_profiler_cc', |
+ 'inputs': [ |
+ '../tools/gen_library_src_paths.py', |
+ '<(libgen_in_cc_file)', |
+ '<@(_sources)', |
+ ], |
+ 'outputs': [ |
+ '<(profiler_cc_file)', |
+ ], |
+ 'action': [ |
+ 'python', |
+ 'tools/gen_library_src_paths.py', |
+ '--output', '<(profiler_cc_file)', |
+ '--input_cc', '<(libgen_in_cc_file)', |
+ '--include', 'vm/bootstrap.h', |
+ '--var_name', 'dart::Bootstrap::profiler_source_paths_', |
+ '--library_name', 'dart:profiler', |
+ '<@(_sources)', |
+ ], |
+ 'message': 'Generating ''<(profiler_cc_file)'' file.' |
+ }, |
+ ] |
+ }, |
+ { |
+ 'target_name': 'generate_profiler_patch_cc_file', |
+ 'type': 'none', |
+ 'toolsets':['host'], |
+ 'includes': [ |
+ # Load the runtime implementation sources. |
+ '../lib/profiler_sources.gypi', |
+ ], |
+ 'sources/': [ |
+ # Exclude all .[cc|h] files. |
+ # This is only here for reference. Excludes happen after |
+ # variable expansion, so the script has to do its own |
+ # exclude processing of the sources being passed. |
+ ['exclude', '\\.cc|h$'], |
+ ], |
+ 'actions': [ |
+ { |
+ 'action_name': 'generate_profiler_patch_cc', |
+ 'inputs': [ |
+ '../tools/gen_library_src_paths.py', |
+ '<(libgen_in_cc_file)', |
+ '<@(_sources)', |
+ ], |
+ 'outputs': [ |
+ '<(profiler_patch_cc_file)', |
+ ], |
+ 'action': [ |
+ 'python', |
+ 'tools/gen_library_src_paths.py', |
+ '--output', '<(profiler_patch_cc_file)', |
+ '--input_cc', '<(libgen_in_cc_file)', |
+ '--include', 'vm/bootstrap.h', |
+ '--var_name', 'dart::Bootstrap::profiler_patch_paths_', |
+ '--library_name', 'dart:profiler', |
+ '<@(_sources)', |
+ ], |
+ 'message': 'Generating ''<(profiler_patch_cc_file)'' file.' |
+ }, |
+ ] |
+ }, |
+ { |
'target_name': 'generate_snapshot_test_dat_file', |
'type': 'none', |
'toolsets':['host'], |