1# Copyright (c) 2021-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("//arkcompiler/runtime_core/static_core/ark_config.gni") 15import("//build/ohos.gni") 16 17config("arkziparchive_config") { 18 include_dirs = [ 19 "$ark_root/libziparchive", 20 "$ark_root/libpandabase", 21 ] 22} 23 24ohos_source_set("libarktsziparchive_static") { 25 sources = [ "zip_archive.cpp" ] 26 27 public_configs = [ 28 ":arkziparchive_config", 29 "$ark_root:ark_config", 30 "$ark_root/libpandabase:arkbase_public_config", 31 ] 32 33 if (ark_standalone_build) { 34 public_configs += [ zlib_public_config ] 35 } 36 37 deps = [ "$ark_root/libpandabase:libarktsbase" ] 38 39 external_deps = [ 40 sdk_libc_secshared_dep, 41 zlib_dep, 42 ] 43 44 part_name = ark_part_name 45 subsystem_name = "$ark_subsystem_name" 46} 47 48ohos_shared_library("libarktsziparchive") { 49 deps = [ ":libarktsziparchive_static" ] 50 51 if (!is_mingw && !is_mac) { 52 output_extension = "so" 53 } 54 part_name = ark_part_name 55 subsystem_name = "$ark_subsystem_name" 56} 57 58ohos_source_set("libarktsziparchive_frontend_set_static") { 59 sources = [ "zip_archive.cpp" ] 60 61 public_configs = [ 62 ":arkziparchive_config", 63 "$ark_root:ark_config", 64 "$ark_root/libpandabase:arkbase_public_config", 65 ] 66 67 if (ark_standalone_build) { 68 public_configs += [ zlib_public_config ] 69 } 70 71 deps = [ "$ark_root/libpandabase:logger_enum_gen_h" ] 72 73 external_deps = [ 74 sdk_libc_secshared_dep, 75 zlib_dep, 76 ] 77 78 part_name = ark_part_name 79 subsystem_name = "$ark_subsystem_name" 80} 81 82ohos_static_library("libarktsziparchive_frontend_static") { 83 deps = [ ":libarktsziparchive_frontend_set_static" ] 84 part_name = ark_part_name 85 subsystem_name = ark_subsystem_name 86} 87