1# Copyright (c) 2023 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") 15 16## Build setresolution {{{ 17config("setresolution_config") { 18 visibility = [ ":*" ] 19 include_dirs = [ "include" ] 20} 21 22ohos_executable("setresolution_screen") { 23 sources = [ "src/setresolution_screen.cpp" ] 24 25 if (build_variant == "root") { 26 install_enable = true 27 } else { 28 install_enable = false 29 } 30 31 configs = [ 32 ":setresolution_config", 33 "../resources/config/build:coverage_flags", 34 ] 35 36 deps = [ 37 ":libsetresolution_util", 38 "../dm:libdm", 39 ] 40 41 external_deps = [ 42 "c_utils:utils", 43 "graphic_surface:surface", 44 "init:libbegetutil", 45 ] 46 47 part_name = "window_manager" 48 subsystem_name = "window" 49} 50 51ohos_shared_library("libsetresolution_util") { 52 sources = [ "src/setresolution_utils.cpp" ] 53 54 configs = [ 55 ":setresolution_config", 56 "../resources/config/build:coverage_flags", 57 ] 58 59 deps = [ "../dm:libdm" ] 60 61 external_deps = [ 62 "c_utils:utils", 63 "hitrace:hitrace_meter", 64 ] 65 66 part_name = "window_manager" 67 subsystem_name = "window" 68} 69## Build setresolution }}} 70