1# Copyright (c) 2021-2025 Huawei Device Co., Ltd. 2# Licensed under the Apache License, Version 2.0 (the "License"); 3# you may not use this file except in compliance with the License. 4# You may obtain a copy of the License at 5# 6# http://www.apache.org/licenses/LICENSE-2.0 7# 8# Unless required by applicable law or agreed to in writing, software 9# distributed under the License is distributed on an "AS IS" BASIS, 10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 11# See the License for the specific language governing permissions and 12# limitations under the License. 13 14# declare build args 15declare_args() { 16 plugin_so = false 17 plugin_target_platform = "hisi" 18 plugin_target_ram = "2G" 19 plugin_target_rom = "32G" 20 21 # enable for build with external config 22 build_with_config = false 23 config_path = "" 24} 25 26input_build_file = 27 rebase_path("//base/hiviewdfx/hiview/build/plugin_build.json") 28 29plugin_static_deps = [] 30plugin_ut_deps = [] 31plugin_mst_deps = [] 32plugin_config_json = read_file(input_build_file, "json") 33# must be the same as in plugin_build.json 34plugin_keys = [] 35 36foreach(plugin_key, plugin_keys) { 37 plugins_info = plugin_config_json.plugins 38 plugin_info = plugins_info[plugin_key] 39 plugin_name = plugin_info.name 40 plugin_path = plugin_info.path 41 42 plugin_source = "$plugin_path:$plugin_name" 43 plugin_ut_source = "$plugin_path:unittest" 44 plugin_mst_source = "$plugin_path:moduletest" 45 46 plugin_static_deps += [ plugin_source ] 47 plugin_ut_deps += [ plugin_ut_source ] 48 plugin_mst_deps += [ plugin_mst_source ] 49 50 plugins_info = {} 51 plugin_info = {} 52} 53