# Copyright (c) Huawei Technologies Co., Ltd. 2021. All rights reserved. # 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("//build/ohos.gni") import("../../base/config.gni") config("bytraceplugin_config") { include_dirs = [ "../api/include", "${OHOS_PROFILER_DIR}/interfaces/kits", "../../services/profiler_service/src", "../../base/include", "include", ] } ohos_shared_library("bytraceplugin") { output_name = "bytraceplugin" sources = [ "src/bytrace_module.cpp" ] public_configs = [ ":bytraceplugin_config", "${OHOS_PROFILER_DIR}/device/base:hiprofiler_test_config", ] public_deps = [ "${OHOS_PROFILER_DIR}/protos/types/plugins/bytrace_plugin:bytrace_plugin_protos_cpp" ] if (current_toolchain != host_toolchain) { defines = [ "HAVE_HILOG" ] external_deps = [ "bounds_checking_function:libsec_shared", "hilog:libhilog_base", "protobuf:protobuf_lite", ] } install_enable = false subsystem_name = "${OHOS_PROFILER_SUBSYS_NAME}" part_name = "${OHOS_PROFILER_PART_NAME}" } ohos_executable("test_bytrace_plugin") { output_name = "test_bytraceplugin" sources = [ "src/run_test.cpp" ] deps = [ ":bytraceplugin" ] install_enable = false subsystem_name = "${OHOS_PROFILER_SUBSYS_NAME}" part_name = "${OHOS_PROFILER_PART_NAME}" }