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/ohos.gni") 15import("fonts_config.gni") 16 17dep_list = [] 18 19foreach(font, fonts_list) { 20 font_name = font.font_name 21 ohos_prebuilt_etc(font_name) { 22 source = font.font_path 23 module_install_dir = "fonts" 24 subsystem_name = "thirdparty" 25 part_name = "noto-cjk" 26 } 27 dep_list += [ font_name ] 28} 29 30group("fonts_notocjk") { 31 deps = [] 32 foreach(dep, dep_list) { 33 deps += [ ":${dep}" ] 34 } 35} 36 37ohos_copy("copy_preview_fonts_notocjk") { 38 sources = [] 39 foreach(font, fonts_list) { 40 sources += [ font.font_path ] 41 } 42 outputs = 43 [ target_out_dir + "/previewer/common/bin/fonts/{{source_file_part}}" ] 44 module_source_dir = target_out_dir + "/previewer/common/bin/" 45 module_install_name = "" 46 subsystem_name = "thirdparty" 47 part_name = "noto-cjk" 48} 49