1# Copyright (c) 2024 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/test.gni")
15import("//foundation/graphic/graphic_2d/graphic_config.gni")
16
17ohos_shared_library("libdrawing_demo") {
18  sanitize = {
19    cfi = true
20    cfi_cross_dso = true
21    debug = false
22  }
23
24  sources = [
25    "drawing_demo.cpp",
26    "test_case/draw_path_test.cpp",
27    "test_case/draw_rect_test.cpp",
28    "test_case/draw_textblob_test.cpp",
29    "test_case/test_base.cpp",
30    "test_case/test_common.cpp",
31    "test_case_factory.cpp",
32  ]
33
34  deps = [
35    "../../../../rosen/modules/2d_graphics:2d_graphics",
36    "../../../../rosen/modules/render_service_base:librender_service_base",
37    "../../../../rosen/modules/render_service_client:librender_service_client",
38  ]
39
40  public_external_deps = [ "window_manager:libwm" ]
41  external_deps = [
42    "access_token:libaccesstoken_sdk",
43    "access_token:libnativetoken",
44    "access_token:libtoken_setproc",
45    "c_utils:utils",
46    "hilog:libhilog",
47    "image_framework:image_native",
48    "window_manager:libdm",
49  ]
50
51  part_name = "graphic_2d"
52  subsystem_name = "graphic"
53}
54
55ohos_executable("drawing_demo") {
56  sanitize = {
57    cfi = true
58    cfi_cross_dso = true
59    debug = false
60  }
61  deps = [ ":libdrawing_demo" ]
62  part_name = "graphic_2d"
63  subsystem_name = "graphic"
64}
65