From d88bc4760822fa91abfe4a164d5692fc17d1c4fd Mon Sep 17 00:00:00 2001 From: litiangang4 Date: Mon, 24 Apr 2023 18:07:30 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=86=E5=B8=83=E5=BC=8F=E8=BE=93=E5=85=A5gn?= =?UTF-8?q?=E9=83=A8=E4=BB=B6=E5=8C=96=E6=95=B4=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: litiangang4 --- .../include/test/whitelistunittest/BUILD.gn | 21 ++++--- dfx_utils/BUILD.gn | 10 ++- dfx_utils/test/dfxtest/BUILD.gn | 13 ++-- inputdevicehandler/BUILD.gn | 13 ++-- .../test/inputhandlertest/BUILD.gn | 20 +++--- interfaces/inner_kits/BUILD.gn | 20 +++--- interfaces/inner_kits/test/unittest/BUILD.gn | 20 +++--- .../BUILD.gn | 18 +++--- interfaces/ipc/test/clientunittest/BUILD.gn | 40 +++++------- .../BUILD.gn | 14 ++--- .../dinputsourcecallbackunittest/BUILD.gn | 30 +++++---- interfaces/ipc/test/ipcunittest/BUILD.gn | 20 +++--- .../unpreparedinputcallbackunittest/BUILD.gn | 14 ++--- .../unregisterdinputcallbackunittest/BUILD.gn | 14 ++--- services/sink/inputcollector/BUILD.gn | 16 +++-- .../test/sinkcollectorunittest/BUILD.gn | 25 ++++---- services/sink/sinkmanager/BUILD.gn | 27 +++----- .../test/sinkmanagerunittest/BUILD.gn | 54 ++++++---------- services/sink/transport/BUILD.gn | 21 +++---- .../transport/test/sinktransunittest/BUILD.gn | 47 ++++++-------- services/source/inputinject/BUILD.gn | 13 ++-- .../test/sourceinjectunittest/BUILD.gn | 36 +++++------ services/source/sourcemanager/BUILD.gn | 42 ++++++------- .../test/sourcemanagerunittest/BUILD.gn | 63 +++++++++---------- services/source/transport/BUILD.gn | 16 ++--- .../distributed_input_source_transport.cpp | 4 +- .../test/sourcetransunittest/BUILD.gn | 25 ++++---- services/transportbase/BUILD.gn | 27 +++----- .../test/transbaseunittest/BUILD.gn | 30 ++++----- sinkhandler/BUILD.gn | 11 ++-- sinkhandler/test/unittest/BUILD.gn | 15 +++-- sourcehandler/BUILD.gn | 12 ++-- sourcehandler/test/unittest/BUILD.gn | 16 +++-- .../distributedinputclient_fuzzer/BUILD.gn | 15 ++--- .../distributedinputkit_fuzzer/BUILD.gn | 11 ++-- .../BUILD.gn | 26 ++++---- .../BUILD.gn | 25 +++----- .../BUILD.gn | 25 +++----- utils/BUILD.gn | 11 ++-- utils/test/unittest/BUILD.gn | 18 +++--- 40 files changed, 371 insertions(+), 527 deletions(-) diff --git a/common/include/test/whitelistunittest/BUILD.gn b/common/include/test/whitelistunittest/BUILD.gn index f0ac725..e7544bf 100755 --- a/common/include/test/whitelistunittest/BUILD.gn +++ b/common/include/test/whitelistunittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/white_list_test" group("whitelistunittest") { @@ -28,13 +29,9 @@ ohos_unittest("distributed_input_white_list_test") { include_dirs = [ "${innerkits_path}/include", - "${innerkits_path}/src", "${ipc_path}/include", - "${ipc_path}/src", - "//foundation/distributedhardware/distributed_input/services/sink/transport/include", - "//foundation/distributedhardware/distributed_input/frameworks/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", + "${services_sink_path}/transport/include", + "${frameworks_path}/include", "${common_path}/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", @@ -42,10 +39,7 @@ ohos_unittest("distributed_input_white_list_test") { "${fwk_utils_path}/include", "${service_common}/include", "//third_party/json/include", - "//foundation/communication/dsoftbus/interfaces/kits/transport", "${utils_path}/include", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//base/notification/eventhandler/interfaces/inner_api", ] sources = [ @@ -72,6 +66,13 @@ ohos_unittest("distributed_input_white_list_test") { "${utils_path}:libdinput_utils", ] + external_deps = [ + "c_utils:utils", + "dsoftbus:softbus_client", + "eventhandler:libeventhandler", + "ipc:ipc_core", + ] + cflags_cc = [ "-DHILOG_ENABLE" ] } ## UnitTest distributed_input_manager_service_test }}} diff --git a/dfx_utils/BUILD.gn b/dfx_utils/BUILD.gn index 8e563ac..bb20e18 100755 --- a/dfx_utils/BUILD.gn +++ b/dfx_utils/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -19,8 +19,6 @@ ohos_shared_library("libdinput_dfx_utils") { include_dirs = [ "include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_utils_path}/include/log", @@ -29,9 +27,6 @@ ohos_shared_library("libdinput_dfx_utils") { "${dfx_utils_path}/include", "${service_common}/include", "${utils_path}/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", ] sources = [ @@ -55,6 +50,9 @@ ohos_shared_library("libdinput_dfx_utils") { "c_utils:utils", "hisysevent_native:libhisysevent", "hiviewdfx_hilog_native:libhilog", + "ipc:ipc_core", + "safwk:system_ability_fwk", + "samgr:samgr_proxy", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/dfx_utils/test/dfxtest/BUILD.gn b/dfx_utils/test/dfxtest/BUILD.gn index 2d4416e..f35b58f 100644 --- a/dfx_utils/test/dfxtest/BUILD.gn +++ b/dfx_utils/test/dfxtest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/dfx_utils" group("dfxtest") { @@ -29,8 +30,6 @@ ohos_unittest("distributed_input_dfx_test") { include_dirs = [ "include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_utils_path}/include/log", @@ -39,15 +38,12 @@ ohos_unittest("distributed_input_dfx_test") { "${dfx_utils_path}/include", "${service_common}/include", "${utils_path}/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", ] sources = [ - "${utils_path}/src/dinput_log.cpp", "${dfx_utils_path}/src/hidumper.cpp", "${dfx_utils_path}/src/hisysevent_util.cpp", + "${utils_path}/src/dinput_log.cpp", "distributed_input_dfx_test.cpp", ] @@ -74,6 +70,9 @@ ohos_unittest("distributed_input_dfx_test") { "c_utils:utils", "hisysevent_native:libhisysevent", "hiviewdfx_hilog_native:libhilog", + "ipc:ipc_core", + "safwk:system_ability_fwk", + "samgr:samgr_proxy", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/inputdevicehandler/BUILD.gn b/inputdevicehandler/BUILD.gn index a6e789f..16150c8 100755 --- a/inputdevicehandler/BUILD.gn +++ b/inputdevicehandler/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -19,8 +19,6 @@ ohos_shared_library("libdinput_handler") { include_dirs = [ "include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_utils_path}/include/log", @@ -29,12 +27,8 @@ ohos_shared_library("libdinput_handler") { "${frameworks_path}/include", "${utils_path}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", ] sources = [ @@ -51,13 +45,16 @@ ohos_shared_library("libdinput_handler") { deps = [ "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", - "//third_party/openssl:libcrypto_static", "//third_party/libevdev:libevdev", + "//third_party/openssl:libcrypto_static", ] external_deps = [ "c_utils:utils", "dsoftbus:softbus_client", + "ipc:ipc_core", + "safwk:system_ability_fwk", + "samgr:samgr_proxy", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/inputdevicehandler/test/inputhandlertest/BUILD.gn b/inputdevicehandler/test/inputhandlertest/BUILD.gn index 466ceee..7fd3245 100644 --- a/inputdevicehandler/test/inputhandlertest/BUILD.gn +++ b/inputdevicehandler/test/inputhandlertest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/input_handler" group("inputhandlertest") { @@ -28,8 +29,6 @@ ohos_unittest("distributed_input_handler_test") { include_dirs = [ "${common_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_utils_path}/include/log", @@ -38,18 +37,14 @@ ohos_unittest("distributed_input_handler_test") { "${frameworks_path}/include", "${utils_path}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", - "//foundation/distributedhardware/distributed_input/inputdevicehandler/include", + "${distributedinput_path}/inputdevicehandler/include", ] sources = [ "${common_path}/include/input_hub.cpp", - "//foundation/distributedhardware/distributed_input/inputdevicehandler/src/distributed_input_handler.cpp", + "${distributedinput_path}/inputdevicehandler/src/distributed_input_handler.cpp", "distributed_input_handler_test.cpp", ] @@ -70,15 +65,18 @@ ohos_unittest("distributed_input_handler_test") { deps = [ "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", - "//third_party/openssl:libcrypto_static", "//third_party/libevdev:libevdev", + "//third_party/openssl:libcrypto_static", ] external_deps = [ "c_utils:utils", "dsoftbus:softbus_client", + "ipc:ipc_core", + "safwk:system_ability_fwk", + "samgr:samgr_proxy", ] cflags_cc = [ "-DHILOG_ENABLE" ] } -## UnitTest distributed_input_handler_test }}} \ No newline at end of file +## UnitTest distributed_input_handler_test }}} diff --git a/interfaces/inner_kits/BUILD.gn b/interfaces/inner_kits/BUILD.gn index 4358fe0..2296f30 100644 --- a/interfaces/inner_kits/BUILD.gn +++ b/interfaces/inner_kits/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -30,34 +30,28 @@ config("input_sdk_public_config") { "${ipc_path}/include", "${ipc_path}/src", "${utils_path}/include", - "//commonlibrary/c_utils/base/include", "//third_party/json/include", - "//utils/system/safwk/native/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/dsoftbus/interfaces/kits/bus_center", - "//foundation/communication/dsoftbus/interfaces/kits/common", - "//third_party/libevdev/libevdev/" ] } ohos_shared_library("libdinput_sdk") { - public_configs = [":input_sdk_public_config"] + public_configs = [ ":input_sdk_public_config" ] sources = [ - "${common_path}/include/white_list_util.cpp", "${common_path}/include/input_check_param.cpp", + "${common_path}/include/white_list_util.cpp", "${innerkits_path}/src/distributed_input_kit.cpp", "${ipc_path}/src/add_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/add_white_list_infos_call_back_stub.cpp", "${ipc_path}/src/del_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/del_white_list_infos_call_back_stub.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/dinput_sa_manager.cpp", "${ipc_path}/src/distributed_input_client.cpp", "${ipc_path}/src/distributed_input_sink_proxy.cpp", "${ipc_path}/src/distributed_input_sink_stub.cpp", "${ipc_path}/src/distributed_input_source_proxy.cpp", "${ipc_path}/src/distributed_input_source_stub.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/input_node_listener_proxy.cpp", "${ipc_path}/src/input_node_listener_stub.cpp", "${ipc_path}/src/prepare_d_input_call_back_proxy.cpp", @@ -83,7 +77,6 @@ ohos_shared_library("libdinput_sdk") { ] deps = [ - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", "//third_party/libevdev:libevdev", @@ -97,7 +90,10 @@ ohos_shared_library("libdinput_sdk") { external_deps = [ "c_utils:utils", + "dsoftbus:softbus_client", + "eventhandler:libeventhandler", "ipc:ipc_core", + "safwk:system_ability_fwk", "samgr:samgr_proxy", ] diff --git a/interfaces/inner_kits/test/unittest/BUILD.gn b/interfaces/inner_kits/test/unittest/BUILD.gn index a0bc825..49aacc0 100644 --- a/interfaces/inner_kits/test/unittest/BUILD.gn +++ b/interfaces/inner_kits/test/unittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/inner_kits" group("unittest") { @@ -31,11 +32,8 @@ ohos_unittest("distributed_input_inner_test") { "${innerkits_path}/src", "${ipc_path}/include", "${ipc_path}/src", - "//foundation/distributedhardware/distributed_input/services/include", - "//foundation/distributedhardware/distributed_input/services/src", - "//foundation/distributedhardware/distributed_input/frameworks/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", + "${distributedinput_path}/services/include", + "${frameworks_path}/include", "${common_path}/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", @@ -46,29 +44,29 @@ ohos_unittest("distributed_input_inner_test") { "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", "${frameworks_path}/include", - "//base/notification/eventhandler/interfaces/inner_api", ] sources = [ "${common_path}/include/white_list_util.cpp", "${innerkits_path}/src/distributed_input_kit.cpp", + "${innerkits_path}/test/unittest/mock/mock_distributed_input_client.cpp", "${ipc_path}/src/add_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/add_white_list_infos_call_back_stub.cpp", "${ipc_path}/src/del_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/del_white_list_infos_call_back_stub.cpp", + "${ipc_path}/src/distributed_input_source_proxy.cpp", "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", - "${ipc_path}/src/distributed_input_source_proxy.cpp", "${ipc_path}/src/input_node_listener_proxy.cpp", "${ipc_path}/src/input_node_listener_stub.cpp", "${ipc_path}/src/prepare_d_input_call_back_proxy.cpp", "${ipc_path}/src/prepare_d_input_call_back_stub.cpp", + "${ipc_path}/src/register_d_input_call_back_proxy.cpp", + "${ipc_path}/src/register_d_input_call_back_stub.cpp", "${ipc_path}/src/sharing_dhid_listener_proxy.cpp", "${ipc_path}/src/sharing_dhid_listener_stub.cpp", "${ipc_path}/src/simulation_event_listener_proxy.cpp", "${ipc_path}/src/simulation_event_listener_stub.cpp", - "${ipc_path}/src/register_d_input_call_back_proxy.cpp", - "${ipc_path}/src/register_d_input_call_back_stub.cpp", "${ipc_path}/src/start_d_input_call_back_proxy.cpp", "${ipc_path}/src/start_d_input_call_back_stub.cpp", "${ipc_path}/src/start_stop_d_inputs_call_back_proxy.cpp", @@ -81,7 +79,6 @@ ohos_unittest("distributed_input_inner_test") { "${ipc_path}/src/unprepare_d_input_call_back_stub.cpp", "${ipc_path}/src/unregister_d_input_call_back_proxy.cpp", "${ipc_path}/src/unregister_d_input_call_back_stub.cpp", - "//foundation/distributedhardware/distributed_input/interfaces/inner_kits/test/unittest/mock/mock_distributed_input_client.cpp", "distributed_input_inner_test.cpp", ] @@ -106,6 +103,7 @@ ohos_unittest("distributed_input_inner_test") { external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", "ipc:ipc_core", ] diff --git a/interfaces/ipc/test/addwhitelistinfoscallbackunittest/BUILD.gn b/interfaces/ipc/test/addwhitelistinfoscallbackunittest/BUILD.gn index 1cc25d6..67a144f 100644 --- a/interfaces/ipc/test/addwhitelistinfoscallbackunittest/BUILD.gn +++ b/interfaces/ipc/test/addwhitelistinfoscallbackunittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/ipc" group("addwhitelistinfoscallbackunittest") { @@ -40,24 +41,18 @@ ohos_unittest("add_white_list_infos_callbackl_test") { "${ipc_path}/include", "${ipc_path}/src", "${utils_path}/include", - "//commonlibrary/c_utils/base/include", "//third_party/json/include", - "//utils/system/safwk/native/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/dsoftbus/interfaces/kits/bus_center", - "//foundation/communication/dsoftbus/interfaces/kits/common", ] sources = [ - "add_white_list_infos_call_back_test.cpp", "${ipc_path}/src/add_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/add_white_list_infos_call_back_stub.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/distributed_input_sink_proxy.cpp", "${ipc_path}/src/distributed_input_sink_stub.cpp", "${ipc_path}/src/distributed_input_source_proxy.cpp", "${ipc_path}/src/distributed_input_source_stub.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/input_node_listener_proxy.cpp", "${ipc_path}/src/input_node_listener_stub.cpp", "${ipc_path}/src/prepare_d_input_call_back_proxy.cpp", @@ -76,6 +71,7 @@ ohos_unittest("add_white_list_infos_callbackl_test") { "${ipc_path}/src/start_stop_result_call_back_stub.cpp", "${ipc_path}/src/stop_d_input_call_back_proxy.cpp", "${ipc_path}/src/stop_d_input_call_back_stub.cpp", + "add_white_list_infos_call_back_test.cpp", ] cflags = [ @@ -97,12 +93,14 @@ ohos_unittest("add_white_list_infos_callbackl_test") { "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", ] external_deps = [ "c_utils:utils", + "dsoftbus:softbus_client", + "eventhandler:libeventhandler", "ipc:ipc_core", + "safwk:system_ability_fwk", "samgr:samgr_proxy", ] diff --git a/interfaces/ipc/test/clientunittest/BUILD.gn b/interfaces/ipc/test/clientunittest/BUILD.gn index 504c75f..51fec9f 100644 --- a/interfaces/ipc/test/clientunittest/BUILD.gn +++ b/interfaces/ipc/test/clientunittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/ipc" group("clientunittest") { @@ -40,13 +41,7 @@ ohos_unittest("distributed_input_client_test") { "${ipc_path}/include", "${ipc_path}/src", "${utils_path}/include", - "//commonlibrary/c_utils/base/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", - "//utils/system/safwk/native/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/dsoftbus/interfaces/kits/bus_center", - "//foundation/communication/dsoftbus/interfaces/kits/common", "${services_source_path}/sourcemanager/include", "${services_source_path}/inputinject/include", "${services_source_path}/transport/include", @@ -54,33 +49,23 @@ ohos_unittest("distributed_input_client_test") { "${services_sink_path}/transport/include", "${services_sink_path}/inputcollector/include", "${services_sink_path}/sinkmanager/include", - "//foundation/window/window_manager/interfaces/innerkits/dm", - "//foundation/window/window_manager/utils/include/", - "//foundation/graphic/graphic_2d/rosen/modules/render_service_base/include", - "//foundation/graphic/graphic_2d/interfaces/inner_api/surface", - "//foundation/graphic/graphic_2d/interfaces/inner_api/common", - "//drivers/peripheral/display/interfaces/include", - "//drivers/peripheral/base", - "//foundation/graphic/graphic_2d/utils/buffer_handle/export", "${distributedinput_path}/inputdevicehandler/include", ] sources = [ - "distributed_input_client_test.cpp", - "mock_samanager.cpp", - "${common_path}/include/white_list_util.cpp", "${common_path}/include/input_check_param.cpp", + "${common_path}/include/white_list_util.cpp", "${ipc_path}/src/add_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/add_white_list_infos_call_back_stub.cpp", "${ipc_path}/src/del_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/del_white_list_infos_call_back_stub.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/distributed_input_client.cpp", "${ipc_path}/src/distributed_input_sink_proxy.cpp", "${ipc_path}/src/distributed_input_sink_stub.cpp", "${ipc_path}/src/distributed_input_source_proxy.cpp", "${ipc_path}/src/distributed_input_source_stub.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/input_node_listener_proxy.cpp", "${ipc_path}/src/input_node_listener_stub.cpp", "${ipc_path}/src/prepare_d_input_call_back_proxy.cpp", @@ -103,6 +88,8 @@ ohos_unittest("distributed_input_client_test") { "${ipc_path}/src/unprepare_d_input_call_back_stub.cpp", "${ipc_path}/src/unregister_d_input_call_back_proxy.cpp", "${ipc_path}/src/unregister_d_input_call_back_stub.cpp", + "distributed_input_client_test.cpp", + "mock_samanager.cpp", ] cflags = [ @@ -123,19 +110,22 @@ ohos_unittest("distributed_input_client_test") { "${dfx_utils_path}:libdinput_dfx_utils", "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", + "${services_sink_path}/sinkmanager:libdinput_sink", + "${services_source_path}/inputinject:libdinput_inject", + "${services_source_path}/sourcemanager:libdinput_source", "${utils_path}:libdinput_utils", - "//foundation/distributedhardware/distributed_input/services/source/sourcemanager:libdinput_source", - "//foundation/distributedhardware/distributed_input/services/source/inputinject:libdinput_inject", - "//foundation/distributedhardware/distributed_input/services/sink/sinkmanager:libdinput_sink", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//foundation/window/window_manager/dm:libdm", "//third_party/libevdev:libevdev", ] external_deps = [ "c_utils:utils", + "dsoftbus:softbus_client", + "eventhandler:libeventhandler", + "graphic_standard:surface", "ipc:ipc_core", + "safwk:system_ability_fwk", "samgr:samgr_proxy", + "window_manager:libdm", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/interfaces/ipc/test/delwhitelistinfoscallbackunittest/BUILD.gn b/interfaces/ipc/test/delwhitelistinfoscallbackunittest/BUILD.gn index ed0fb0c..2c8d803 100644 --- a/interfaces/ipc/test/delwhitelistinfoscallbackunittest/BUILD.gn +++ b/interfaces/ipc/test/delwhitelistinfoscallbackunittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/ipc" group("delwhitelistinfoscallbackunittest") { @@ -40,18 +41,13 @@ ohos_unittest("del_white_list_infos_callbackl_test") { "${ipc_path}/include", "${ipc_path}/src", "${utils_path}/include", - "//commonlibrary/c_utils/base/include", "//third_party/json/include", - "//utils/system/safwk/native/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/dsoftbus/interfaces/kits/bus_center", - "//foundation/communication/dsoftbus/interfaces/kits/common", ] sources = [ - "del_white_list_infos_call_back_test.cpp", "${ipc_path}/src/del_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/del_white_list_infos_call_back_stub.cpp", + "del_white_list_infos_call_back_test.cpp", ] cflags = [ @@ -73,12 +69,14 @@ ohos_unittest("del_white_list_infos_callbackl_test") { "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", ] external_deps = [ "c_utils:utils", + "dsoftbus:softbus_client", + "eventhandler:libeventhandler", "ipc:ipc_core", + "safwk:system_ability_fwk", "samgr:samgr_proxy", ] diff --git a/interfaces/ipc/test/dinputsourcecallbackunittest/BUILD.gn b/interfaces/ipc/test/dinputsourcecallbackunittest/BUILD.gn index f04d38a..8c85b49 100644 --- a/interfaces/ipc/test/dinputsourcecallbackunittest/BUILD.gn +++ b/interfaces/ipc/test/dinputsourcecallbackunittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/ipc" group("dinputsourcecallbackunittest") { @@ -40,42 +41,37 @@ ohos_unittest("dinput_source_callback_test") { "${ipc_path}/include", "${ipc_path}/src", "${utils_path}/include", - "//commonlibrary/c_utils/base/include", "//third_party/json/include", - "//utils/system/safwk/native/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/dsoftbus/interfaces/kits/bus_center", - "//foundation/communication/dsoftbus/interfaces/kits/common", ] sources = [ - "dinput_source_callback_unittest.cpp", "${ipc_path}/src/add_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/add_white_list_infos_call_back_stub.cpp", "${ipc_path}/src/del_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/del_white_list_infos_call_back_stub.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/distributed_input_source_proxy.cpp", "${ipc_path}/src/distributed_input_source_stub.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", + "${ipc_path}/src/input_node_listener_proxy.cpp", + "${ipc_path}/src/input_node_listener_stub.cpp", "${ipc_path}/src/prepare_d_input_call_back_proxy.cpp", "${ipc_path}/src/prepare_d_input_call_back_stub.cpp", "${ipc_path}/src/register_d_input_call_back_proxy.cpp", "${ipc_path}/src/register_d_input_call_back_stub.cpp", + "${ipc_path}/src/simulation_event_listener_proxy.cpp", + "${ipc_path}/src/simulation_event_listener_stub.cpp", "${ipc_path}/src/start_d_input_call_back_proxy.cpp", "${ipc_path}/src/start_d_input_call_back_stub.cpp", + "${ipc_path}/src/start_stop_d_inputs_call_back_proxy.cpp", + "${ipc_path}/src/start_stop_d_inputs_call_back_stub.cpp", "${ipc_path}/src/stop_d_input_call_back_proxy.cpp", "${ipc_path}/src/stop_d_input_call_back_stub.cpp", "${ipc_path}/src/unprepare_d_input_call_back_proxy.cpp", "${ipc_path}/src/unprepare_d_input_call_back_stub.cpp", "${ipc_path}/src/unregister_d_input_call_back_proxy.cpp", "${ipc_path}/src/unregister_d_input_call_back_stub.cpp", - "${ipc_path}/src/start_stop_d_inputs_call_back_proxy.cpp", - "${ipc_path}/src/start_stop_d_inputs_call_back_stub.cpp", - "${ipc_path}/src/input_node_listener_proxy.cpp", - "${ipc_path}/src/input_node_listener_stub.cpp", - "${ipc_path}/src/simulation_event_listener_proxy.cpp", - "${ipc_path}/src/simulation_event_listener_stub.cpp", + "dinput_source_callback_unittest.cpp", ] cflags = [ @@ -97,12 +93,14 @@ ohos_unittest("dinput_source_callback_test") { "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", ] external_deps = [ "c_utils:utils", + "dsoftbus:softbus_client", + "eventhandler:libeventhandler", "ipc:ipc_core", + "safwk:system_ability_fwk", "samgr:samgr_proxy", ] diff --git a/interfaces/ipc/test/ipcunittest/BUILD.gn b/interfaces/ipc/test/ipcunittest/BUILD.gn index 53add0c..0908f88 100644 --- a/interfaces/ipc/test/ipcunittest/BUILD.gn +++ b/interfaces/ipc/test/ipcunittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/ipc" group("ipcunittest") { @@ -40,30 +41,24 @@ ohos_unittest("distributed_input_ipc_test") { "${ipc_path}/include", "${ipc_path}/src", "${utils_path}/include", - "//commonlibrary/c_utils/base/include", "//third_party/json/include", - "//utils/system/safwk/native/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/dsoftbus/interfaces/kits/bus_center", - "//foundation/communication/dsoftbus/interfaces/kits/common", ] sources = [ - "distributed_input_ipc_test.cpp", - "${common_path}/include/white_list_util.cpp", "${common_path}/include/input_check_param.cpp", + "${common_path}/include/white_list_util.cpp", "${ipc_path}/src/add_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/add_white_list_infos_call_back_stub.cpp", "${ipc_path}/src/del_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/del_white_list_infos_call_back_stub.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/dinput_sa_manager.cpp", "${ipc_path}/src/distributed_input_client.cpp", "${ipc_path}/src/distributed_input_sink_proxy.cpp", "${ipc_path}/src/distributed_input_sink_stub.cpp", "${ipc_path}/src/distributed_input_source_proxy.cpp", "${ipc_path}/src/distributed_input_source_stub.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/input_node_listener_proxy.cpp", "${ipc_path}/src/input_node_listener_stub.cpp", "${ipc_path}/src/prepare_d_input_call_back_proxy.cpp", @@ -86,6 +81,7 @@ ohos_unittest("distributed_input_ipc_test") { "${ipc_path}/src/unprepare_d_input_call_back_stub.cpp", "${ipc_path}/src/unregister_d_input_call_back_proxy.cpp", "${ipc_path}/src/unregister_d_input_call_back_stub.cpp", + "distributed_input_ipc_test.cpp", ] cflags = [ @@ -107,12 +103,14 @@ ohos_unittest("distributed_input_ipc_test") { "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", ] external_deps = [ "c_utils:utils", + "dsoftbus:softbus_client", + "eventhandler:libeventhandler", "ipc:ipc_core", + "safwk:system_ability_fwk", "samgr:samgr_proxy", ] diff --git a/interfaces/ipc/test/unpreparedinputcallbackunittest/BUILD.gn b/interfaces/ipc/test/unpreparedinputcallbackunittest/BUILD.gn index 2ffd50a..5bd9899 100644 --- a/interfaces/ipc/test/unpreparedinputcallbackunittest/BUILD.gn +++ b/interfaces/ipc/test/unpreparedinputcallbackunittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/ipc" group("unpreparedinputcallbackunittest") { @@ -40,18 +41,13 @@ ohos_unittest("unprepare_d_input_call_back_test") { "${ipc_path}/include", "${ipc_path}/src", "${utils_path}/include", - "//commonlibrary/c_utils/base/include", "//third_party/json/include", - "//utils/system/safwk/native/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/dsoftbus/interfaces/kits/bus_center", - "//foundation/communication/dsoftbus/interfaces/kits/common", ] sources = [ - "unprepare_d_input_call_back_test.cpp", "${ipc_path}/src/unprepare_d_input_call_back_proxy.cpp", "${ipc_path}/src/unprepare_d_input_call_back_stub.cpp", + "unprepare_d_input_call_back_test.cpp", ] cflags = [ @@ -73,12 +69,14 @@ ohos_unittest("unprepare_d_input_call_back_test") { "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", ] external_deps = [ "c_utils:utils", + "dsoftbus:softbus_client", + "eventhandler:libeventhandler", "ipc:ipc_core", + "safwk:system_ability_fwk", "samgr:samgr_proxy", ] diff --git a/interfaces/ipc/test/unregisterdinputcallbackunittest/BUILD.gn b/interfaces/ipc/test/unregisterdinputcallbackunittest/BUILD.gn index 8298f6d..287f8d8 100644 --- a/interfaces/ipc/test/unregisterdinputcallbackunittest/BUILD.gn +++ b/interfaces/ipc/test/unregisterdinputcallbackunittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/ipc" group("unregisterdinputcallbackunittest") { @@ -40,18 +41,13 @@ ohos_unittest("unregister_d_input_call_back_test") { "${ipc_path}/include", "${ipc_path}/src", "${utils_path}/include", - "//commonlibrary/c_utils/base/include", "//third_party/json/include", - "//utils/system/safwk/native/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/dsoftbus/interfaces/kits/bus_center", - "//foundation/communication/dsoftbus/interfaces/kits/common", ] sources = [ - "unregister_d_input_call_back_test.cpp", "${ipc_path}/src/unregister_d_input_call_back_proxy.cpp", "${ipc_path}/src/unregister_d_input_call_back_stub.cpp", + "unregister_d_input_call_back_test.cpp", ] cflags = [ @@ -73,12 +69,14 @@ ohos_unittest("unregister_d_input_call_back_test") { "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", ] external_deps = [ "c_utils:utils", + "dsoftbus:softbus_client", + "eventhandler:libeventhandler", "ipc:ipc_core", + "safwk:system_ability_fwk", "samgr:samgr_proxy", ] diff --git a/services/sink/inputcollector/BUILD.gn b/services/sink/inputcollector/BUILD.gn index 9af2f05..cc14b4b 100755 --- a/services/sink/inputcollector/BUILD.gn +++ b/services/sink/inputcollector/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -19,8 +19,6 @@ ohos_shared_library("libdinput_collector") { include_dirs = [ "include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${frameworks_path}/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", @@ -28,12 +26,8 @@ ohos_shared_library("libdinput_collector") { "${fwk_utils_path}/include", "${utils_path}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", ] sources = [ @@ -50,13 +44,17 @@ ohos_shared_library("libdinput_collector") { deps = [ "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//third_party/openssl:libcrypto_static", "//third_party/libevdev:libevdev", + "//third_party/openssl:libcrypto_static", + "//third_party/openssl:libcrypto_static", ] external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", + "ipc:ipc_core", + "safwk:system_ability_fwk", + "samgr:samgr_proxy", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/services/sink/inputcollector/test/sinkcollectorunittest/BUILD.gn b/services/sink/inputcollector/test/sinkcollectorunittest/BUILD.gn index e362355..ed77bd3 100644 --- a/services/sink/inputcollector/test/sinkcollectorunittest/BUILD.gn +++ b/services/sink/inputcollector/test/sinkcollectorunittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/sink_collector" group("sinkcollectorunittest") { @@ -27,9 +28,7 @@ ohos_unittest("distributed_input_inner_sinkcollector_test") { module_out_path = module_out_path include_dirs = [ - "$services_sink_path/inputcollector/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", + "${services_sink_path}/inputcollector/include", "${common_path}/include", "${frameworks_path}/include", "${fwk_common_path}/log/include", @@ -38,17 +37,13 @@ ohos_unittest("distributed_input_inner_sinkcollector_test") { "${fwk_utils_path}/include", "${utils_path}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", ] sources = [ "${common_path}/include/input_hub.cpp", - "//foundation/distributedhardware/distributed_input/services/sink/inputcollector/src/distributed_input_collector.cpp", + "${services_sink_path}/inputcollector/src/distributed_input_collector.cpp", "distributed_input_collector_test.cpp", ] @@ -67,18 +62,20 @@ ohos_unittest("distributed_input_inner_sinkcollector_test") { ] deps = [ - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//third_party/libevdev:libevdev", - "//third_party/openssl:libcrypto_static", "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", + "//third_party/libevdev:libevdev", + "//third_party/openssl:libcrypto_static", ] external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", + "ipc:ipc_core", + "safwk:system_ability_fwk", + "samgr:samgr_proxy", ] cflags_cc = [ "-DHILOG_ENABLE" ] } - -## UnitTest distributed_input_manager_service_test }}} \ No newline at end of file +## UnitTest distributed_input_manager_service_test }}} diff --git a/services/sink/sinkmanager/BUILD.gn b/services/sink/sinkmanager/BUILD.gn index c0ff445..d404e66 100644 --- a/services/sink/sinkmanager/BUILD.gn +++ b/services/sink/sinkmanager/BUILD.gn @@ -23,8 +23,6 @@ ohos_shared_library("libdinput_sink") { "${innerkits_path}/src", "${ipc_path}/include", "${ipc_path}/src", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${common_path}/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", @@ -38,17 +36,6 @@ ohos_shared_library("libdinput_sink") { "${utils_path}/include", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", - "//foundation/window/window_manager/interfaces/innerkits/dm", - "//foundation/window/window_manager/utils/include/", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", - "//base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent/include", - "//foundation/graphic/graphic_2d/rosen/modules/render_service_base/include", - "//foundation/graphic/graphic_2d/interfaces/inner_api/surface", - "//foundation/graphic/graphic_2d/interfaces/inner_api/common", - "//drivers/peripheral/display/interfaces/include", - "//drivers/peripheral/base", - "//foundation/graphic/graphic_2d/utils/buffer_handle/export", - "//third_party/libevdev/libevdev/" ] sources = [ @@ -66,22 +53,24 @@ ohos_shared_library("libdinput_sink") { deps = [ "${dfx_utils_path}:libdinput_dfx_utils", + "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", + "${innerkits_path}:libdinput_sdk", + "${services_sink_path}/inputcollector:libdinput_collector", + "${services_sink_path}/transport:libdinput_sink_trans", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//foundation/distributedhardware/distributed_input/interfaces/inner_kits:libdinput_sdk", - "//foundation/distributedhardware/distributed_input/services/sink/inputcollector:libdinput_collector", - "//foundation/distributedhardware/distributed_input/services/sink/transport:libdinput_sink_trans", - "${fwk_interfaces_path}:libdhfwk_sdk", - "//foundation/window/window_manager/dm:libdm", "//third_party/libevdev:libevdev", ] external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", + "graphic_standard:surface", + "hisysevent_native:libhisysevent", "ipc:ipc_core", "safwk:system_ability_fwk", "samgr:samgr_proxy", + "window_manager:libdm", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/services/sink/sinkmanager/test/sinkmanagerunittest/BUILD.gn b/services/sink/sinkmanager/test/sinkmanagerunittest/BUILD.gn index 2d745e2..e972941 100755 --- a/services/sink/sinkmanager/test/sinkmanagerunittest/BUILD.gn +++ b/services/sink/sinkmanager/test/sinkmanagerunittest/BUILD.gn @@ -33,11 +33,9 @@ ohos_unittest("distributed_input_sinkmanager_test") { "${ipc_path}/include", "${ipc_path}/src", "${distributedinput_path}/services/transportbase/include", - "${distributedinput_path}/services/sink/transport/include", - "${distributedinput_path}/services/sink/sinkmanager/include", - "${distributedinput_path}/frameworks/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", + "${services_sink_path}/transport/include", + "${services_sink_path}/sinkmanager/include", + "${frameworks_path}/include", "${common_path}/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", @@ -45,29 +43,13 @@ ohos_unittest("distributed_input_sinkmanager_test") { "${fwk_utils_path}/include", "${service_common}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", - "//foundation/communication/dsoftbus/interfaces/kits/transport", "${services_sink_path}/inputcollector/include", "${dfx_utils_path}/include", "${utils_path}/include", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", - "//foundation/window/window_manager/interfaces/innerkits/dm", - "//foundation/window/window_manager/utils/include/", - "//foundation/graphic/graphic_2d/rosen/modules/render_service_base/include", - "//foundation/graphic/graphic_2d/interfaces/inner_api/surface", - "//foundation/graphic/graphic_2d/interfaces/inner_api/common", - "//drivers/peripheral/display/interfaces/include", - "//drivers/peripheral/base", - "//foundation/graphic/graphic_2d/utils/buffer_handle/export", "${common_path}/test/mock", - "//base/security/access_token/interfaces/innerkits/accesstoken/include", - "//base/security/access_token/interfaces/innerkits/nativetoken/include", - "//base/security/access_token/interfaces/innerkits/token_setproc/include", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", - "${distributedinput_path}/services/sink/sinkmanager/test/sinkmanagerunittest/mock/", - "${services_source_path}/inputinject/include", - "${distributedinput_path}/inputdevicehandler/include", + "${services_sink_path}/sinkmanager/test/sinkmanagerunittest/mock/", ] sources = [ @@ -75,16 +57,15 @@ ohos_unittest("distributed_input_sinkmanager_test") { "${common_path}/include/white_list_util.cpp", "${common_path}/test/mock/session_mock.cpp", "${common_path}/test/mock/softbus_bus_center_mock.cpp", - "${distributedinput_path}/services/sink/sinkmanager/src/distributed_input_sink_event_handler.cpp", - "${distributedinput_path}/services/sink/sinkmanager/src/distributed_input_sink_manager.cpp", - "${distributedinput_path}/services/sink/sinkmanager/test/sinkmanagerunittest/mock/mock_process.cpp", - "${distributedinput_path}/services/sink/transport/src/distributed_input_sink_switch.cpp", - "${distributedinput_path}/services/sink/transport/src/distributed_input_sink_transport.cpp", - "${distributedinput_path}/services/transportbase/src/distributed_input_transport_base.cpp", "${ipc_path}/src/distributed_input_sink_stub.cpp", "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/sharing_dhid_listener_stub.cpp", "${services_sink_path}/inputcollector/src/distributed_input_collector.cpp", + "${services_sink_path}/sinkmanager/src/distributed_input_sink_event_handler.cpp", + "${services_sink_path}/sinkmanager/src/distributed_input_sink_manager.cpp", + "${services_sink_path}/sinkmanager/test/sinkmanagerunittest/mock/mock_process.cpp", + "${services_sink_path}/transport/src/distributed_input_sink_switch.cpp", + "${services_sink_path}/transport/src/distributed_input_sink_transport.cpp", "distributed_input_sinkmanager_test.cpp", ] @@ -100,30 +81,31 @@ ohos_unittest("distributed_input_sinkmanager_test") { "HI_LOG_ENABLE", "DH_LOG_TAG=\"distributedinpututtest\"", "LOG_DOMAIN=0xD004100", - "COMPILE_TEST_MODE", ] deps = [ "${dfx_utils_path}:libdinput_dfx_utils", - "${distributedinput_path}/services/sink/transport:libdinput_sink_trans", + "${distributedinput_path}/services/transportbase:libdinput_trans_base", "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", + "${services_sink_path}/transport:libdinput_sink_trans", "${utils_path}:libdinput_utils", - "${window_manager_path}/dm:libdm", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//base/security/access_token/interfaces/innerkits/accesstoken:libaccesstoken_sdk", - "//base/security/access_token/interfaces/innerkits/nativetoken:libnativetoken", - "//base/security/access_token/interfaces/innerkits/token_setproc:libtoken_setproc", "//third_party/libevdev:libevdev", "//third_party/openssl:libcrypto_static", ] external_deps = [ + "access_token:libaccesstoken_sdk", + "access_token:libnativetoken", + "access_token:libtoken_setproc", "c_utils:utils", - "hitrace_native:hitrace_meter", + "dsoftbus:softbus_client", + "eventhandler:libeventhandler", + "graphic_standard:surface", "ipc:ipc_core", "safwk:system_ability_fwk", "samgr:samgr_proxy", + "window_manager:libdm", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/services/sink/transport/BUILD.gn b/services/sink/transport/BUILD.gn index 9f929f6..a415258 100644 --- a/services/sink/transport/BUILD.gn +++ b/services/sink/transport/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -19,8 +19,6 @@ ohos_shared_library("libdinput_sink_trans") { include_dirs = [ "include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${frameworks_path}/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", @@ -33,12 +31,7 @@ ohos_shared_library("libdinput_sink_trans") { "${utils_path}/include", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", - "//third_party/libevdev/libevdev/", - "//foundation/distributedhardware/distributed_input/services/transportbase/include", - "//foundation/communication/dsoftbus/interfaces/kits/transport", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", + "${distributedinput_path}/services/transportbase/include", ] sources = [ @@ -54,19 +47,21 @@ ohos_shared_library("libdinput_sink_trans") { deps = [ "${dfx_utils_path}:libdinput_dfx_utils", + "${distributedinput_path}/services/transportbase:libdinput_trans_base", "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//foundation/communication/dsoftbus/sdk:softbus_client", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy:samgr_proxy", "//third_party/libevdev:libevdev", - "//foundation/distributedhardware/distributed_input/services/transportbase:libdinput_trans_base", ] external_deps = [ "c_utils:utils", + "dsoftbus:softbus_client", + "eventhandler:libeventhandler", "hitrace_native:hitrace_meter", + "ipc:ipc_core", + "safwk:system_ability_fwk", + "samgr:samgr_proxy", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/services/sink/transport/test/sinktransunittest/BUILD.gn b/services/sink/transport/test/sinktransunittest/BUILD.gn index 36d3edc..7508c6c 100755 --- a/services/sink/transport/test/sinktransunittest/BUILD.gn +++ b/services/sink/transport/test/sinktransunittest/BUILD.gn @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/sink_trans" group("sinktransunittest") { @@ -27,10 +28,8 @@ ohos_unittest("distributed_input_sinktrans_test") { module_out_path = module_out_path include_dirs = [ - "//foundation/distributedhardware/distributed_input/services/sink/transport/include", - "//foundation/distributedhardware/distributed_input/services/transportbase/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", + "${services_sink_path}/transport/include", + "${distributedinput_path}/services/transportbase/include", "${common_path}/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", @@ -40,40 +39,28 @@ ohos_unittest("distributed_input_sinktrans_test") { "${fwk_utils_path}/include", "${service_common}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", "${dfx_utils_path}/include", "${utils_path}/include", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", "${common_path}/test/mock", - "//foundation/distributedhardware/distributed_input/services/sink/sinkmanager/include", + "${services_sink_path}/sinkmanager/include", "${fwk_interfaces_path}/include/ipc", - "//foundation/window/window_manager/interfaces/innerkits/dm", - "//foundation/window/window_manager/utils/include/", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", - "//base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent/include", - "//foundation/graphic/graphic_2d/rosen/modules/render_service_base/include", - "//foundation/graphic/graphic_2d/interfaces/inner_api/surface", - "//foundation/graphic/graphic_2d/interfaces/inner_api/common", - "//drivers/peripheral/display/interfaces/include", - "//drivers/peripheral/base", - "//foundation/graphic/graphic_2d/utils/buffer_handle/export", "${innerkits_path}/include", "${innerkits_path}/src", "${ipc_path}/include", "${ipc_path}/src", "${services_sink_path}/inputcollector/include", "${services_source_path}/inputinject/include", - "//foundation/distributedhardware/distributed_input/inputdevicehandler/include", + "${distributedinput_path}/inputdevicehandler/include", ] sources = [ - "//foundation/distributedhardware/distributed_input/services/sink/transport/src/distributed_input_sink_switch.cpp", - "//foundation/distributedhardware/distributed_input/services/sink/transport/src/distributed_input_sink_transport.cpp", - "//foundation/distributedhardware/distributed_input/services/sink/sinkmanager/src/distributed_input_sink_manager.cpp", - "//foundation/distributedhardware/distributed_input/services/transportbase/src/distributed_input_transport_base.cpp", - "distributed_input_sinktrans_test.cpp", "${common_path}/test/mock/session_mock.cpp", "${common_path}/test/mock/softbus_bus_center_mock.cpp", + "${distributedinput_path}/services/transportbase/src/distributed_input_transport_base.cpp", + "${services_sink_path}/sinkmanager/src/distributed_input_sink_manager.cpp", + "${services_sink_path}/transport/src/distributed_input_sink_switch.cpp", + "${services_sink_path}/transport/src/distributed_input_sink_transport.cpp", + "distributed_input_sinktrans_test.cpp", ] cflags = [ @@ -88,27 +75,29 @@ ohos_unittest("distributed_input_sinktrans_test") { "HI_LOG_ENABLE", "DH_LOG_TAG=\"distributedinpututtest\"", "LOG_DOMAIN=0xD004100", - "COMPILE_TEST_MODE" + "COMPILE_TEST_MODE", ] deps = [ "${dfx_utils_path}:libdinput_dfx_utils", "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", - "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "${services_sink_path}/sinkmanager:libdinput_sink", "${services_sink_path}/inputcollector:libdinput_collector", - "//foundation/window/window_manager/dm:libdm", + "${services_sink_path}/sinkmanager:libdinput_sink", + "${utils_path}:libdinput_utils", "//third_party/libevdev:libevdev", ] external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", + "graphic_standard:surface", + "hisysevent_native:libhisysevent", + "hitrace_native:hitrace_meter", "ipc:ipc_core", "safwk:system_ability_fwk", - "hitrace_native:hitrace_meter", "samgr:samgr_proxy", + "window_manager:libdm", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/services/source/inputinject/BUILD.gn b/services/source/inputinject/BUILD.gn index 8872180..b874d45 100644 --- a/services/source/inputinject/BUILD.gn +++ b/services/source/inputinject/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -20,8 +20,6 @@ ohos_shared_library("libdinput_inject") { "include", "${common_path}/include", "${frameworks_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_utils_path}/include/log", @@ -33,10 +31,6 @@ ohos_shared_library("libdinput_inject") { "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", "${distributedinput_path}/inputdevicehandler/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", - "//third_party/libevdev/libevdev/" ] sources = [ @@ -56,13 +50,16 @@ ohos_shared_library("libdinput_inject") { "${dfx_utils_path}:libdinput_dfx_utils", "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", - "//third_party/openssl:libcrypto_static", "//third_party/libevdev:libevdev", + "//third_party/openssl:libcrypto_static", ] external_deps = [ "c_utils:utils", "dsoftbus:softbus_client", + "ipc:ipc_core", + "safwk:system_ability_fwk", + "samgr:samgr_proxy", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/services/source/inputinject/test/sourceinjectunittest/BUILD.gn b/services/source/inputinject/test/sourceinjectunittest/BUILD.gn index 7a3a097..5b20676 100755 --- a/services/source/inputinject/test/sourceinjectunittest/BUILD.gn +++ b/services/source/inputinject/test/sourceinjectunittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/source_inject" group("sourceinjectunittest") { @@ -28,13 +29,9 @@ ohos_unittest("distributed_input_inner_sourceinject_test") { include_dirs = [ "${innerkits_path}/include", - "${innerkits_path}/src", "${ipc_path}/include", - "${ipc_path}/src", - "//foundation/distributedhardware/distributed_input/services/source/inputinject/include", - "//foundation/distributedhardware/distributed_input/frameworks/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", + "${services_source_path}/inputinject/include", + "${frameworks_path}/include", "${common_path}/include", "${frameworks_path}/include", "${fwk_common_path}/log/include", @@ -43,28 +40,22 @@ ohos_unittest("distributed_input_inner_sourceinject_test") { "${fwk_utils_path}/include", "${service_common}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", - "//foundation/communication/dsoftbus/interfaces/kits/transport", "${dfx_utils_path}/include", "${utils_path}/include", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", "${distributedinput_path}/inputdevicehandler/include", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//base/notification/eventhandler/interfaces/inner_api", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", "${common_path}/test/mock", ] sources = [ "${common_path}/include/input_hub.cpp", - "//foundation/distributedhardware/distributed_input/inputdevicehandler/src/distributed_input_handler.cpp", - "//foundation/distributedhardware/distributed_input/services/source/inputinject/src/distributed_input_inject.cpp", - "//foundation/distributedhardware/distributed_input/services/source/inputinject/src/distributed_input_node_manager.cpp", - "//foundation/distributedhardware/distributed_input/services/source/inputinject/src/virtual_device.cpp", - "distributed_input_sourceinject_test.cpp", "${common_path}/test/mock/softbus_bus_center_mock.cpp", + "${distributedinput_path}/inputdevicehandler/src/distributed_input_handler.cpp", + "${services_source_path}/inputinject/src/distributed_input_inject.cpp", + "${services_source_path}/inputinject/src/distributed_input_node_manager.cpp", + "${services_source_path}/inputinject/src/virtual_device.cpp", + "distributed_input_sourceinject_test.cpp", ] cflags = [ @@ -84,16 +75,19 @@ ohos_unittest("distributed_input_inner_sourceinject_test") { deps = [ "${dfx_utils_path}:libdinput_dfx_utils", "${fwk_utils_path}:distributedhardwareutils", + "${innerkits_path}:libdinput_sdk", "${utils_path}:libdinput_utils", - "//third_party/openssl:libcrypto_static", "//third_party/libevdev:libevdev", - "${distributedinput_path}/interfaces/inner_kits:libdinput_sdk", + "//third_party/openssl:libcrypto_static", ] external_deps = [ "c_utils:utils", - "ipc:ipc_core", "dsoftbus:softbus_client", + "eventhandler:libeventhandler", + "ipc:ipc_core", + "safwk:system_ability_fwk", + "samgr:samgr_proxy", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/services/source/sourcemanager/BUILD.gn b/services/source/sourcemanager/BUILD.gn index f87f93b..0214051 100644 --- a/services/source/sourcemanager/BUILD.gn +++ b/services/source/sourcemanager/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -24,8 +24,6 @@ ohos_shared_library("libdinput_source") { "${innerkits_path}/src", "${ipc_path}/include", "${ipc_path}/src", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${common_path}/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", @@ -37,47 +35,42 @@ ohos_shared_library("libdinput_source") { "${dfx_utils_path}/include", "${utils_path}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", - "//base/hiviewdfx/hitrace/interfaces/native/innerkits/include/hitrace_meter", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", "${distributedinput_path}/inputdevicehandler/include", - "//base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent/include", - "//foundation/communication/dsoftbus/interfaces/kits/bus_center", - "//foundation/communication/dsoftbus/interfaces/kits/common", ] sources = [ - "${common_path}/include/white_list_util.cpp", "${common_path}/include/input_check_param.cpp", + "${common_path}/include/white_list_util.cpp", "${ipc_path}/src/add_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/add_white_list_infos_call_back_stub.cpp", "${ipc_path}/src/del_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/del_white_list_infos_call_back_stub.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/distributed_input_sink_proxy.cpp", "${ipc_path}/src/distributed_input_sink_stub.cpp", "${ipc_path}/src/distributed_input_source_proxy.cpp", "${ipc_path}/src/distributed_input_source_stub.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", + "${ipc_path}/src/input_node_listener_proxy.cpp", + "${ipc_path}/src/input_node_listener_stub.cpp", "${ipc_path}/src/prepare_d_input_call_back_proxy.cpp", "${ipc_path}/src/prepare_d_input_call_back_stub.cpp", "${ipc_path}/src/register_d_input_call_back_proxy.cpp", "${ipc_path}/src/register_d_input_call_back_stub.cpp", + "${ipc_path}/src/sharing_dhid_listener_proxy.cpp", + "${ipc_path}/src/sharing_dhid_listener_stub.cpp", + "${ipc_path}/src/simulation_event_listener_proxy.cpp", + "${ipc_path}/src/simulation_event_listener_stub.cpp", "${ipc_path}/src/start_d_input_call_back_proxy.cpp", "${ipc_path}/src/start_d_input_call_back_stub.cpp", - "${ipc_path}/src/stop_d_input_call_back_proxy.cpp", - "${ipc_path}/src/stop_d_input_call_back_stub.cpp", "${ipc_path}/src/start_stop_d_inputs_call_back_proxy.cpp", "${ipc_path}/src/start_stop_d_inputs_call_back_stub.cpp", "${ipc_path}/src/start_stop_result_call_back_proxy.cpp", "${ipc_path}/src/start_stop_result_call_back_stub.cpp", - "${ipc_path}/src/input_node_listener_proxy.cpp", - "${ipc_path}/src/input_node_listener_stub.cpp", - "${ipc_path}/src/sharing_dhid_listener_proxy.cpp", - "${ipc_path}/src/sharing_dhid_listener_stub.cpp", - "${ipc_path}/src/simulation_event_listener_proxy.cpp", - "${ipc_path}/src/simulation_event_listener_stub.cpp", + "${ipc_path}/src/stop_d_input_call_back_proxy.cpp", + "${ipc_path}/src/stop_d_input_call_back_stub.cpp", "${ipc_path}/src/unprepare_d_input_call_back_proxy.cpp", "${ipc_path}/src/unprepare_d_input_call_back_stub.cpp", "${ipc_path}/src/unregister_d_input_call_back_proxy.cpp", @@ -95,19 +88,20 @@ ohos_shared_library("libdinput_source") { deps = [ "${dfx_utils_path}:libdinput_dfx_utils", + "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", + "${innerkits_path}:libdinput_sdk", + "${services_source_path}/inputinject:libdinput_inject", + "${services_source_path}/transport:libdinput_source_trans", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//foundation/distributedhardware/distributed_input/interfaces/inner_kits:libdinput_sdk", - "//foundation/distributedhardware/distributed_input/services/source/inputinject:libdinput_inject", - "//foundation/distributedhardware/distributed_input/services/source/transport:libdinput_source_trans", - "${fwk_interfaces_path}:libdhfwk_sdk", "//third_party/libevdev:libevdev", ] external_deps = [ "c_utils:utils", + "dsoftbus:softbus_client", "eventhandler:libeventhandler", + "hisysevent_native:libhisysevent", "hitrace_native:hitrace_meter", "ipc:ipc_core", "safwk:system_ability_fwk", diff --git a/services/source/sourcemanager/test/sourcemanagerunittest/BUILD.gn b/services/source/sourcemanager/test/sourcemanagerunittest/BUILD.gn index 8ddc354..2317b58 100755 --- a/services/source/sourcemanager/test/sourcemanagerunittest/BUILD.gn +++ b/services/source/sourcemanager/test/sourcemanagerunittest/BUILD.gn @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/source_manager" group("sourcemanagerunittest") { @@ -32,11 +33,9 @@ ohos_unittest("distributed_input_sourcemanager_test") { "${innerkits_path}/src", "${ipc_path}/include", "${ipc_path}/src", - "//foundation/distributedhardware/distributed_input/services/source/sourcemanager/include", - "//foundation/distributedhardware/distributed_input/frameworks/include", - "//foundation/distributedhardware/distributed_input/inputdevicehandler/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", + "${services_source_path}/sourcemanager/include", + "${frameworks_path}/include", + "${distributedinput_path}/inputdevicehandler/include", "${common_path}/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", @@ -44,37 +43,35 @@ ohos_unittest("distributed_input_sourcemanager_test") { "${fwk_utils_path}/include", "${service_common}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", - "//foundation/communication/dsoftbus/interfaces/kits/transport", "//foundation/distributedhardware/device_manager/interfaces/inner_kits/native_cpp/include", "${services_source_path}/inputinject/include", "${services_source_path}/transport/include", "${dfx_utils_path}/include", - "//base/hiviewdfx/hitrace/interfaces/native/innerkits/include/hitrace_meter", "${utils_path}/include", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", - "//base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent/include", "${common_path}/test/mock", - "//base/security/access_token/interfaces/innerkits/accesstoken/include", - "//base/security/access_token/interfaces/innerkits/nativetoken/include", - "//base/security/access_token/interfaces/innerkits/token_setproc/include", - "//foundation/distributedhardware/distributed_input/services/transportbase/include", + "${distributedinput_path}/services/transportbase/include", "${distributedinput_path}/utils/include", ] sources = [ "${common_path}/include/input_hub.cpp", + "${common_path}/test/mock/session_mock.cpp", + "${common_path}/test/mock/softbus_bus_center_mock.cpp", + "${distributedinput_path}/services/transportbase/src/distributed_input_transport_base.cpp", + "${distributedinput_path}/utils/src/dinput_context.cpp", + "${distributedinput_path}/utils/src/dinput_utils_tool.cpp", "${ipc_path}/src/add_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/add_white_list_infos_call_back_stub.cpp", "${ipc_path}/src/del_white_list_infos_call_back_proxy.cpp", "${ipc_path}/src/del_white_list_infos_call_back_stub.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", - "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/distributed_input_sink_proxy.cpp", "${ipc_path}/src/distributed_input_sink_stub.cpp", "${ipc_path}/src/distributed_input_source_proxy.cpp", "${ipc_path}/src/distributed_input_source_stub.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", + "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", "${ipc_path}/src/prepare_d_input_call_back_proxy.cpp", "${ipc_path}/src/prepare_d_input_call_back_stub.cpp", "${ipc_path}/src/register_d_input_call_back_proxy.cpp", @@ -87,19 +84,14 @@ ohos_unittest("distributed_input_sourcemanager_test") { "${ipc_path}/src/unprepare_d_input_call_back_stub.cpp", "${ipc_path}/src/unregister_d_input_call_back_proxy.cpp", "${ipc_path}/src/unregister_d_input_call_back_stub.cpp", - "//foundation/distributedhardware/distributed_input/services/source/inputinject/src/distributed_input_inject.cpp", - "//foundation/distributedhardware/distributed_input/services/source/inputinject/src/distributed_input_node_manager.cpp", - "//foundation/distributedhardware/distributed_input/services/source/inputinject/src/virtual_device.cpp", - "//foundation/distributedhardware/distributed_input/services/source/sourcemanager/src/distributed_input_source_event_handler.cpp", - "//foundation/distributedhardware/distributed_input/services/source/sourcemanager/src/distributed_input_source_manager.cpp", - "//foundation/distributedhardware/distributed_input/services/source/sourcemanager/src/distributed_input_source_sa_cli_mgr.cpp", - "//foundation/distributedhardware/distributed_input/services/source/transport/src/distributed_input_source_transport.cpp", - "//foundation/distributedhardware/distributed_input/services/transportbase/src/distributed_input_transport_base.cpp", + "${services_source_path}/inputinject/src/distributed_input_inject.cpp", + "${services_source_path}/inputinject/src/distributed_input_node_manager.cpp", + "${services_source_path}/inputinject/src/virtual_device.cpp", + "${services_source_path}/sourcemanager/src/distributed_input_source_event_handler.cpp", + "${services_source_path}/sourcemanager/src/distributed_input_source_manager.cpp", + "${services_source_path}/sourcemanager/src/distributed_input_source_sa_cli_mgr.cpp", + "${services_source_path}/transport/src/distributed_input_source_transport.cpp", "distributed_input_sourcemanager_test.cpp", - "${common_path}/test/mock/session_mock.cpp", - "${common_path}/test/mock/softbus_bus_center_mock.cpp", - "${distributedinput_path}/utils/src/dinput_utils_tool.cpp", - "${distributedinput_path}/utils/src/dinput_context.cpp", ] cflags = [ @@ -114,25 +106,26 @@ ohos_unittest("distributed_input_sourcemanager_test") { "HI_LOG_ENABLE", "DH_LOG_TAG=\"distributedinpututtest\"", "LOG_DOMAIN=0xD004100", - "COMPILE_TEST_MODE" + "COMPILE_TEST_MODE", ] deps = [ "${dfx_utils_path}:libdinput_dfx_utils", + "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", + "${innerkits_path}:libdinput_sdk", + "${services_source_path}/transport:libdinput_source_trans", "//third_party/libevdev:libevdev", "//third_party/openssl:libcrypto_static", - "${fwk_interfaces_path}:libdhfwk_sdk", - "${innerkits_path}:libdinput_sdk", - "//foundation/distributedhardware/distributed_input/services/source/transport:libdinput_source_trans", - "//base/security/access_token/interfaces/innerkits/accesstoken:libaccesstoken_sdk", - "//base/security/access_token/interfaces/innerkits/nativetoken:libnativetoken", - "//base/security/access_token/interfaces/innerkits/token_setproc:libtoken_setproc", ] external_deps = [ + "access_token:libaccesstoken_sdk", + "access_token:libnativetoken", + "access_token:libtoken_setproc", "c_utils:utils", + "eventhandler:libeventhandler", + "hisysevent_native:libhisysevent", "hitrace_native:hitrace_meter", "ipc:ipc_core", "safwk:system_ability_fwk", diff --git a/services/source/transport/BUILD.gn b/services/source/transport/BUILD.gn index 9765c12..cedaf24 100755 --- a/services/source/transport/BUILD.gn +++ b/services/source/transport/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -19,8 +19,6 @@ ohos_shared_library("libdinput_source_trans") { include_dirs = [ "include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_interfaces_path}/include", @@ -30,14 +28,11 @@ ohos_shared_library("libdinput_source_trans") { "${service_common}/include", "//foundation/distributedhardware/device_manager/interfaces/inner_kits/native_cpp/include", "${services_source_path}/inputinject/include", - "//base/hiviewdfx/hitrace/interfaces/native/innerkits/include/hitrace_meter", "${dfx_utils_path}/include", "${utils_path}/include", "${frameworks_path}/include", "${distributedinput_path}/inputdevicehandler/include", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", - "//third_party/libevdev/libevdev/", - "//foundation/distributedhardware/distributed_input/services/transportbase/include", + "${distributedinput_path}/services/transportbase/include", ] sources = [ "src/distributed_input_source_transport.cpp" ] @@ -50,18 +45,19 @@ ohos_shared_library("libdinput_source_trans") { deps = [ "${dfx_utils_path}:libdinput_dfx_utils", + "${distributedinput_path}/services/transportbase:libdinput_trans_base", "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", + "${services_source_path}/inputinject:libdinput_inject", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//foundation/distributedhardware/distributed_input/services/source/inputinject:libdinput_inject", "//third_party/libevdev:libevdev", - "//foundation/distributedhardware/distributed_input/services/transportbase:libdinput_trans_base", ] external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", "hitrace_native:hitrace_meter", + "samgr:samgr_proxy", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/services/source/transport/src/distributed_input_source_transport.cpp b/services/source/transport/src/distributed_input_source_transport.cpp index 5fa6c90..5dcbda9 100644 --- a/services/source/transport/src/distributed_input_source_transport.cpp +++ b/services/source/transport/src/distributed_input_source_transport.cpp @@ -661,8 +661,8 @@ void DistributedInputSourceTransport::StartLatencyCount(const std::string& devic while (isLatencyThreadRunning_.load()) { if (sendNum_ >= INPUT_LATENCY_DELAY_TIMES) { uint64_t latency = (uint64_t)(deltaTimeAll_ / 2 / INPUT_LATENCY_DELAY_TIMES); - DHLOGI("LatencyCount average single-channel latency is %d us, send times is %d, recive times is %d, " + - "each RTT latency details is %s", latency, sendNum_, recvNum_, eachLatencyDetails_.c_str()); + DHLOGI("LatencyCount average single-channel latency is %d us, send times is %d, recive times is %d.", + latency, sendNum_, recvNum_); deltaTimeAll_ = 0; sendNum_ = 0; recvNum_ = 0; diff --git a/services/source/transport/test/sourcetransunittest/BUILD.gn b/services/source/transport/test/sourcetransunittest/BUILD.gn index 87ee625..403547e 100755 --- a/services/source/transport/test/sourcetransunittest/BUILD.gn +++ b/services/source/transport/test/sourcetransunittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/source_trans" group("sourcetransunittest") { @@ -27,10 +28,8 @@ ohos_unittest("distributed_input_sourcetrans_test") { module_out_path = module_out_path include_dirs = [ - "//foundation/distributedhardware/distributed_input/services/source/transport/include", - "//foundation/distributedhardware/distributed_input/services/transportbase/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", + "${services_source_path}/transport/include", + "${distributedinput_path}/services/transportbase/include", "${common_path}/include", "${frameworks_path}/include", "${fwk_common_path}/log/include", @@ -42,26 +41,23 @@ ohos_unittest("distributed_input_sourcetrans_test") { "${fwk_interfaces_path}/include/ipc", "${service_common}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", "${services_source_path}/inputinject/include", "${services_source_path}/transport/include", "${services_source_path}/sourcemanager/include", - "//base/hiviewdfx/hitrace/interfaces/native/innerkits/include/hitrace_meter", "${dfx_utils_path}/include", "${utils_path}/include", "${ipc_path}/include", "${frameworks_path}/include", "${distributedinput_path}/inputdevicehandler/include", - "//base/notification/eventhandler/interfaces/inner_api", "${common_path}/test/mock", ] sources = [ - "//foundation/distributedhardware/distributed_input/services/source/transport/src/distributed_input_source_transport.cpp", - "//foundation/distributedhardware/distributed_input/services/transportbase/src/distributed_input_transport_base.cpp", - "distributed_input_sourcetrans_test.cpp", "${common_path}/test/mock/session_mock.cpp", "${common_path}/test/mock/softbus_bus_center_mock.cpp", + "${distributedinput_path}/services/transportbase/src/distributed_input_transport_base.cpp", + "${services_source_path}/transport/src/distributed_input_source_transport.cpp", + "distributed_input_sourcetrans_test.cpp", ] cflags = [ @@ -76,21 +72,22 @@ ohos_unittest("distributed_input_sourcetrans_test") { "HI_LOG_ENABLE", "DH_LOG_TAG=\"distributedinpututtest\"", "LOG_DOMAIN=0xD004100", - "COMPILE_TEST_MODE" + "COMPILE_TEST_MODE", ] deps = [ "${dfx_utils_path}:libdinput_dfx_utils", "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", + "${services_source_path}/inputinject:libdinput_inject", + "${services_source_path}/sourcemanager:libdinput_source", "${utils_path}:libdinput_utils", - "//foundation/distributedhardware/distributed_input/services/source/sourcemanager:libdinput_source", - "//foundation/distributedhardware/distributed_input/services/source/inputinject:libdinput_inject", "//third_party/libevdev:libevdev", ] external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", "hitrace_native:hitrace_meter", ] diff --git a/services/transportbase/BUILD.gn b/services/transportbase/BUILD.gn index 4e0f8b9..8dbeea4 100644 --- a/services/transportbase/BUILD.gn +++ b/services/transportbase/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -19,32 +19,23 @@ ohos_shared_library("libdinput_trans_base") { include_dirs = [ "include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${frameworks_path}/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_utils_path}/include/log", "${fwk_utils_path}/include", "//third_party/json/include", - "//foundation/communication/dsoftbus/interfaces/kits/transport", "${service_common}/include", "${dfx_utils_path}/include", "${utils_path}/include", - "//third_party/libevdev/libevdev/", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", - "//foundation/distributedhardware/distributed_input/services/transportbase/include", + "${distributedinput_path}/services/transportbase/include", "${distributedinput_path}/services/source/inputinject/include", "${distributedinput_path}/inputdevicehandler/include", ] - sources = [ - "src/distributed_input_transport_base.cpp", - ] + sources = [ "src/distributed_input_transport_base.cpp" ] defines = [ "HI_LOG_ENABLE", @@ -54,19 +45,21 @@ ohos_shared_library("libdinput_trans_base") { deps = [ "${dfx_utils_path}:libdinput_dfx_utils", - "${fwk_utils_path}:distributedhardwareutils", "${fwk_interfaces_path}:libdhfwk_sdk", + "${fwk_utils_path}:distributedhardwareutils", + "${services_source_path}/inputinject:libdinput_inject", "${utils_path}:libdinput_utils", "//third_party/libevdev:libevdev", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//foundation/communication/dsoftbus/sdk:softbus_client", - "//foundation/distributedhardware/distributed_input/services/source/inputinject:libdinput_inject", - "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy:samgr_proxy", ] external_deps = [ "c_utils:utils", + "dsoftbus:softbus_client", + "eventhandler:libeventhandler", "hitrace_native:hitrace_meter", + "ipc:ipc_core", + "safwk:system_ability_fwk", + "samgr:samgr_proxy", ] cflags_cc = [ "-DHILOG_ENABLE" ] diff --git a/services/transportbase/test/transbaseunittest/BUILD.gn b/services/transportbase/test/transbaseunittest/BUILD.gn index 8ede4ae..e59e1e0 100644 --- a/services/transportbase/test/transbaseunittest/BUILD.gn +++ b/services/transportbase/test/transbaseunittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/trans_base" group("transbaseunittest") { @@ -27,11 +28,9 @@ ohos_unittest("distributed_input_transbase_test") { module_out_path = module_out_path include_dirs = [ - "//foundation/distributedhardware/distributed_input/services/source/transport/include", - "//foundation/distributedhardware/distributed_input/services/sink/transport/include", - "//foundation/distributedhardware/distributed_input/services/transportbase/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", + "${distributedinput_path}/services/source/transport/include", + "${distributedinput_path}/services/sink/transport/include", + "${distributedinput_path}/services/transportbase/include", "${common_path}/include", "${fwk_interfaces_path}/include", "${fwk_common_path}/log/include", @@ -44,21 +43,18 @@ ohos_unittest("distributed_input_transbase_test") { "${utils_path}/include", "${frameworks_path}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", "${distributedinput_path}/inputdevicehandler/include", - "//base/hiviewdfx/hitrace/interfaces/native/innerkits/include/hitrace_meter", - "//base/notification/eventhandler/interfaces/inner_api", "${common_path}/test/mock", ] sources = [ - "//foundation/distributedhardware/distributed_input/services/source/transport/src/distributed_input_source_transport.cpp", - "//foundation/distributedhardware/distributed_input/services/sink/transport/src/distributed_input_sink_transport.cpp", - "//foundation/distributedhardware/distributed_input/services/sink/transport/src/distributed_input_sink_switch.cpp", - "//foundation/distributedhardware/distributed_input/services/transportbase/src/distributed_input_transport_base.cpp", - "distributed_input_transbase_test.cpp", "${common_path}/test/mock/session_mock.cpp", "${common_path}/test/mock/softbus_bus_center_mock.cpp", + "${distributedinput_path}/services/transportbase/src/distributed_input_transport_base.cpp", + "${services_sink_path}/transport/src/distributed_input_sink_switch.cpp", + "${services_sink_path}/transport/src/distributed_input_sink_transport.cpp", + "${services_source_path}/transport/src/distributed_input_source_transport.cpp", + "distributed_input_transbase_test.cpp", ] cflags = [ @@ -73,21 +69,21 @@ ohos_unittest("distributed_input_transbase_test") { "HI_LOG_ENABLE", "DH_LOG_TAG=\"distributedinpututtest\"", "LOG_DOMAIN=0xD004100", - "COMPILE_TEST_MODE" + "COMPILE_TEST_MODE", ] deps = [ "${dfx_utils_path}:libdinput_dfx_utils", "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", + "${services_source_path}/inputinject:libdinput_inject", "${utils_path}:libdinput_utils", "//third_party/libevdev:libevdev", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//foundation/distributedhardware/distributed_input/services/source/inputinject:libdinput_inject", ] external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", "hitrace_native:hitrace_meter", ] diff --git a/sinkhandler/BUILD.gn b/sinkhandler/BUILD.gn index 2aa7849..4398b17 100644 --- a/sinkhandler/BUILD.gn +++ b/sinkhandler/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -26,8 +26,6 @@ ohos_shared_library("libdinput_sink_handler") { "${frameworks_path}/include", "${service_common}/include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_utils_path}/include/log", @@ -36,8 +34,6 @@ ohos_shared_library("libdinput_sink_handler") { "${utils_path}/include", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent/include", ] sources = [ @@ -55,13 +51,14 @@ ohos_shared_library("libdinput_sink_handler") { "${dfx_utils_path}:libdinput_dfx_utils", "${fwk_utils_path}:distributedhardwareutils", "${innerkits_path}:libdinput_sdk", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "${dfx_utils_path}:libdinput_dfx_utils", ] external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", + "hisysevent_native:libhisysevent", "ipc:ipc_core", + "safwk:system_ability_fwk", "samgr:samgr_proxy", ] diff --git a/sinkhandler/test/unittest/BUILD.gn b/sinkhandler/test/unittest/BUILD.gn index c4cf9a9..3de7017 100755 --- a/sinkhandler/test/unittest/BUILD.gn +++ b/sinkhandler/test/unittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/sink_handler" group("unittest") { @@ -36,8 +37,6 @@ ohos_unittest("distributed_input_sink_handler_test") { "${frameworks_path}/include", "${service_common}/include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_utils_path}/include/log", @@ -48,13 +47,12 @@ ohos_unittest("distributed_input_sink_handler_test") { "${fwk_interfaces_path}/include/ipc", "${services_source_path}/inputinject/include", "${utils_path}/include", - "//base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent/include", ] sources = [ - "//foundation/distributedhardware/distributed_input/sinkhandler/src/distributed_input_sink_handler.cpp", - "//foundation/distributedhardware/distributed_input/sinkhandler/src/load_d_input_sink_callback.cpp", - "//foundation/distributedhardware/distributed_input/sinkhandler/test/unittest/mock/mock_distributed_input_client.cpp", + "${distributedinput_path}/sinkhandler/src/distributed_input_sink_handler.cpp", + "${distributedinput_path}/sinkhandler/src/load_d_input_sink_callback.cpp", + "${distributedinput_path}/sinkhandler/test/unittest/mock/mock_distributed_input_client.cpp", "distributed_input_sinkhandler_test.cpp", ] @@ -76,11 +74,12 @@ ohos_unittest("distributed_input_sink_handler_test") { "${dfx_utils_path}:libdinput_dfx_utils", "${fwk_utils_path}:distributedhardwareutils", "${innerkits_path}:libdinput_sdk", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", ] external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", + "hisysevent_native:libhisysevent", "ipc:ipc_core", "samgr:samgr_proxy", ] diff --git a/sourcehandler/BUILD.gn b/sourcehandler/BUILD.gn index 81189a8..883c692 100644 --- a/sourcehandler/BUILD.gn +++ b/sourcehandler/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -26,8 +26,6 @@ ohos_shared_library("libdinput_source_handler") { "${frameworks_path}/include", "${service_common}/include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_utils_path}/include/log", @@ -37,9 +35,6 @@ ohos_shared_library("libdinput_source_handler") { "${fwk_interfaces_path}/include/ipc", "${utils_path}/include", "${services_source_path}/inputinject/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", - "//base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent/include", - "//third_party/libevdev/libevdev/" ] sources = [ @@ -57,14 +52,15 @@ ohos_shared_library("libdinput_source_handler") { "${dfx_utils_path}:libdinput_dfx_utils", "${fwk_utils_path}:distributedhardwareutils", "${innerkits_path}:libdinput_sdk", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "${dfx_utils_path}:libdinput_dfx_utils", "//third_party/libevdev:libevdev", ] external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", + "hisysevent_native:libhisysevent", "ipc:ipc_core", + "safwk:system_ability_fwk", "samgr:samgr_proxy", ] diff --git a/sourcehandler/test/unittest/BUILD.gn b/sourcehandler/test/unittest/BUILD.gn index f50fab0..c37b072 100755 --- a/sourcehandler/test/unittest/BUILD.gn +++ b/sourcehandler/test/unittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/source_handler" group("unittest") { @@ -36,8 +37,6 @@ ohos_unittest("distributed_input_source_handler_test") { "${frameworks_path}/include", "${service_common}/include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_utils_path}/include/log", @@ -48,14 +47,12 @@ ohos_unittest("distributed_input_source_handler_test") { "${fwk_interfaces_path}/include/ipc", "${services_source_path}/inputinject/include", "${utils_path}/include", - "//base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent/include", - "//third_party/libevdev/libevdev/", ] sources = [ - "//foundation/distributedhardware/distributed_input/sourcehandler/src/distributed_input_source_handler.cpp", - "//foundation/distributedhardware/distributed_input/sourcehandler/src/load_d_input_source_callback.cpp", - "//foundation/distributedhardware/distributed_input/sourcehandler/test/unittest/mock/mock_distributed_input_client.cpp", + "${distributedinput_path}/sourcehandler/src/distributed_input_source_handler.cpp", + "${distributedinput_path}/sourcehandler/src/load_d_input_source_callback.cpp", + "${distributedinput_path}/sourcehandler/test/unittest/mock/mock_distributed_input_client.cpp", "distributed_input_sourcehandler_test.cpp", ] @@ -77,12 +74,13 @@ ohos_unittest("distributed_input_source_handler_test") { "${dfx_utils_path}:libdinput_dfx_utils", "${fwk_utils_path}:distributedhardwareutils", "${innerkits_path}:libdinput_sdk", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", "//third_party/libevdev:libevdev", ] external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", + "hisysevent_native:libhisysevent", "ipc:ipc_core", "samgr:samgr_proxy", ] diff --git a/test/fuzztest/distributedinputclient_fuzzer/BUILD.gn b/test/fuzztest/distributedinputclient_fuzzer/BUILD.gn index bc08f51..319402a 100755 --- a/test/fuzztest/distributedinputclient_fuzzer/BUILD.gn +++ b/test/fuzztest/distributedinputclient_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -21,7 +21,8 @@ import( ohos_fuzztest("DistributedInputClientFuzzTest") { module_out_path = "distributed_input/system" - fuzz_config_file = "//foundation/distributedhardware/distributed_input/test/fuzztest/distributedinputclient_fuzzer" + fuzz_config_file = + "${distributedinput_path}/test/fuzztest/distributedinputclient_fuzzer" include_dirs = [ "include", @@ -33,13 +34,9 @@ ohos_fuzztest("DistributedInputClientFuzzTest") { "${distributedinput_path}/sourcehandler/include", "${distributedinput_path}/sinkhandler/include", "${distributedinput_path}/inputdevicehandler/include", - "//foundation/distributedhardware/distributed_hardware_fwk/common/utils/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${service_common}/include", "${common_path}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", "//foundation/distributedhardware/distributed_hardware_fwk/common/log/include", "//foundation/distributedhardware/distributed_hardware_fwk/common/utils/include", "//foundation/distributedhardware/distributed_hardware_fwk/utils/include/log", @@ -48,9 +45,6 @@ ohos_fuzztest("DistributedInputClientFuzzTest") { "${fwk_interfaces_path}/include/ipc", "${services_source_path}/inputinject/include", "${utils_path}/include", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//base/notification/eventhandler/interfaces/inner_api", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", ] cflags = [ @@ -70,6 +64,9 @@ ohos_fuzztest("DistributedInputClientFuzzTest") { external_deps = [ "c_utils:utils", "dsoftbus:softbus_client", + "eventhandler:libeventhandler", + "ipc:ipc_core", + "safwk:system_ability_fwk", ] defines = [ diff --git a/test/fuzztest/distributedinputkit_fuzzer/BUILD.gn b/test/fuzztest/distributedinputkit_fuzzer/BUILD.gn index 156e6fd..d18bcc9 100755 --- a/test/fuzztest/distributedinputkit_fuzzer/BUILD.gn +++ b/test/fuzztest/distributedinputkit_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -21,7 +21,8 @@ import( ohos_fuzztest("DistributedInputKitFuzzTest") { module_out_path = "distributed_input/system" - fuzz_config_file = "//foundation/distributedhardware/distributed_input/test/fuzztest/distributedinputkit_fuzzer" + fuzz_config_file = + "${distributedinput_path}/test/fuzztest/distributedinputkit_fuzzer" include_dirs = [ "include", @@ -33,13 +34,9 @@ ohos_fuzztest("DistributedInputKitFuzzTest") { "${distributedinput_path}/sourcehandler/include", "${distributedinput_path}/sinkhandler/include", "${distributedinput_path}/inputdevicehandler/include", - "//foundation/distributedhardware/distributed_hardware_fwk/common/utils/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", "${service_common}/include", "${common_path}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", "//foundation/distributedhardware/distributed_hardware_fwk/common/log/include", "//foundation/distributedhardware/distributed_hardware_fwk/common/utils/include", "//foundation/distributedhardware/distributed_hardware_fwk/utils/include/log", @@ -48,7 +45,6 @@ ohos_fuzztest("DistributedInputKitFuzzTest") { "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", "${services_source_path}/inputinject/include", - "//base/notification/eventhandler/interfaces/inner_api", ] cflags = [ @@ -67,6 +63,7 @@ ohos_fuzztest("DistributedInputKitFuzzTest") { external_deps = [ "c_utils:utils", + "eventhandler:libeventhandler", "ipc:ipc_core", ] diff --git a/test/fuzztest/distributedinputsinktransport_fuzzer/BUILD.gn b/test/fuzztest/distributedinputsinktransport_fuzzer/BUILD.gn index 6b48102..40f6d40 100755 --- a/test/fuzztest/distributedinputsinktransport_fuzzer/BUILD.gn +++ b/test/fuzztest/distributedinputsinktransport_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -21,13 +21,11 @@ import( ohos_fuzztest("DistributedInputSinkTransportFuzzTest") { module_out_path = "distributed_input/system" - fuzz_config_file = "//foundation/distributedhardware/distributed_input/test/fuzztest/distributedinputsinktransport_fuzzer" + fuzz_config_file = "${distributedinput_path}/test/fuzztest/distributedinputsinktransport_fuzzer" include_dirs = [ - "//foundation/distributedhardware/distributed_input/services/sink/transport/include", - "//foundation/distributedhardware/distributed_input/services/transportbase/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", + "${services_sink_path}/transport/include", + "${distributedinput_path}/services/transportbase/include", "${common_path}/include", "${frameworks_path}/include", "${fwk_common_path}/log/include", @@ -37,11 +35,8 @@ ohos_fuzztest("DistributedInputSinkTransportFuzzTest") { "${fwk_utils_path}/include", "${service_common}/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", "${dfx_utils_path}/include", "${utils_path}/include", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", ] cflags = [ @@ -51,25 +46,26 @@ ohos_fuzztest("DistributedInputSinkTransportFuzzTest") { "-fno-omit-frame-pointer", ] sources = [ - "//foundation/distributedhardware/distributed_input/services/sink/transport/src/distributed_input_sink_switch.cpp", - "//foundation/distributedhardware/distributed_input/services/sink/transport/src/distributed_input_sink_transport.cpp", + "${services_sink_path}/transport/src/distributed_input_sink_switch.cpp", + "${services_sink_path}/transport/src/distributed_input_sink_transport.cpp", "distributed_input_sink_transport_fuzzer.cpp", ] deps = [ - "${fwk_interfaces_path}:libdhfwk_sdk", "${dfx_utils_path}:libdinput_dfx_utils", + "${distributedinput_path}/services/transportbase:libdinput_trans_base", + "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//foundation/communication/dsoftbus/sdk:softbus_client", "//third_party/libevdev:libevdev", - "//foundation/distributedhardware/distributed_input/services/transportbase:libdinput_trans_base", ] external_deps = [ "c_utils:utils", "dsoftbus:softbus_client", + "eventhandler:libeventhandler", + "ipc:ipc_core", + "safwk:system_ability_fwk", ] defines = [ diff --git a/test/fuzztest/distributedinputsourcetransport_fuzzer/BUILD.gn b/test/fuzztest/distributedinputsourcetransport_fuzzer/BUILD.gn index a7ae367..d9ef3ac 100755 --- a/test/fuzztest/distributedinputsourcetransport_fuzzer/BUILD.gn +++ b/test/fuzztest/distributedinputsourcetransport_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021-2022 Huawei Device Co., Ltd. +# Copyright (c) 2021-2023 Huawei Device Co., Ltd. # 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 @@ -21,15 +21,12 @@ import( ohos_fuzztest("DistributedInputSourceTransportFuzzTest") { module_out_path = "distributed_input/system" - fuzz_config_file = "//foundation/distributedhardware/distributed_input/test/fuzztest/distributedinputsourcetransport_fuzzer" + fuzz_config_file = "${distributedinput_path}/test/fuzztest/distributedinputsourcetransport_fuzzer" include_dirs = [ - "//foundation/distributedhardware/distributed_input/services/source/transport/include", - "//foundation/distributedhardware/distributed_input/services/transportbase/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", + "${services_source_path}/transport/include", + "${distributedinput_path}/services/transportbase/include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_interfaces_path}/include", @@ -39,14 +36,10 @@ ohos_fuzztest("DistributedInputSourceTransportFuzzTest") { "${services_source_path}/inputinject/include", "${services_source_path}/transport/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", "${dfx_utils_path}/include", "${utils_path}/include", - "//base/hiviewdfx/hitrace/interfaces/native/innerkits/include/hitrace_meter", "${frameworks_path}/include", "${distributedinput_path}/inputdevicehandler/include", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", ] cflags = [ @@ -57,25 +50,27 @@ ohos_fuzztest("DistributedInputSourceTransportFuzzTest") { ] sources = [ - "//foundation/distributedhardware/distributed_input/services/source/transport/src/distributed_input_source_transport.cpp", + "${services_source_path}/transport/src/distributed_input_source_transport.cpp", "distributed_input_source_transport_fuzzer.cpp", ] deps = [ "${dfx_utils_path}:libdinput_dfx_utils", + "${distributedinput_path}/services/transportbase:libdinput_trans_base", "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", + "${services_source_path}/inputinject:libdinput_inject", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//foundation/distributedhardware/distributed_input/services/source/inputinject:libdinput_inject", "//third_party/libevdev:libevdev", - "//foundation/distributedhardware/distributed_input/services/transportbase:libdinput_trans_base", ] external_deps = [ "c_utils:utils", "dsoftbus:softbus_client", + "eventhandler:libeventhandler", "hitrace_native:hitrace_meter", + "ipc:ipc_core", + "safwk:system_ability_fwk", ] defines = [ diff --git a/test/fuzztest/distributedinputtransportbase_fuzzer/BUILD.gn b/test/fuzztest/distributedinputtransportbase_fuzzer/BUILD.gn index 3f83a9a..025cdf9 100644 --- a/test/fuzztest/distributedinputtransportbase_fuzzer/BUILD.gn +++ b/test/fuzztest/distributedinputtransportbase_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -21,15 +21,12 @@ import( ohos_fuzztest("DistributedInputTransportBaseFuzzTest") { module_out_path = "distributed_input/system" - fuzz_config_file = "//foundation/distributedhardware/distributed_input/test/fuzztest/distributedinputtransportbase_fuzzer" + fuzz_config_file = "${distributedinput_path}/test/fuzztest/distributedinputtransportbase_fuzzer" include_dirs = [ - "//foundation/distributedhardware/distributed_input/services/source/transport/include", - "//foundation/distributedhardware/distributed_input/services/transportbase/include", - "//commonlibrary/c_utils/base/include", - "//utils/system/safwk/native/include", + "${services_source_path}/transport/include", + "${distributedinput_path}/services/transportbase/include", "${common_path}/include", - "//commonlibrary/c_utils/base/include", "${fwk_common_path}/log/include", "${fwk_common_path}/utils/include", "${fwk_interfaces_path}/include", @@ -39,14 +36,10 @@ ohos_fuzztest("DistributedInputTransportBaseFuzzTest") { "${services_source_path}/inputinject/include", "${services_source_path}/transport/include", "//third_party/json/include", - "//third_party/libevdev/libevdev/", "${dfx_utils_path}/include", "${utils_path}/include", - "//base/hiviewdfx/hitrace/interfaces/native/innerkits/include/hitrace_meter", "${frameworks_path}/include", "${distributedinput_path}/inputdevicehandler/include", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk", ] cflags = [ @@ -57,25 +50,27 @@ ohos_fuzztest("DistributedInputTransportBaseFuzzTest") { ] sources = [ - "//foundation/distributedhardware/distributed_input/services/transportbase/src/distributed_input_transport_base.cpp", + "${distributedinput_path}/services/transportbase/src/distributed_input_transport_base.cpp", "distributed_input_transport_base_fuzzer.cpp", ] deps = [ "${dfx_utils_path}:libdinput_dfx_utils", + "${distributedinput_path}/services/transportbase:libdinput_trans_base", "${fwk_interfaces_path}:libdhfwk_sdk", "${fwk_utils_path}:distributedhardwareutils", + "${services_source_path}/inputinject:libdinput_inject", "${utils_path}:libdinput_utils", - "//base/notification/eventhandler/frameworks/eventhandler:libeventhandler", - "//foundation/distributedhardware/distributed_input/services/source/inputinject:libdinput_inject", "//third_party/libevdev:libevdev", - "//foundation/distributedhardware/distributed_input/services/transportbase:libdinput_trans_base", ] external_deps = [ "c_utils:utils", "dsoftbus:softbus_client", + "eventhandler:libeventhandler", "hitrace_native:hitrace_meter", + "ipc:ipc_core", + "safwk:system_ability_fwk", ] defines = [ diff --git a/utils/BUILD.gn b/utils/BUILD.gn index b72c309..7f471fe 100644 --- a/utils/BUILD.gn +++ b/utils/BUILD.gn @@ -29,10 +29,7 @@ ohos_shared_library("libdinput_utils") { "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", "${dfx_utils_path}/include", - "//commonlibrary/c_utils/base/include", "${frameworks_path}/include", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", - "//base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent/include", ] sources = [ @@ -48,16 +45,18 @@ ohos_shared_library("libdinput_utils") { ] deps = [ - "${fwk_utils_path}:distributedhardwareutils", "${fwk_interfaces_path}:libdhfwk_sdk", + "${fwk_utils_path}:distributedhardwareutils", "//third_party/openssl:libcrypto_static", ] external_deps = [ - "dsoftbus:softbus_client", - "samgr:samgr_proxy", "c_utils:utils", + "dsoftbus:softbus_client", + "hisysevent_native:libhisysevent", "hiviewdfx_hilog_native:libhilog", + "ipc:ipc_core", + "samgr:samgr_proxy", ] subsystem_name = "distributedhardware" diff --git a/utils/test/unittest/BUILD.gn b/utils/test/unittest/BUILD.gn index 0dd27e9..eba48ae 100644 --- a/utils/test/unittest/BUILD.gn +++ b/utils/test/unittest/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022 Huawei Device Co., Ltd. +# Copyright (c) 2022-2023 Huawei Device Co., Ltd. # 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 @@ -14,6 +14,7 @@ import("//build/test.gni") import( "//foundation/distributedhardware/distributed_input/distributedinput.gni") + module_out_path = "distributed_input/utils" group("unittest") { @@ -36,21 +37,18 @@ ohos_unittest("distributed_input_utils_test") { "${common_path}/include", "${fwk_interfaces_path}/include", "${fwk_interfaces_path}/include/ipc", - "//commonlibrary/c_utils/base/include", "${frameworks_path}/include", - "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", "//third_party/json/include", "${common_path}/test/mock", "${service_common}/include", - "//base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent/include", ] sources = [ - "dinput_context_test.cpp", + "${common_path}/test/mock/softbus_bus_center_mock.cpp", "${distributedinput_path}/utils/src/dinput_context.cpp", - "${distributedinput_path}/utils/src/dinput_utils_tool.cpp", "${distributedinput_path}/utils/src/dinput_log.cpp", - "${common_path}/test/mock/softbus_bus_center_mock.cpp", + "${distributedinput_path}/utils/src/dinput_utils_tool.cpp", + "dinput_context_test.cpp", ] cflags = [ @@ -65,7 +63,7 @@ ohos_unittest("distributed_input_utils_test") { "HI_LOG_ENABLE", "DH_LOG_TAG=\"distributedinpututtest\"", "LOG_DOMAIN=0xD004100", - "COMPILE_TEST_MODE" + "COMPILE_TEST_MODE", ] deps = [ @@ -74,9 +72,11 @@ ohos_unittest("distributed_input_utils_test") { ] external_deps = [ - "samgr:samgr_proxy", "c_utils:utils", + "hisysevent_native:libhisysevent", "hiviewdfx_hilog_native:libhilog", + "ipc:ipc_core", + "samgr:samgr_proxy", ] cflags_cc = [ "-DHILOG_ENABLE" ] -- Gitee