window_window_manager/dm/BUILD.gn
lpf 37d93946ed 部件依赖
Signed-off-by: lpf <liaopengfei@h-partners.com>
2024-10-29 21:29:18 +08:00

203 lines
5.0 KiB
Plaintext

# Copyright (c) 2021-2022 Huawei Device Co., Ltd.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import("//build/ohos.gni")
import("../windowmanager_aafwk.gni")
config("libdm_private_config") {
include_dirs = [
"include",
"../dmserver/include",
"${window_base_path}/interfaces/innerkits/wm",
"${window_base_path}/window_scene",
"${window_base_path}/window_scene/screen_session_manager/include",
"${window_base_path}/window_scene/screen_session_manager_client/include",
"${window_base_path}/window_scene/session_manager/include",
"${window_base_path}/window_scene/session_manager_service/include",
"${window_base_path}/window_scene/interfaces/innerkits/include",
]
}
config("libdm_public_config") {
include_dirs = [
"../interfaces/innerkits",
"../interfaces/innerkits/dm",
"../utils/include",
]
}
config("for_libdm_public_config") {
include_dirs =
[ "../../../multimedia/image_framework/interfaces/innerkits/include" ]
}
## Build libdm_static.a
ohos_static_library("libdm_static") {
branch_protector_ret = "pac_ret"
sanitize = {
cfi = true
cfi_cross_dso = true
cfi_vcall_icall_only = true
debug = false
integer_overflow = true
ubsan = true
boundary_sanitize = true
}
sources = [
"../dmserver/src/display_manager_proxy.cpp",
"../window_scene/screen_session_manager/src/zidl/screen_session_manager_proxy.cpp",
"src/display.cpp",
"src/display_manager.cpp",
"src/display_manager_adapter.cpp",
"src/screen.cpp",
"src/screen_group.cpp",
"src/screen_manager.cpp",
"src/zidl/display_manager_agent_stub.cpp",
]
configs = [
":libdm_private_config",
"${window_base_path}/resources/config/build:coverage_flags",
]
public_configs = [ ":libdm_public_config" ]
deps = [
"${window_base_path}/utils:libwmutil",
"${window_base_path}/utils:libwmutil_base",
"${window_base_path}/window_scene/interfaces/innerkits:libwsutils",
]
public_external_deps = [
"graphic_2d:color_manager",
"image_framework:image_native",
]
external_deps = [
"ability_runtime:ability_manager",
"c_utils:utils",
"graphic_2d:librender_service_client",
"hilog:libhilog",
"image_framework:image_native",
"ipc:ipc_single",
"samgr:samgr_proxy",
]
part_name = "window_manager"
subsystem_name = "window"
}
## Build libdm.so
ohos_shared_library("libdm") {
branch_protector_ret = "pac_ret"
sources = [
"../dmserver/src/display_manager_proxy.cpp",
"../window_scene/screen_session_manager/src/zidl/screen_session_manager_proxy.cpp",
"src/display.cpp",
"src/display_manager.cpp",
"src/display_manager_adapter.cpp",
"src/screen.cpp",
"src/screen_group.cpp",
"src/screen_manager.cpp",
"src/zidl/display_manager_agent_stub.cpp",
]
configs = [
":libdm_private_config",
"../resources/config/build:coverage_flags",
]
public_configs = [
":for_libdm_public_config",
":libdm_public_config",
]
deps = [
"${window_base_path}/utils:libwmutil",
"${window_base_path}/utils:libwmutil_base",
"${window_base_path}/window_scene/interfaces/innerkits:libwsutils",
]
public_external_deps = [ "graphic_2d:color_manager" ]
external_deps = [
"ability_runtime:ability_manager",
"c_utils:utils",
"graphic_2d:librender_service_base",
"graphic_2d:librender_service_client",
"hilog:libhilog",
"image_framework:image_native",
"ipc:ipc_single",
"samgr:samgr_proxy",
]
innerapi_tags = [ "platformsdk" ]
part_name = "window_manager"
subsystem_name = "window"
defines = []
if (build_variant == "user") {
defines += [ "IS_RELEASE_VERSION" ]
}
}
group("test") {
testonly = true
deps = [ "test:test" ]
}
## Build libdm_ndk.so
config("libdm_ndk_public_config") {
include_dirs = [ "../interfaces/kits/dmndk/dm" ]
}
ohos_shared_library("libdm_ndk") {
branch_protector_ret = "pac_ret"
output_name = "libnative_display_manager"
output_extension = "so"
sanitize = {
cfi = true
cfi_cross_dso = true
cfi_vcall_icall_only = true
debug = false
}
public_configs = [ ":libdm_ndk_public_config" ]
include_dirs = [
".",
"${window_base_path}/interfaces/kits/dmndk/dm",
"${window_base_path}/interfaces/inner_kits/dm",
]
sources = [ "src/oh_display_manager.cpp" ]
deps = [
":libdm",
"${window_base_path}/utils:libwmutil_base",
]
innerapi_tags = [ "ndk" ]
external_deps = [
"c_utils:utils",
"hilog:libhilog",
"image_framework:pixelmap",
"ipc:ipc_core",
]
part_name = "window_manager"
subsystem_name = "window"
}