| OLD | NEW |
| 1 # Copyright 2017 The Chromium Authors. All rights reserved. | 1 # Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 import("//third_party/WebKit/Source/core/core.gni") | 5 import("//third_party/WebKit/Source/core/core.gni") |
| 6 | 6 |
| 7 blink_core_sources("probe") { | |
| 8 sources = [ | |
| 9 "CoreProbes.cpp", | |
| 10 "CoreProbes.h", | |
| 11 ] | |
| 12 } | |
| 13 | |
| 14 action("instrumentation_probes") { | 7 action("instrumentation_probes") { |
| 15 script = "../../build/scripts/make_instrumenting_probes.py" | 8 script = "../../build/scripts/make_instrumenting_probes.py" |
| 16 | 9 |
| 17 inputs = [ | 10 inputs = [ |
| 18 "CoreProbes.pidl", | 11 "CoreProbes.pidl", |
| 19 "CoreProbes.json5", | 12 "CoreProbes.json5", |
| 20 "../../build/scripts/templates/InstrumentingProbesImpl.cpp.tmpl", | 13 "../../build/scripts/templates/InstrumentingProbesImpl.cpp.tmpl", |
| 21 "../../build/scripts/templates/InstrumentingProbesInl.h.tmpl", | 14 "../../build/scripts/templates/InstrumentingProbesInl.h.tmpl", |
| 22 "../../build/scripts/templates/ProbeSink.h.tmpl", | 15 "../../build/scripts/templates/ProbeSink.h.tmpl", |
| 23 ] | 16 ] |
| 24 | 17 |
| 25 outputs = [ | 18 outputs = [ |
| 26 "$blink_core_output_dir/CoreProbesInl.h", | 19 "$blink_core_output_dir/CoreProbesInl.h", |
| 27 "$blink_core_output_dir/CoreProbesImpl.cpp", | 20 "$blink_core_output_dir/CoreProbesImpl.cpp", |
| 28 "$blink_core_output_dir/CoreProbeSink.h", | 21 "$blink_core_output_dir/CoreProbeSink.h", |
| 29 ] | 22 ] |
| 30 | 23 |
| 31 args = [ | 24 args = [ |
| 32 rebase_path(inputs[0], root_build_dir), | 25 rebase_path(inputs[0], root_build_dir), |
| 33 "--config", | 26 "--config", |
| 34 rebase_path("CoreProbes.json5", root_build_dir), | 27 rebase_path("CoreProbes.json5", root_build_dir), |
| 35 "--output_dir", | 28 "--output_dir", |
| 36 rebase_path(blink_core_output_dir, root_build_dir), | 29 rebase_path(blink_core_output_dir, root_build_dir), |
| 37 ] | 30 ] |
| 38 } | 31 } |
| 39 | 32 |
| 33 source_set("generated") { |
| 34 deps = [ |
| 35 ":instrumentation_probes", |
| 36 ] |
| 37 } |
| 38 |
| 40 # Compiles the sources generated above. | 39 # Compiles the sources generated above. |
| 41 source_set("generated") { | 40 blink_core_sources("probe") { |
| 42 sources = get_target_outputs(":instrumentation_probes") | 41 sources = [ |
| 43 | 42 "CoreProbes.cpp", |
| 44 configs -= core_config_remove | 43 "CoreProbes.h", |
| 45 configs += | 44 ] |
| 46 core_config_add + [ "//third_party/WebKit/Source/core:core_include_dirs" ] | 45 sources += get_target_outputs(":instrumentation_probes") |
| 47 | |
| 48 if (is_win) { | |
| 49 cflags = [ "/wd4702" ] # Unreachable code. | |
| 50 } | |
| 51 | 46 |
| 52 deps = [ | 47 deps = [ |
| 53 ":instrumentation_probes", | 48 ":instrumentation_probes", |
| 54 "//skia", | 49 "//skia", |
| 50 "//third_party/WebKit/Source/bindings/core/v8:bindings_core_v8_generated", |
| 51 "//third_party/WebKit/Source/core:all_generators", |
| 52 "//third_party/WebKit/Source/platform:make_platform_generated", |
| 55 "//third_party/WebKit/Source/platform/wtf", | 53 "//third_party/WebKit/Source/platform/wtf", |
| 56 "//v8", | 54 "//v8", |
| 57 ] | 55 ] |
| 58 } | 56 } |
| OLD | NEW |