1# Copyright (C) 2017 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 15import("../../gn/perfetto_host_executable.gni") 16import("../../gn/test.gni") 17 18perfetto_host_executable("ftrace_proto_gen") { 19 testonly = true 20 sources = [ "main.cc" ] 21 deps = [ 22 ":lib", 23 "../../gn:default_deps", 24 "../../gn:protobuf_full", 25 "../../src/base", 26 "../../src/traced/probes/ftrace/format_parser", 27 ] 28} 29 30perfetto_unittest_source_set("unittests") { 31 testonly = true 32 deps = [ 33 ":lib", 34 "../../gn:default_deps", 35 "../../gn:gtest_and_gmock", 36 "../../gn:protobuf_full", 37 ] 38 sources = [ "ftrace_proto_gen_unittest.cc" ] 39} 40 41source_set("lib") { 42 testonly = true 43 sources = [ 44 "ftrace_descriptor_gen.cc", 45 "ftrace_descriptor_gen.h", 46 "ftrace_proto_gen.cc", 47 "ftrace_proto_gen.h", 48 "proto_gen_utils.cc", 49 "proto_gen_utils.h", 50 ] 51 deps = [ 52 "../../gn:default_deps", 53 "../../gn:protobuf_full", 54 "../../src/base", 55 "../../src/traced/probes/ftrace/format_parser", 56 ] 57} 58