1# Copyright (c) 2021-2022 Huawei Device Co., Ltd. 2# Licensed under the Apache License, Version 2.0 (the "License"); 3# you may not use this file except in compliance with the License. 4# You may obtain a copy of the License at 5# 6# http://www.apache.org/licenses/LICENSE-2.0 7# 8# Unless required by applicable law or agreed to in writing, software 9# distributed under the License is distributed on an "AS IS" BASIS, 10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 11# See the License for the specific language governing permissions and 12# limitations under the License. 13 14import("//build/ohos.gni") 15import("//build/ohos/sa_profile/sa_profile.gni") 16import("//foundation/filemanagement/storage_service/storage_service_aafwk.gni") 17 18config("storage_manager_config") { 19 include_dirs = [ 20 "include", 21 "../../interfaces/innerkits/storage_manager/native", 22 "//utils/system/safwk/native/include", 23 "//commonlibrary/c_utils/base/include", 24 "../storage_daemon/include", 25 "//foundation/filemanagement/storage_service/services/common/include", 26 "//foundation/bundlemanager/bundle_framework/services/bundlemgr/include", 27 "//foundation/multimedia/media_library/frameworks/utils/include", 28 "//foundation/multimedia/media_library/interfaces/inner_api/media_library_helper/include", 29 ] 30} 31 32ohos_shared_library("storage_manager") { 33 sources = [ 34 "account_subscriber/account_subscriber.cpp", 35 "crypto/filesystem_crypto.cpp", 36 "disk/src/disk_manager_service.cpp", 37 "ipc/src/storage_manager.cpp", 38 "ipc/src/storage_manager_stub.cpp", 39 "storage/src/storage_status_service.cpp", 40 "storage/src/storage_total_status_service.cpp", 41 "storage/src/volume_storage_status_service.cpp", 42 "storage_daemon_communication/src/storage_daemon_communication.cpp", 43 "user/src/multi_user_manager_service.cpp", 44 "volume/src/notification.cpp", 45 "volume/src/volume_manager_service.cpp", 46 ] 47 48 defines = [ 49 "STORAGE_LOG_TAG = \"StorageManager\"", 50 "LOG_DOMAIN = 0xD004300", 51 ] 52 53 configs = [ ":storage_manager_config" ] 54 55 deps = [ 56 "${ability_runtime_path}/frameworks/native/ability/native:abilitykit_native", 57 "${ability_runtime_path}/interfaces/inner_api/dataobs_manager:dataobs_manager", 58 "../../interfaces/innerkits/storage_manager/native:storage_manager_sa_proxy", 59 ] 60 61 if (storage_service_graphic) { 62 defines += [ "STORAGE_SERVICE_GRAPHIC" ] 63 deps += [ 64 "//foundation/multimedia/media_library/frameworks/innerkitsimpl/media_library_helper:media_library", 65 "//foundation/multimedia/media_library/frameworks/innerkitsimpl/media_library_manager:media_library_manager", 66 ] 67 } 68 69 external_deps = [ 70 "ability_base:base", 71 "ability_base:want", 72 "access_token:libaccesstoken_sdk", 73 "bundle_framework:appexecfwk_base", 74 "bundle_framework:appexecfwk_core", 75 "c_utils:utils", 76 "common_event_service:cesfwk_innerkits", 77 "data_share:datashare_consumer", 78 "hiviewdfx_hilog_native:libhilog", 79 "ipc:ipc_core", 80 "relational_store:native_rdb", 81 "safwk:system_ability_fwk", 82 "samgr:samgr_proxy", 83 ] 84 85 subsystem_name = "filemanagement" 86 part_name = "storage_service" 87 install_enable = true 88} 89