• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 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("//base/print/print_fwk/print.gni")
15import("//build/ohos.gni")
16
17cflags_cc = []
18
19config("print_service_config") {
20  visibility = [ ":*" ]
21  include_dirs = [
22    "include",
23    "${print_path}/frameworks/models/print_models/include",
24  ]
25
26  cflags_cc += [ "-fno-exceptions" ]
27}
28
29ohos_shared_library("print_service") {
30  sources = [
31    "src/hisys_event_util.cpp",
32    "src/print_bms_death_recipient.cpp",
33    "src/print_bms_helper.cpp",
34    "src/print_callback_proxy.cpp",
35    "src/print_extension_callback_proxy.cpp",
36    "src/print_security_guard_info.cpp",
37    "src/print_security_guard_manager.cpp",
38    "src/print_service_ability.cpp",
39    "src/print_service_helper.cpp",
40    "src/print_service_stub.cpp",
41  ]
42
43  public_configs = [
44    "${c_utils_path}/base:utils_config",
45    ":print_service_config",
46  ]
47  include_dirs = [
48    "${print_path}/frameworks/innerkitsimpl/print_impl/include",
49    "${print_utils_path}/include",
50  ]
51  deps = [ "${print_path}/frameworks/models/print_models:print_models" ]
52
53  if (cups_enable) {
54    include_dirs += [ "//third_party/cups/cups-2.4.0" ]
55    sources += [ "src/print_cups_client.cpp" ]
56    cflags_cc += [ "-DCUPS_ENABLE" ]
57    deps += [
58      "//third_party/cups:third_party_cups",
59      "//third_party/cups-filters:third_party_cupsfilters",
60    ]
61  }
62
63  external_deps = [
64    "ability_base:base",
65    "ability_base:want",
66    "ability_base:zuri",
67    "ability_runtime:ability_manager",
68    "ability_runtime:abilitykit_native",
69    "access_token:libaccesstoken_sdk",
70    "bundle_framework:appexecfwk_base",
71    "bundle_framework:appexecfwk_core",
72    "c_utils:utils",
73    "common_event_service:cesfwk_innerkits",
74    "core_service:tel_core_service_api",
75    "distributed_notification_service:ans_innerkits",
76    "eventhandler:libeventhandler",
77    "hilog:libhilog",
78    "hisysevent:libhisysevent",
79    "hitrace:hitrace_meter",
80    "init:libbegetutil",
81    "ipc:ipc_core",
82    "napi:ace_napi",
83    "netmanager_base:net_conn_manager_if",
84    "os_account:os_account_innerkits",
85    "relational_store:native_rdb",
86    "safwk:system_ability_fwk",
87    "samgr:samgr_proxy",
88    "wifi:wifi_sdk",
89  ]
90
91  if (security_guard_enabled) {
92    external_deps += [
93      "security_guard:libsg_collect_sdk",
94      "time_service:time_client",
95    ]
96
97    cflags_cc += [ "-DSECURITY_GUARDE_ENABLE" ]
98  }
99
100  subsystem_name = "print"
101  part_name = "print_fwk"
102}
103