1# Copyright (c) 2021 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("//foundation/graphic/graphic_surface/graphic_surface_config.gni") 16 17## buffer_handle.so {{{ 18config("buffer_handle_config") { 19 visibility = [ ":buffer_handle", ":buffer_handle_static" ] 20 21 cflags = [ 22 "-Wall", 23 "-Werror", 24 "-g3", 25 "-Wno-error=missing-braces", 26 "-Wno-error=#warnings", 27 ] 28} 29 30config("buffer_handle_public_config") { 31 include_dirs = [ "$graphic_surface_root/interfaces/inner_api/utils" ] 32} 33 34ohos_shared_library("buffer_handle") { 35 deps = [ ":buffer_handle_static" ] 36 sanitize = { 37 boundary_sanitize = true 38 integer_overflow = true 39 ubsan = true 40 } 41 42 public_configs = [ ":buffer_handle_public_config" ] 43 44 external_deps = [ 45 "c_utils:utils", 46 "hilog:libhilog", 47 "ipc:ipc_single", 48 ] 49 50 innerapi_tags = [ 51 "chipsetsdk_sp", 52 "platformsdk", 53 ] 54 subsystem_name = "graphic" 55 part_name = "graphic_surface" 56} 57 58ohos_static_library("buffer_handle_static") { 59 sources = [ "src/buffer_handle.cpp" ] 60 61 configs = [ ":buffer_handle_config" ] 62 63 public_configs = [ ":buffer_handle_public_config" ] 64 65 external_deps = [ 66 "c_utils:utils", 67 "hilog:libhilog", 68 "ipc:ipc_single", 69 ] 70 71 subsystem_name = "graphic" 72 part_name = "graphic_surface" 73} 74## buffer_handle.so }}} 75