From fe4080dcf7f13b4f34c4a5eb52bba4ad1034e98b Mon Sep 17 00:00:00 2001 From: heguokai Date: Thu, 8 May 2025 16:02:55 +0800 Subject: [PATCH] fix gn Signed-off-by: heguokai --- bundle.json | 5 ++++- frameworks/ans/BUILD.gn | 3 +-- frameworks/ans/test/unittest/BUILD.gn | 1 + frameworks/js/napi/include/cancel.h | 1 - frameworks/reminder/test/unittest/BUILD.gn | 4 ++++ frameworks/test/moduletest/BUILD.gn | 9 +++++---- services/ans/test/unittest/BUILD.gn | 2 ++ test/bechmarktest/notification_publish_test/BUILD.gn | 1 + test/bechmarktest/notification_services_test/BUILD.gn | 2 ++ .../addnotificationslot_fuzzer.cpp | 1 - test/fuzztest/fuzz_common_base/BUILD.gn | 1 + tools/test/unittest/dump/BUILD.gn | 1 + 12 files changed, 22 insertions(+), 9 deletions(-) diff --git a/bundle.json b/bundle.json index 2617c996d..9d41c2c36 100644 --- a/bundle.json +++ b/bundle.json @@ -108,7 +108,10 @@ "libxml2", "node", "googletest", - "icu" + "icu", + "node", + "cJSON", + "selinux_adapter" ], "third_party": [ "libuv", diff --git a/frameworks/ans/BUILD.gn b/frameworks/ans/BUILD.gn index eaaba778a..22bc47c61 100644 --- a/frameworks/ans/BUILD.gn +++ b/frameworks/ans/BUILD.gn @@ -43,7 +43,6 @@ config("ans_innerkits_public_config") { "${core_path}/include", "${target_gen_dir}", ] - configs = [ "${multimedia_path}/interfaces/innerkits:image_external_config" ] } config("ans_innerkits_config") { @@ -56,7 +55,6 @@ config("ans_innerkits_config") { "${core_path}/include", "${target_gen_dir}", ] - configs = [ "${multimedia_path}/interfaces/innerkits:image_external_config" ] } ohos_shared_library("ans_innerkits") { @@ -158,6 +156,7 @@ ohos_shared_library("ans_innerkits") { "ability_runtime:appkit_native", "bundle_framework:appexecfwk_base", "bundle_framework:appexecfwk_core", + "cJSON:cjson_static", "c_utils:utils", "eventhandler:libeventhandler", "hicollie:libhicollie", diff --git a/frameworks/ans/test/unittest/BUILD.gn b/frameworks/ans/test/unittest/BUILD.gn index a00976229..0db5c73f7 100644 --- a/frameworks/ans/test/unittest/BUILD.gn +++ b/frameworks/ans/test/unittest/BUILD.gn @@ -106,6 +106,7 @@ ohos_unittest("ans_test") { "relational_store:native_rdb", "safwk:system_ability_fwk", "samgr:samgr_proxy", + "selinux_adapter:librestorecon", ] subsystem_name = "${subsystem_name}" diff --git a/frameworks/js/napi/include/cancel.h b/frameworks/js/napi/include/cancel.h index c641f7520..ecea9c5d4 100644 --- a/frameworks/js/napi/include/cancel.h +++ b/frameworks/js/napi/include/cancel.h @@ -17,7 +17,6 @@ #define BASE_NOTIFICATION_DISTRIBUTED_NOTIFICATION_SERVICE_FRAMEWORKS_JS_NAPI_CANCEL_H #include "common.h" -#include "commonlibrary/utils_lite/include/ohos_types.h" namespace OHOS { namespace NotificationNapi { diff --git a/frameworks/reminder/test/unittest/BUILD.gn b/frameworks/reminder/test/unittest/BUILD.gn index 3a9396e64..edddef55a 100644 --- a/frameworks/reminder/test/unittest/BUILD.gn +++ b/frameworks/reminder/test/unittest/BUILD.gn @@ -69,6 +69,7 @@ ohos_unittest("reminder_test") { "relational_store:native_rdb", "safwk:system_ability_fwk", "samgr:samgr_proxy", + "selinux_adapter:librestorecon", ] subsystem_name = "${subsystem_name}" @@ -112,6 +113,7 @@ ohos_unittest("reminder_request_test") { "ability_base:want", "ability_base:zuri", "c_utils:utils", + "hilog:libhilog", "relational_store:native_rdb", ] cflags = [ @@ -147,6 +149,7 @@ ohos_unittest("reminder_request_branch_test") { "ability_base:want", "ability_base:zuri", "c_utils:utils", + "hilog:libhilog", "relational_store:native_rdb", ] cflags = [ @@ -181,6 +184,7 @@ ohos_unittest("reminder_agent_idl_test") { "ability_base:zuri", "c_utils:utils", "googletest:gmock_main", + "hilog:libhilog", "ipc:ipc_core", "relational_store:native_rdb", ] diff --git a/frameworks/test/moduletest/BUILD.gn b/frameworks/test/moduletest/BUILD.gn index f925a8d00..25ce679c2 100644 --- a/frameworks/test/moduletest/BUILD.gn +++ b/frameworks/test/moduletest/BUILD.gn @@ -167,6 +167,7 @@ ohos_moduletest("ans_innerkits_module_publish_test") { "relational_store:native_rdb", "safwk:system_ability_fwk", "samgr:samgr_proxy", + "selinux_adapter:librestorecon", ] subsystem_name = "${subsystem_name}" @@ -225,6 +226,7 @@ ohos_moduletest("ans_innerkits_module_slot_test") { "common_event_service:cesfwk_innerkits", "eventhandler:libeventhandler", "ffrt:libffrt", + "googletest:gtest_main", "hilog:libhilog", "image_framework:image_native", "ipc:ipc_core", @@ -233,10 +235,9 @@ ohos_moduletest("ans_innerkits_module_slot_test") { "relational_store:native_rdb", "safwk:system_ability_fwk", "samgr:samgr_proxy", + "selinux_adapter:librestorecon", ] - public_external_deps = [ "googletest:gtest_main" ] - subsystem_name = "${subsystem_name}" part_name = "${component_name}" } @@ -299,6 +300,7 @@ ohos_moduletest("ans_innerkits_module_setting_test") { "common_event_service:cesfwk_innerkits", "eventhandler:libeventhandler", "ffrt:libffrt", + "googletest:gtest_main", "hilog:libhilog", "image_framework:image_native", "ipc:ipc_core", @@ -307,10 +309,9 @@ ohos_moduletest("ans_innerkits_module_setting_test") { "relational_store:native_rdb", "safwk:system_ability_fwk", "samgr:samgr_proxy", + "selinux_adapter:librestorecon", ] - public_external_deps = [ "googletest:gtest_main" ] - subsystem_name = "${subsystem_name}" part_name = "${component_name}" } diff --git a/services/ans/test/unittest/BUILD.gn b/services/ans/test/unittest/BUILD.gn index 58a18318e..2a7d21546 100644 --- a/services/ans/test/unittest/BUILD.gn +++ b/services/ans/test/unittest/BUILD.gn @@ -1449,6 +1449,7 @@ ohos_unittest("advanced_notification_service_unit_test") { "data_share:datashare_common", "data_share:datashare_consumer", "ffrt:libffrt", + "hilog:libhilog", "ipc:ipc_core", "kv_store:distributeddata_inner", "time_service:time_client", @@ -1491,6 +1492,7 @@ ohos_unittest("common_utils_test") { external_deps = [ "ability_base:zuri", "c_utils:utils", + "hilog:libhilog", ] subsystem_name = "${subsystem_name}" diff --git a/test/bechmarktest/notification_publish_test/BUILD.gn b/test/bechmarktest/notification_publish_test/BUILD.gn index 1cd96d741..8bfe962d9 100644 --- a/test/bechmarktest/notification_publish_test/BUILD.gn +++ b/test/bechmarktest/notification_publish_test/BUILD.gn @@ -34,6 +34,7 @@ ohos_benchmarktest("Benchmark_Publish_Test") { "ability_runtime:wantagent_innerkits", "c_utils:utils", "googletest:gtest_main", + "hilog:libhilog", "image_framework:image_native", "relational_store:native_rdb", ] diff --git a/test/bechmarktest/notification_services_test/BUILD.gn b/test/bechmarktest/notification_services_test/BUILD.gn index 414e4629a..96f122966 100644 --- a/test/bechmarktest/notification_services_test/BUILD.gn +++ b/test/bechmarktest/notification_services_test/BUILD.gn @@ -48,9 +48,11 @@ ohos_benchmarktest("Benchmark_Notification_Servece_Test") { "common_event_service:cesfwk_innerkits", "ffrt:libffrt", "googletest:gtest_main", + "hilog:libhilog", "image_framework:image_native", "kv_store:distributeddata_inner", "relational_store:native_rdb", + "selinux_adapter:librestorecon", ] subsystem_name = "${subsystem_name}" diff --git a/test/fuzztest/addnotificationslot_fuzzer/addnotificationslot_fuzzer.cpp b/test/fuzztest/addnotificationslot_fuzzer/addnotificationslot_fuzzer.cpp index 66ac398df..8f36542fd 100644 --- a/test/fuzztest/addnotificationslot_fuzzer/addnotificationslot_fuzzer.cpp +++ b/test/fuzztest/addnotificationslot_fuzzer/addnotificationslot_fuzzer.cpp @@ -15,7 +15,6 @@ #include "addnotificationslot_fuzzer.h" -#include "base/accesscontrol/sandbox_manager/test/fuzztest/common/alloc_token.h" #include "notification_helper.h" #include #include diff --git a/test/fuzztest/fuzz_common_base/BUILD.gn b/test/fuzztest/fuzz_common_base/BUILD.gn index c12b70c85..778d17502 100644 --- a/test/fuzztest/fuzz_common_base/BUILD.gn +++ b/test/fuzztest/fuzz_common_base/BUILD.gn @@ -31,6 +31,7 @@ static_library("fuzz_common_base") { "access_token:libaccesstoken_sdk", "access_token:libnativetoken", "access_token:libtoken_setproc", + "selinux_adapter:librestorecon", ] public_external_deps = [ "c_utils:utils" ] diff --git a/tools/test/unittest/dump/BUILD.gn b/tools/test/unittest/dump/BUILD.gn index 144fd6fe6..45e3d7dba 100644 --- a/tools/test/unittest/dump/BUILD.gn +++ b/tools/test/unittest/dump/BUILD.gn @@ -77,6 +77,7 @@ ohos_unittest("notification_shell_command_dump_test") { "hilog:libhilog", "ipc:ipc_core", "relational_store:native_rdb", + "selinux_adapter:librestorecon", ] } -- Gitee