diff --git a/arkui/ace_ets_xcomponent/BUILD.gn b/arkui/ace_ets_xcomponent/BUILD.gn index 6d2bd32f8de7997663fc00da2b423844f6e940dd..f6f39b1148f290da6c96f332a31030d24b4aac68 100644 --- a/arkui/ace_ets_xcomponent/BUILD.gn +++ b/arkui/ace_ets_xcomponent/BUILD.gn @@ -11,6 +11,7 @@ # See the License for the specific language governing permissions and # limitations under the License. +import("//build/config/ohos/config.gni") import("//build/ohos.gni") import("//test/xts/tools/build/suite.gni") @@ -31,13 +32,7 @@ ohos_js_hap_suite("ActsAceXComponentEtsTest") { } ohos_prebuilt_shared_library("libcppsharedso") { - if (target_cpu == "arm") { - source = "//prebuilts/clang/ohos/linux-x86_64/libcxx-ndk/lib/arm-linux-ohos/c++/libc++_shared.so" - } else if (target_cpu == "arm64") { - source = "//prebuilts/clang/ohos/linux-x86_64/libcxx-ndk/lib/aarch64-linux-ohos/c++/libc++_shared.so" - } else { - source = " " - } + source = rebase_path(libcxx_ndk_shared_file) } ohos_js_assets("ace_ets_xcomponent_assets") { diff --git a/arkui/ace_napi_test/entry/src/main/cpp/BUILD.gn b/arkui/ace_napi_test/entry/src/main/cpp/BUILD.gn index 22b5e758da95e7e5027f4b76e9a8e2c72e592a9a..23c0887abe45391ab379779bf5bf3b3406392a80 100644 --- a/arkui/ace_napi_test/entry/src/main/cpp/BUILD.gn +++ b/arkui/ace_napi_test/entry/src/main/cpp/BUILD.gn @@ -32,13 +32,7 @@ config("public_config") { ohos_shared_library("napitest") { sources = [ "./napi/napi_test.cpp" ] if (!(product_name == "m40")) { - if (target_cpu == "arm") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/arm-linux-ohos/c++/libc++_shared.so" ] - } else if (target_cpu == "arm64") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/aarch64-linux-ohos/c++/libc++_shared.so" ] - } else { - libs = [] - } + libs = [ rebase_path(libcxx_ndk_shared_file) ] } include_dirs = [ "//test/xts/acts/arkui/ace_napi_test/entry/src/main/cpp" ] diff --git a/bundlemanager/bundle_standard/bundlemanager/actsbundlenativetest/BUILD.gn b/bundlemanager/bundle_standard/bundlemanager/actsbundlenativetest/BUILD.gn index 257ef6d591b1c88b4faafead0d8d942ca47e66c4..3effa95eb3ca05ca79973f277d717a7adb6d8eb2 100755 --- a/bundlemanager/bundle_standard/bundlemanager/actsbundlenativetest/BUILD.gn +++ b/bundlemanager/bundle_standard/bundlemanager/actsbundlenativetest/BUILD.gn @@ -32,7 +32,7 @@ ohos_js_hap_suite("ActsBundleNativeTest") { } ohos_prebuilt_shared_library("libcppsharedso") { - source = "//prebuilts/clang/ohos/linux-x86_64/libcxx-ndk/lib/arm-linux-ohos/c++/libc++_shared.so" + source = rebase_path(libcxx_ndk_shared_file) } ohos_js_assets("ace_third_ets_assets") { diff --git a/bundlemanager/bundle_standard/bundlemanager/actsbundlenativetest/entry/src/main/cpp/BUILD.gn b/bundlemanager/bundle_standard/bundlemanager/actsbundlenativetest/entry/src/main/cpp/BUILD.gn index 1c447db6e20116336cac57cff58190eea576a596..f9fb5be2f44648192648149e213f47ad715ba895 100755 --- a/bundlemanager/bundle_standard/bundlemanager/actsbundlenativetest/entry/src/main/cpp/BUILD.gn +++ b/bundlemanager/bundle_standard/bundlemanager/actsbundlenativetest/entry/src/main/cpp/BUILD.gn @@ -31,13 +31,7 @@ config("public_config") { ohos_shared_library("bundlendk") { sources = [ "./bundlendk.cpp" ] if (!(product_name == "m40")) { - if (target_cpu == "arm") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/arm-linux-ohos/c++/libc++_shared.so" ] - } else if (target_cpu == "arm64") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/aarch64-linux-ohos/c++/libc++_shared.so" ] - } else { - libs = [] - } + libs = [ rebase_path(libcxx_ndk_shared_file) ] } include_dirs = [ "//test/xts/acts/bundlemanager/bundle_standard/bundlemanager/actsbundlenativetest/entry/src/main/cpp" ] diff --git a/global/global_napi_test/entry/src/main/cpp/BUILD.gn b/global/global_napi_test/entry/src/main/cpp/BUILD.gn index dbfd33a2c8d5bec11ae10a3265edc20ff6f9a8e9..597a6214da7a883e4e3260ed9e5fa3288a6a58b8 100644 --- a/global/global_napi_test/entry/src/main/cpp/BUILD.gn +++ b/global/global_napi_test/entry/src/main/cpp/BUILD.gn @@ -31,13 +31,8 @@ config("public_config") { ohos_shared_library("resmgrndk") { sources = [ "./napi/global_napi_test.cpp" ] - if (target_cpu == "arm") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/arm-linux-ohos/c++/libc++_shared.so" ] - } else if (target_cpu == "arm64") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/aarch64-linux-ohos/c++/libc++_shared.so" ] - } else { - libs = [] - } + libs = [ rebase_path(libcxx_ndk_shared_file) ] + include_dirs = [ "//base/global/resource_management/interfaces/native/resource/include", "//test/xts/acts/arkui/ace_napi_test/entry/src/main/cpp", diff --git a/hiviewdfx/hilogtest/hilogjstest/src/main/cpp/BUILD.gn b/hiviewdfx/hilogtest/hilogjstest/src/main/cpp/BUILD.gn index 410cf985df1e043b795a302af55db6f0465f1a5a..ea57de2412aac6140a5d24440e9d02ef144f52b2 100644 --- a/hiviewdfx/hilogtest/hilogjstest/src/main/cpp/BUILD.gn +++ b/hiviewdfx/hilogtest/hilogjstest/src/main/cpp/BUILD.gn @@ -32,13 +32,7 @@ config("public_config") { ohos_shared_library("hilogndk") { sources = [ "./hilogndk.cpp" ] if (!(product_name == "m40")) { - if (target_cpu == "arm") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/arm-linux-ohos/c++/libc++_shared.so" ] - } else if (target_cpu == "arm64") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/aarch64-linux-ohos/c++/libc++_shared.so" ] - } else { - libs = [] - } + libs = [ rebase_path(libcxx_ndk_shared_file) ] } include_dirs = [ diff --git a/multimedia/image/image_js_standard/imagePixelMapNDK/entry/src/main/cpp/BUILD.gn b/multimedia/image/image_js_standard/imagePixelMapNDK/entry/src/main/cpp/BUILD.gn index d08908f961c7397a8cda7fe041979ad855f06e1c..f64b9b4faa49d7e4d299ff12850f635583743b70 100644 --- a/multimedia/image/image_js_standard/imagePixelMapNDK/entry/src/main/cpp/BUILD.gn +++ b/multimedia/image/image_js_standard/imagePixelMapNDK/entry/src/main/cpp/BUILD.gn @@ -28,13 +28,8 @@ config("config") { ohos_shared_library("ImagePixelMapNDKTest") { sources = [ "./napi/image_pixel_map_imgndk_test.cpp" ] - if (target_cpu == "arm") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/arm-linux-ohos/c++/libc++_shared.so" ] - } else if (target_cpu == "arm64") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/aarch64-linux-ohos/c++/libc++_shared.so" ] - } else { - libs = [] - } + libs = [ rebase_path(libcxx_ndk_shared_file) ] + include_dirs = [ "../cpp" ] configs = [ ":config" ] diff --git a/multimedia/image/image_js_standard/imageReceiverNDK/entry/src/main/cpp/BUILD.gn b/multimedia/image/image_js_standard/imageReceiverNDK/entry/src/main/cpp/BUILD.gn index 9d6c3f9d62b124de5fe8428b34dd9742db39db6c..26a484f2449058c893b1ed74f0d4e597c83176fd 100644 --- a/multimedia/image/image_js_standard/imageReceiverNDK/entry/src/main/cpp/BUILD.gn +++ b/multimedia/image/image_js_standard/imageReceiverNDK/entry/src/main/cpp/BUILD.gn @@ -28,13 +28,8 @@ config("config") { ohos_shared_library("ImageReceiverNDKTest") { sources = [ "./napi/image_receiver_mdk_test.cpp" ] - if (target_cpu == "arm") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/arm-linux-ohos/c++/libc++_shared.so" ] - } else if (target_cpu == "arm64") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/aarch64-linux-ohos/c++/libc++_shared.so" ] - } else { - libs = [] - } + libs = [ rebase_path(libcxx_ndk_shared_file) ] + include_dirs = [ "../cpp" ] configs = [ ":config" ] diff --git a/multimedia/image/image_js_standard/image_ndk_test/entry/src/main/cpp/BUILD.gn b/multimedia/image/image_js_standard/image_ndk_test/entry/src/main/cpp/BUILD.gn index aff4d0ff8cb08a0393be924e0764967a0665529a..9c058cf720e448e188bea6d90a35f849a1063dce 100644 --- a/multimedia/image/image_js_standard/image_ndk_test/entry/src/main/cpp/BUILD.gn +++ b/multimedia/image/image_js_standard/image_ndk_test/entry/src/main/cpp/BUILD.gn @@ -32,13 +32,7 @@ config("public_config") { ohos_shared_library("imagePixelmap") { sources = [ "./napi/imagePixelmap.cpp" ] if (use_musl) { - if (target_cpu == "arm") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/arm-linux-ohos/c++/libc++_shared.so" ] - } else if (target_cpu == "arm64") { - libs = [ "${clang_base_path}/../libcxx-ndk/lib/aarch64-linux-ohos/c++/libc++_shared.so" ] - } else { - libs = [] - } + libs = [ rebase_path(libcxx_ndk_shared_file) ] } include_dirs = [ "//test/xts/acts/multimedia/image/image_js_standard/image_ndk_test/entry/src/main/cpp" ] configs = [ ":config" ]