From c7dc7e943f3e4abb30b1848350f0968d250a6e96 Mon Sep 17 00:00:00 2001 From: zhrenqiang Date: Wed, 20 Nov 2024 19:34:20 +0800 Subject: [PATCH] rm quickfix Signed-off-by: zhrenqiang Change-Id: I8f52a405c7691b55080e248d0c810ec4bf6b88f3 --- .../unittest/bms_bundle_overlay_test/BUILD.gn | 37 +++++++++++++++---- .../bundleinstalldhost_fuzzer/BUILD.gn | 5 ++- .../bundleinstallerhost_fuzzer/BUILD.gn | 6 ++- .../aginghandlerchain_fuzzer/BUILD.gn | 5 ++- .../agingrequest_fuzzer/BUILD.gn | 5 ++- .../fuzztest_others/agingutil_fuzzer/BUILD.gn | 5 ++- .../bundleagingmgr_fuzzer/BUILD.gn | 5 ++- .../BUILD.gn | 5 ++- .../bundleoverlaymgr_fuzzer/BUILD.gn | 5 ++- .../overlaydatamgr_fuzzer/BUILD.gn | 5 ++- .../overlaymgrhostimpl_fuzzer/BUILD.gn | 5 ++- 11 files changed, 71 insertions(+), 17 deletions(-) diff --git a/services/bundlemgr/test/unittest/bms_bundle_overlay_test/BUILD.gn b/services/bundlemgr/test/unittest/bms_bundle_overlay_test/BUILD.gn index 5d9c454ff..5b0a71752 100644 --- a/services/bundlemgr/test/unittest/bms_bundle_overlay_test/BUILD.gn +++ b/services/bundlemgr/test/unittest/bms_bundle_overlay_test/BUILD.gn @@ -42,7 +42,6 @@ ohos_unittest("BmsBundleOverlayCheckerTest") { "${services_path}/bundlemgr/test/mock/src/accesstoken_kit.cpp", "${services_path}/bundlemgr/test/mock/src/bundle_mgr_service_event_handler.cpp", "${services_path}/bundlemgr/test/mock/src/installd_permission_mgr.cpp", - "${services_path}/bundlemgr/test/mock/src/mock_quick_fix_callback.cpp", "${services_path}/bundlemgr/test/mock/src/mock_status_receiver.cpp", "${services_path}/bundlemgr/test/mock/src/system_ability_helper.cpp", ] @@ -90,13 +89,17 @@ ohos_unittest("BmsBundleOverlayCheckerTest") { "ability_runtime:ability_manager", "ability_runtime:app_manager", "battery_manager:batterysrv_client", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "ffrt:libffrt", "power_manager:powermgr_client", "syscap_codec:syscap_interface_shared", ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } + external_deps += bundle_install_external_deps if (code_signature_enable) { @@ -192,13 +195,17 @@ ohos_unittest("BmsBundleOverlayInfoTest") { "ability_runtime:ability_manager", "ability_runtime:app_manager", "battery_manager:batterysrv_client", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "ffrt:libffrt", "power_manager:powermgr_client", "syscap_codec:syscap_interface_shared", ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } + if (bundle_framework_power_mgr_enable) { external_deps += aot_external_deps } @@ -299,13 +306,17 @@ ohos_unittest("BmsBundleOverlayIpcTest") { "ability_runtime:ability_manager", "ability_runtime:app_manager", "battery_manager:batterysrv_client", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "ffrt:libffrt", "power_manager:powermgr_client", "syscap_codec:syscap_interface_shared", ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } + external_deps += bundle_install_external_deps if (bundle_framework_power_mgr_enable) { @@ -442,13 +453,17 @@ ohos_unittest("BmsBundleManagerOverlayIpcTest") { "ability_runtime:ability_manager", "ability_runtime:app_manager", "battery_manager:batterysrv_client", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "ffrt:libffrt", "power_manager:powermgr_client", "syscap_codec:syscap_interface_shared", ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } + external_deps += bundle_install_external_deps if (bundle_framework_power_mgr_enable) { @@ -585,13 +600,17 @@ ohos_unittest("BmsBundleSetOverlayEnabledTest") { "ability_runtime:ability_manager", "ability_runtime:app_manager", "battery_manager:batterysrv_client", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "ffrt:libffrt", "power_manager:powermgr_client", "syscap_codec:syscap_interface_shared", ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } + external_deps += bundle_install_external_deps if (bundle_framework_power_mgr_enable) { @@ -729,13 +748,17 @@ ohos_unittest("BmsBundleGetOverlayModuleInfoTest") { "ability_runtime:ability_manager", "ability_runtime:app_manager", "battery_manager:batterysrv_client", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "ffrt:libffrt", "power_manager:powermgr_client", "syscap_codec:syscap_interface_shared", ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } + external_deps += bundle_install_external_deps if (bundle_framework_power_mgr_enable) { diff --git a/test/fuzztest/fuzztest_application/bundleinstalldhost_fuzzer/BUILD.gn b/test/fuzztest/fuzztest_application/bundleinstalldhost_fuzzer/BUILD.gn index 1718962d7..338c77842 100644 --- a/test/fuzztest/fuzztest_application/bundleinstalldhost_fuzzer/BUILD.gn +++ b/test/fuzztest/fuzztest_application/bundleinstalldhost_fuzzer/BUILD.gn @@ -83,7 +83,6 @@ ohos_fuzztest("BundleInstalldHostFuzzTest") { "ability_runtime:ability_manager", "ability_runtime:app_manager", "battery_manager:batterysrv_client", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "ffrt:libffrt", "power_manager:powermgr_client", @@ -107,6 +106,10 @@ ohos_fuzztest("BundleInstalldHostFuzzTest") { defines = [] include_dirs = [] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } if (code_signature_enable) { sources += [ "${services_path}/bundlemgr/src/aot/aot_sign_data_cache_mgr.cpp", diff --git a/test/fuzztest/fuzztest_application/bundleinstallerhost_fuzzer/BUILD.gn b/test/fuzztest/fuzztest_application/bundleinstallerhost_fuzzer/BUILD.gn index af7eeadab..bc34cf07e 100644 --- a/test/fuzztest/fuzztest_application/bundleinstallerhost_fuzzer/BUILD.gn +++ b/test/fuzztest/fuzztest_application/bundleinstallerhost_fuzzer/BUILD.gn @@ -83,7 +83,6 @@ ohos_fuzztest("BundleInstallerHostFuzzTest") { "ability_runtime:ability_manager", "ability_runtime:app_manager", "battery_manager:batterysrv_client", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "ffrt:libffrt", "power_manager:powermgr_client", @@ -107,6 +106,11 @@ ohos_fuzztest("BundleInstallerHostFuzzTest") { defines = [] include_dirs = [] + + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } if (code_signature_enable) { sources += [ "${services_path}/bundlemgr/src/aot/aot_sign_data_cache_mgr.cpp", diff --git a/test/fuzztest/fuzztest_others/aginghandlerchain_fuzzer/BUILD.gn b/test/fuzztest/fuzztest_others/aginghandlerchain_fuzzer/BUILD.gn index 89cc8bb97..ec0ef115a 100644 --- a/test/fuzztest/fuzztest_others/aginghandlerchain_fuzzer/BUILD.gn +++ b/test/fuzztest/fuzztest_others/aginghandlerchain_fuzzer/BUILD.gn @@ -68,7 +68,6 @@ ohos_fuzztest("AgingHandlerChainFuzzTest") { "battery_manager:batterysrv_client", "bounds_checking_function:libsec_shared", "common_event_service:cesfwk_innerkits", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "eventhandler:libeventhandler", "hilog:libhilog", @@ -82,6 +81,10 @@ ohos_fuzztest("AgingHandlerChainFuzzTest") { ] external_deps += bundle_install_external_deps defines = [ "BUNDLE_FRAMEWORK_FREE_INSTALL" ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } if (code_signature_enable) { sources += [ "${services_path}/bundlemgr/src/aot/aot_sign_data_cache_mgr.cpp", diff --git a/test/fuzztest/fuzztest_others/agingrequest_fuzzer/BUILD.gn b/test/fuzztest/fuzztest_others/agingrequest_fuzzer/BUILD.gn index efc72aba0..ac81ef329 100644 --- a/test/fuzztest/fuzztest_others/agingrequest_fuzzer/BUILD.gn +++ b/test/fuzztest/fuzztest_others/agingrequest_fuzzer/BUILD.gn @@ -67,7 +67,6 @@ ohos_fuzztest("AgingRequestFuzzTest") { "battery_manager:batterysrv_client", "bounds_checking_function:libsec_shared", "common_event_service:cesfwk_innerkits", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "eventhandler:libeventhandler", "hilog:libhilog", @@ -81,6 +80,10 @@ ohos_fuzztest("AgingRequestFuzzTest") { ] external_deps += bundle_install_external_deps defines = [ "BUNDLE_FRAMEWORK_FREE_INSTALL" ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } if (code_signature_enable) { sources += [ "${services_path}/bundlemgr/src/aot/aot_sign_data_cache_mgr.cpp", diff --git a/test/fuzztest/fuzztest_others/agingutil_fuzzer/BUILD.gn b/test/fuzztest/fuzztest_others/agingutil_fuzzer/BUILD.gn index 9d28041df..a89098c30 100644 --- a/test/fuzztest/fuzztest_others/agingutil_fuzzer/BUILD.gn +++ b/test/fuzztest/fuzztest_others/agingutil_fuzzer/BUILD.gn @@ -67,7 +67,6 @@ ohos_fuzztest("AgingUtilFuzzTest") { "battery_manager:batterysrv_client", "bounds_checking_function:libsec_shared", "common_event_service:cesfwk_innerkits", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "eventhandler:libeventhandler", "hilog:libhilog", @@ -81,6 +80,10 @@ ohos_fuzztest("AgingUtilFuzzTest") { ] external_deps += bundle_install_external_deps defines = [ "BUNDLE_FRAMEWORK_FREE_INSTALL" ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } if (code_signature_enable) { sources += [ "${services_path}/bundlemgr/src/aot/aot_sign_data_cache_mgr.cpp", diff --git a/test/fuzztest/fuzztest_others/bundleagingmgr_fuzzer/BUILD.gn b/test/fuzztest/fuzztest_others/bundleagingmgr_fuzzer/BUILD.gn index 1814f1a58..4a9187ba8 100644 --- a/test/fuzztest/fuzztest_others/bundleagingmgr_fuzzer/BUILD.gn +++ b/test/fuzztest/fuzztest_others/bundleagingmgr_fuzzer/BUILD.gn @@ -67,7 +67,6 @@ ohos_fuzztest("BundleAgingMgrFuzzTest") { "battery_manager:batterysrv_client", "bounds_checking_function:libsec_shared", "common_event_service:cesfwk_innerkits", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "eventhandler:libeventhandler", "hilog:libhilog", @@ -81,6 +80,10 @@ ohos_fuzztest("BundleAgingMgrFuzzTest") { ] external_deps += bundle_install_external_deps defines = [ "BUNDLE_FRAMEWORK_FREE_INSTALL" ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } if (code_signature_enable) { sources += [ "${services_path}/bundlemgr/src/aot/aot_sign_data_cache_mgr.cpp", diff --git a/test/fuzztest/fuzztest_others/bundleoverlayinstallchecker_fuzzer/BUILD.gn b/test/fuzztest/fuzztest_others/bundleoverlayinstallchecker_fuzzer/BUILD.gn index a036e0513..0a9d97fff 100644 --- a/test/fuzztest/fuzztest_others/bundleoverlayinstallchecker_fuzzer/BUILD.gn +++ b/test/fuzztest/fuzztest_others/bundleoverlayinstallchecker_fuzzer/BUILD.gn @@ -74,12 +74,15 @@ ohos_fuzztest("BundleOverlayInstallCheckerFuzzTest") { "ability_runtime:ability_manager", "ability_runtime:app_manager", "battery_manager:batterysrv_client", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "ffrt:libffrt", "power_manager:powermgr_client", "syscap_codec:syscap_interface_shared", ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } external_deps += bundle_install_external_deps diff --git a/test/fuzztest/fuzztest_others/bundleoverlaymgr_fuzzer/BUILD.gn b/test/fuzztest/fuzztest_others/bundleoverlaymgr_fuzzer/BUILD.gn index 7b9d72e63..9f8f40cc1 100644 --- a/test/fuzztest/fuzztest_others/bundleoverlaymgr_fuzzer/BUILD.gn +++ b/test/fuzztest/fuzztest_others/bundleoverlaymgr_fuzzer/BUILD.gn @@ -73,12 +73,15 @@ ohos_fuzztest("BundleOverlayMgrFuzzTest") { "ability_runtime:ability_manager", "ability_runtime:app_manager", "battery_manager:batterysrv_client", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "ffrt:libffrt", "power_manager:powermgr_client", "syscap_codec:syscap_interface_shared", ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } external_deps += bundle_install_external_deps diff --git a/test/fuzztest/fuzztest_others/overlaydatamgr_fuzzer/BUILD.gn b/test/fuzztest/fuzztest_others/overlaydatamgr_fuzzer/BUILD.gn index 78ce79547..adea4d1f1 100644 --- a/test/fuzztest/fuzztest_others/overlaydatamgr_fuzzer/BUILD.gn +++ b/test/fuzztest/fuzztest_others/overlaydatamgr_fuzzer/BUILD.gn @@ -73,12 +73,15 @@ ohos_fuzztest("OverlayDataMgrFuzzTest") { "ability_runtime:ability_manager", "ability_runtime:app_manager", "battery_manager:batterysrv_client", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "ffrt:libffrt", "power_manager:powermgr_client", "syscap_codec:syscap_interface_shared", ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } external_deps += bundle_install_external_deps diff --git a/test/fuzztest/fuzztest_others/overlaymgrhostimpl_fuzzer/BUILD.gn b/test/fuzztest/fuzztest_others/overlaymgrhostimpl_fuzzer/BUILD.gn index 69ac01f09..0f2b93428 100644 --- a/test/fuzztest/fuzztest_others/overlaymgrhostimpl_fuzzer/BUILD.gn +++ b/test/fuzztest/fuzztest_others/overlaymgrhostimpl_fuzzer/BUILD.gn @@ -74,12 +74,15 @@ ohos_fuzztest("OverlayMgrHostImplFuzzTest") { "ability_runtime:ability_manager", "ability_runtime:app_manager", "battery_manager:batterysrv_client", - "device_usage_statistics:usagestatsinner", "display_manager:displaymgr", "ffrt:libffrt", "power_manager:powermgr_client", "syscap_codec:syscap_interface_shared", ] + if (device_usage_statistics_enabled) { + external_deps += [ "device_usage_statistics:usagestatsinner" ] + defines += [ "DEVICE_USAGE_STATISTICS_ENABLED" ] + } external_deps += bundle_install_external_deps