# Copyright (C) 2024 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. import("//build/ohos.gni") import("//foundation/multimedia/ringtone_library/ringtone_library.gni") ohos_hap("ringtone_extension_hap") { hap_profile = "RingtoneLibraryExt/entry/src/main/module.json" deps = [ ":RingtoneLibStage_js_assets", ":RingtoneLibStage_resources", ] publicity_file = "${RINGTONE_ROOT_PATH}/publicity.xml" certificate_profile = "${RINGTONE_EXT_HAP_PATH}/signature/ringtonelibrary.p7b" shared_libraries = [ "${RINGTONE_SERVICES_PATH}:ringtone_data_extension" ] hap_name = "Ringtone_Library_Ext" part_name = "prebuilt_hap" subsystem_name = "applications" module_install_dir = "app/Ringtone_Library_Ext" if (defined(sign_hap_py_path)) { certificate_profile = "${RINGTONE_EXT_HAP_PATH}/signature/ringtonelibrary_new.p7b" key_alias = "ringtonelibrarydata" private_key_path = "ringtonelibrarydata" compatible_version = "12" } } ohos_js_assets("RingtoneLibStage_js_assets") { hap_profile = "RingtoneLibraryExt/entry/src/main/module.json" ets2abc = true source_dir = "RingtoneLibraryExt/entry/src/main/ets" } ohos_app_scope("RingtoneLibStage_app_profile") { app_profile = "RingtoneLibraryExt/AppScope/app.json" sources = [ "RingtoneLibraryExt/AppScope/resources" ] } ohos_resources("RingtoneLibStage_resources") { hap_profile = "RingtoneLibraryExt/entry/src/main/module.json" deps = [ ":RingtoneLibStage_app_profile" ] sources = [ "RingtoneLibraryExt/entry/src/main/resources" ] }