blob: 4026e042060d236e28fe21c91ad1adb303389977 [file] [log] [blame]
Primiano Tucci3b729102018-01-08 18:16:36 +00001# Copyright (C) 2018 The Android Open Source Project
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14
Hector Dearman86cfbe12018-03-22 11:58:42 +000015import("../../gn/perfetto.gni")
16import("../../gn/proto_library.gni")
17
Primiano Tucci3b729102018-01-08 18:16:36 +000018source_set("perfetto_cmd") {
19 public_deps = [
Hector Dearman86cfbe12018-03-22 11:58:42 +000020 ":protos",
Hector Dearmanc443a362018-02-28 16:03:56 +000021 "../../include/perfetto/traced",
Primiano Tucci3b729102018-01-08 18:16:36 +000022 ]
23 deps = [
Hector Dearmanc443a362018-02-28 16:03:56 +000024 "../../gn:default_deps",
25 "../../protos/perfetto/config",
26 "../base",
27 "../protozero",
28 "../tracing:ipc_consumer",
Primiano Tucci3b729102018-01-08 18:16:36 +000029 ]
30 sources = [
31 "perfetto_cmd.cc",
Hector Dearman86cfbe12018-03-22 11:58:42 +000032 "perfetto_cmd.h",
33 "rate_limiter.cc",
34 "rate_limiter.h",
35 ]
36}
37
38proto_library("protos") {
39 generate_python = false
40 deps = []
41 sources = [
42 "perfetto_cmd_state.proto",
43 ]
44 proto_in_dir = perfetto_root_path
45 proto_out_dir = perfetto_root_path
46}
47
48source_set("unittests") {
49 testonly = true
50 public_deps = []
51 deps = [
52 ":perfetto_cmd",
53 "../../gn:default_deps",
54 "../../gn:gtest_deps",
55 ]
56 sources = [
57 "rate_limiter_unittest.cc",
Primiano Tucci3b729102018-01-08 18:16:36 +000058 ]
59}