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. 13import("//build/config/components/idl_tool/idl.gni") 14import("//build/ohos.gni") 15 16group("app_fwk_update") { 17 deps = [ 18 ":app_fwk_update_service", 19 ":app_fwk_update_service_cfg", 20 ":app_fwk_update_service_profile", 21 ] 22} 23 24config("web_sa_interface") { 25 include_dirs = [ 26 "include", 27 "${target_gen_dir}", 28 ] 29} 30 31idl_interface_sources = [ 32 "${target_gen_dir}/app_fwk_update_service_proxy.cpp", 33 "${target_gen_dir}/app_fwk_update_service_stub.cpp", 34] 35 36idl_gen_interface("app_fwk_update_service_interface") { 37 src_idl = rebase_path("IAppFwkUpdateService.idl") 38 dst_file = string_join(",", idl_interface_sources) 39} 40 41ohos_sa_profile("app_fwk_update_service_profile") { 42 sources = [ "8350.json" ] 43 part_name = "webview" 44} 45 46ohos_prebuilt_etc("app_fwk_update_service_cfg") { 47 source = "app_fwk_update_service.cfg" 48 relative_install_dir = "init" 49 subsystem_name = "web" 50 part_name = "webview" 51} 52 53ohos_shared_library("app_fwk_update_service") { 54 defines = [ "HILOG_TAG=\"app_fwk_update_service\"" ] 55 shlib_type = "sa" 56 version_script = "libapp_fwk_update_service.map" 57 output_values = get_target_outputs(":app_fwk_update_service_interface") 58 sources = [ 59 "../sa/include/app_fwk_update_service.h", 60 "../sa/src/app_fwk_update_client.cpp", 61 "../sa/src/app_fwk_update_load_callback.cpp", 62 "../sa/src/app_fwk_update_service.cpp", 63 ] 64 sources += filter_include(output_values, [ "*.cpp" ]) 65 deps = [ ":app_fwk_update_service_interface" ] 66 public_configs = [ ":web_sa_interface" ] 67 include_dirs = [ 68 "../sa/include", 69 "${target_gen_dir}/../ohos_nweb/include", 70 "../ohos_nweb/include", 71 "${target_gen_dir}", 72 ] 73 74 cflags = [ 75 "-Wall", 76 "-Werror", 77 "-g3", 78 ] 79 80 external_deps = [ 81 "ability_base:want", 82 "ability_base:zuri", 83 "ability_runtime:ability_manager", 84 "ability_runtime:napi_common", 85 "appspawn:appspawn_client", 86 "bundle_framework:appexecfwk_base", 87 "bundle_framework:appexecfwk_core", 88 "c_utils:utils", 89 "common_event_service:cesfwk_core", 90 "common_event_service:cesfwk_innerkits", 91 "eventhandler:libeventhandler", 92 "hilog:libhilog", 93 "hitrace:hitrace_meter", 94 "init:libbeget_proxy", 95 "init:libbegetutil", 96 "ipc:ipc_core", 97 "safwk:system_ability_fwk", 98 "samgr:samgr_proxy", 99 ] 100 101 #innerapi_tags = [ "platformsdk" ] 102 subsystem_name = "web" 103 part_name = "webview" 104} 105