1# Copyright (c) 2021 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 14import("//build/test.gni") 15import("//foundation/aafwk/standard/aafwk.gni") 16 17config("ability_command_config") { 18 include_dirs = [ 19 "include", 20 "//foundation/distributedschedule/dmsfwk/services/dtbschedmgr/include", 21 "//utils/system/safwk/native/include", 22 "//third_party/jsoncpp/include", 23 ] 24} 25 26ohos_source_set("tools_aa_source_set") { 27 sources = [ 28 "src/ability_command.cpp", 29 "src/shell_command.cpp", 30 ] 31 32 public_configs = [ 33 ":ability_command_config", 34 "${services_path}/abilitymgr:abilityms_config", 35 "${services_path}/common:common_config", 36 ] 37 38 cflags = [] 39 if (target_cpu == "arm") { 40 cflags += [ "-DBINDER_IPC_32BIT" ] 41 } 42 43 deps = [ 44 "${aafwk_path}/interfaces/innerkits/ability_manager:ability_manager", 45 "${appexecfwk_path}/interfaces/innerkits/appexecfwk_base:appexecfwk_base", 46 "${appexecfwk_path}/interfaces/innerkits/appexecfwk_core:appexecfwk_core", 47 "${appexecfwk_path}/interfaces/innerkits/libeventhandler:libeventhandler", 48 "${innerkits_path}/want:want", 49 "${services_path}/abilitymgr:abilityms", 50 "//foundation/distributedschedule/samgr/interfaces/innerkits/samgr_proxy:samgr_proxy", 51 "//utils/native/base:utils", 52 ] 53 54 external_deps = [ 55 "hiviewdfx_hilog_native:libhilog", 56 "ipc:ipc_core", 57 ] 58} 59 60ohos_executable("aa") { 61 sources = [ "src/main.cpp" ] 62 63 cflags = [] 64 if (target_cpu == "arm") { 65 cflags += [ "-DBINDER_IPC_32BIT" ] 66 } 67 68 deps = [ 69 ":tools_aa_source_set", 70 "${appexecfwk_path}/interfaces/innerkits/appexecfwk_base:appexecfwk_base", 71 "${innerkits_path}/want:want", 72 "//utils/native/base:utils", 73 ] 74 75 external_deps = [ 76 "hiviewdfx_hilog_native:libhilog", 77 "ipc:ipc_core", 78 ] 79 80 install_enable = true 81 82 subsystem_name = "aafwk" 83 part_name = "aafwk_standard" 84} 85 86group("tools_aa") { 87 deps = [ ":aa" ] 88} 89