blob: 346c17fb0677d085f92deee1271532e42a743c60 [file] [log] [blame]
# Copyright (C) 2023 The Android Open Source Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import("../../gn/perfetto.gni")
import("../../gn/perfetto_component.gni")
import("../../gn/test.gni")
executable("traced_relay") {
deps = [
":lib",
"../../gn:default_deps",
"../../include/perfetto/ext/traced",
"../base",
"../base:clock_snapshots",
"../base:unix_socket",
"../base:version",
"../ipc:perfetto_ipc",
"../tracing/ipc:default_socket",
]
sources = [ "relay_service_main.cc" ]
}
source_set("lib") {
public_deps = [ "../../include/perfetto/ext/tracing/ipc" ]
sources = [
"relay_service.cc",
"relay_service.h",
"socket_relay_handler.cc",
"socket_relay_handler.h",
]
deps = [
"../../gn:default_deps",
"../../protos/perfetto/ipc",
"../../protos/perfetto/ipc:wire_protocol_cpp",
"../base",
"../ipc:perfetto_ipc",
"../tracing/ipc/producer:relay", # For relay_ipc_client.h
]
}
perfetto_unittest_source_set("unittests") {
testonly = true
deps = [
":lib",
"../../gn:default_deps",
"../../gn:gtest_and_gmock",
"../base",
"../base:test_support",
"../base/threading",
"../ipc:perfetto_ipc",
]
sources = [
"relay_service_unittest.cc",
"socket_relay_handler_unittest.cc",
]
}
source_set("integrationtests") {
testonly = true
deps = [
":lib",
"../../gn:default_deps",
"../../gn:gtest_and_gmock",
"../../test:test_helper",
"../base",
"../base:test_support",
]
sources = [ "relay_service_integrationtest.cc" ]
}