diff --git a/ohos/ndk/BUILD.gn b/ohos/ndk/BUILD.gn index 11d04ac901408759d5a0755e26d45054c1fbb210..70a02d9ada64aada895a50249bf4904303dbe3bc 100755 --- a/ohos/ndk/BUILD.gn +++ b/ohos/ndk/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. +# Copyright (c) 2021-2025 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 @@ -71,8 +71,25 @@ if (!use_current_sdk) { } } + action_with_pydeps("_clean_ndk_ani") { + deps = [ ":_collect_ndk_syscap" ] + script = "//interface/sdk_c/build-tools/clean_ndk_ani.py" + outputs = [ "${ndk_os_irrelevant_out_dir}/clean_ndk_ani.json" ] + _native_syscap_config_file = + "${ndk_os_irrelevant_out_dir}/nativeapi_syscap_config.json" + args = [ + "--ndk-header-path", + rebase_path("$ndk_headers_out_dir", root_build_dir), + "--system-capability-header-config", + rebase_path(_native_syscap_config_file, root_build_dir), + ] + } + group("all_ndk_targets") { deps = [ ":_collect_ndk_syscap" ] + if (!sdk_build_arkts) { + deps += [ ":_clean_ndk_ani" ] + } } group("ndk_notice") {