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("../displaymgr.gni") 15 16config("displaymgr_private_config") { 17 include_dirs = [ "${displaymgr_inner_api}/native/include" ] 18} 19 20config("displaymgr_public_config") { 21 include_dirs = [ 22 "native/include", 23 "zidl/include", 24 ] 25} 26 27ohos_shared_library("displaymgrservice") { 28 sources = [ 29 "native/src/display_auto_brightness.cpp", 30 "native/src/display_param_helper.cpp", 31 "native/src/display_power_mgr_service.cpp", 32 "native/src/display_setting_helper.cpp", 33 "native/src/display_system_ability.cpp", 34 "native/src/gradual_animator.cpp", 35 "native/src/screen_action.cpp", 36 "native/src/screen_controller.cpp", 37 "zidl/src/display_power_callback_proxy.cpp", 38 "zidl/src/display_power_mgr_stub.cpp", 39 ] 40 41 configs = [ 42 "${displaymgr_utils_path}:utils_config", 43 ":displaymgr_private_config", 44 "${displaymgr_utils_path}:coverage_flags", 45 ] 46 47 public_configs = [ ":displaymgr_public_config" ] 48 49 external_deps = [ "power_manager:power_permission" ] 50 external_deps += [ 51 "ability_runtime:ability_manager", 52 "c_utils:utils", 53 "data_share:datashare_consumer", 54 "ffrt:libffrt", 55 "hicollie:libhicollie", 56 "hilog:libhilog", 57 "hisysevent:libhisysevent", 58 "image_framework:image_native", 59 "ipc:ipc_core", 60 "power_manager:power_ffrt", 61 "power_manager:power_setting", 62 "power_manager:power_sysparam", 63 "safwk:system_ability_fwk", 64 "sensor:sensor_interface_native", 65 "window_manager:libdm", 66 ] 67 68 shlib_type = "sa" 69 subsystem_name = "powermgr" 70 part_name = "${displaymgr_part_name}" 71} 72 73ohos_shared_library("displaymgr_stub") { 74 sources = [ "zidl/src/display_power_mgr_stub.cpp" ] 75 76 configs = [ 77 "${displaymgr_utils_path}:utils_config", 78 ":displaymgr_private_config", 79 "${displaymgr_utils_path}:coverage_flags", 80 ] 81 82 public_configs = [ ":displaymgr_public_config" ] 83 84 external_deps = [ 85 "c_utils:utils", 86 "hicollie:libhicollie", 87 "hilog:libhilog", 88 "ipc:ipc_core", 89 "power_manager:power_setting", 90 "safwk:system_ability_fwk", 91 ] 92 93 subsystem_name = "powermgr" 94 part_name = "${displaymgr_part_name}" 95} 96