diff --git a/cj_environment/frameworks/cj_environment/BUILD.gn b/cj_environment/frameworks/cj_environment/BUILD.gn index ae470d06c3c0aeef8eaadf7112634bd4b4fbc7e4..441ff5d749c18a110f0a64e0d673c1b607853c79 100644 --- a/cj_environment/frameworks/cj_environment/BUILD.gn +++ b/cj_environment/frameworks/cj_environment/BUILD.gn @@ -24,6 +24,8 @@ config("cj_rt_public_config") { if (target_cpu == "arm64") { defines += [ "_ARM64_" ] + } else if (target_cpu == "loongarch64") { + defines += [ "_LOONGARCH64_" ] } if (target_cpu == "arm64") { @@ -32,6 +34,8 @@ config("cj_rt_public_config") { defines += [ "APP_USE_ARM" ] } else if (target_cpu == "x86_64") { defines += [ "APP_USE_X86_64" ] + } else if (target_cpu == "loongarch64") { + defines += [ "APP_USE_LOONGARCH64" ] } } diff --git a/cj_environment/frameworks/cj_environment/src/cj_environment.cpp b/cj_environment/frameworks/cj_environment/src/cj_environment.cpp index caf5290aeebcea335ba7d5c8555cb2dc0dbcc597..5098156a364ebb7b42ff7f50ac879eead1b5b615 100644 --- a/cj_environment/frameworks/cj_environment/src/cj_environment.cpp +++ b/cj_environment/frameworks/cj_environment/src/cj_environment.cpp @@ -34,6 +34,8 @@ #define APP_LIB_NAME "arm" #elif defined(APP_USE_X86_64) #define APP_LIB_NAME "x86_64" +#elif defined(APP_USE_LOONGARCH64) +#define APP_LIB_NAME "loongarch64" #elif defined(NAPI_TARGET_ARM64) #define APP_LIB_NAME "arm64" #else diff --git a/frameworks/native/ability/native/BUILD.gn b/frameworks/native/ability/native/BUILD.gn index 1b0733865e75307b4d9ffbdd0bf0f165091e2439..e91c4da07f4dcee9c8b7156d85ca37fa74db7c99 100644 --- a/frameworks/native/ability/native/BUILD.gn +++ b/frameworks/native/ability/native/BUILD.gn @@ -51,6 +51,8 @@ config("ability_config") { defines += [ "AMS_LOG_DOMAIN = 0xD001300" ] if (target_cpu == "arm64") { defines += [ "_ARM64_" ] + } else if (target_cpu == "loongarch64") { + defines += [ "_LOONGARCH64_" ] } if (target_cpu == "arm64") { @@ -59,6 +61,8 @@ config("ability_config") { defines += [ "APP_USE_ARM" ] } else if (target_cpu == "x86_64") { defines += [ "APP_USE_X86_64" ] + } else if (target_cpu == "loongarch64") { + defines += [ "APP_USE_LOONGARCH64" ] } if (ability_runtime_graphics) { @@ -2012,6 +2016,8 @@ config("embedded_ui_extension_module_config") { defines += [ "AMS_LOG_DOMAIN = 0xD001300" ] if (target_cpu == "arm64") { defines += [ "_ARM64_" ] + } else if (target_cpu == "loongarch64") { + defines += [ "_LOONGARCH64_" ] } if (target_cpu == "arm64") { @@ -2020,6 +2026,8 @@ config("embedded_ui_extension_module_config") { defines += [ "APP_USE_ARM" ] } else if (target_cpu == "x86_64") { defines += [ "APP_USE_X86_64" ] + } else if (target_cpu == "loongarch64") { + defines += [ "APP_USE_LOONGARCH64" ] } if (ability_runtime_graphics) { diff --git a/frameworks/native/appkit/BUILD.gn b/frameworks/native/appkit/BUILD.gn index 4f9daaa22d4d043f002ef6809b0ba95c87162a97..1b9625bb119c279293a08d4e54d7e6d3217c01ab 100644 --- a/frameworks/native/appkit/BUILD.gn +++ b/frameworks/native/appkit/BUILD.gn @@ -35,6 +35,8 @@ config("appkit_config") { defines += [ "AMS_LOG_DOMAIN = 0xD001305" ] if (target_cpu == "arm64") { defines += [ "_ARM64_" ] + } else if (target_cpu == "loongarch64") { + defines += [ "_LOONGARCH64_" ] } if (target_cpu == "arm64") { defines += [ "APP_USE_ARM64" ] @@ -42,6 +44,8 @@ config("appkit_config") { defines += [ "APP_USE_ARM" ] } else if (target_cpu == "x86_64") { defines += [ "APP_USE_X86_64" ] + } else if (target_cpu == "loongarch64") { + defines += [ "APP_USE_LOONGARCH64" ] } include_dirs = [ diff --git a/frameworks/native/appkit/app/extension_plugin_info.cpp b/frameworks/native/appkit/app/extension_plugin_info.cpp index fe51add2cc64b1cd840ee7cabbc67ffb2a73281c..99f2248218ab85502fdc38cd3baceaa61372d2d8 100755 --- a/frameworks/native/appkit/app/extension_plugin_info.cpp +++ b/frameworks/native/appkit/app/extension_plugin_info.cpp @@ -25,9 +25,7 @@ namespace OHOS { namespace AbilityRuntime { -#ifdef APP_USE_ARM64 -const std::string EXTENSION_LIB = "system/lib64/extensionability"; -#elif defined(APP_USE_X86_64) +#if defined(APP_USE_ARM64) || defined(APP_USE_X86_64) || defined(APP_USE_LOONGARCH64) const std::string EXTENSION_LIB = "system/lib64/extensionability"; #else const std::string EXTENSION_LIB = "system/lib/extensionability"; diff --git a/interfaces/inner_api/connect_server_manager/BUILD.gn b/interfaces/inner_api/connect_server_manager/BUILD.gn index c2c684462c3aa841d1cc7b8b242102147ddd9f05..18d11f3416aee82d9b008b491c3cdc7106582c2d 100644 --- a/interfaces/inner_api/connect_server_manager/BUILD.gn +++ b/interfaces/inner_api/connect_server_manager/BUILD.gn @@ -20,6 +20,8 @@ config("connect_server_manager_config") { defines = [] if (target_cpu == "arm64") { defines += [ "_ARM64_" ] + } else if (target_cpu == "loongarch64") { + defines += [ "_LOONGARCH64_" ] } if (target_cpu == "arm64") { @@ -28,6 +30,8 @@ config("connect_server_manager_config") { defines += [ "APP_USE_ARM" ] } else if (target_cpu == "x86_64") { defines += [ "APP_USE_X86_64" ] + } else if (target_cpu == "loongarch64") { + defines += [ "APP_USE_LOONGARCH64" ] } } diff --git a/interfaces/inner_api/runtime/BUILD.gn b/interfaces/inner_api/runtime/BUILD.gn index faec0e820c85b56000f1aafce36ea3841c2c46c0..14be7c15ca0097f165d2645530cfa7a2e278af56 100644 --- a/interfaces/inner_api/runtime/BUILD.gn +++ b/interfaces/inner_api/runtime/BUILD.gn @@ -22,6 +22,8 @@ config("runtime_config") { if (target_cpu == "arm64") { defines += [ "_ARM64_" ] + } else if (target_cpu == "loongarch64") { + defines += [ "_LOONGARCH64_" ] } if (target_cpu == "arm64") { @@ -30,6 +32,8 @@ config("runtime_config") { defines += [ "APP_USE_ARM" ] } else if (target_cpu == "x86_64") { defines += [ "APP_USE_X86_64" ] + } else if (target_cpu == "loongarch64") { + defines += [ "APP_USE_LOONGARCH64" ] } include_dirs = [] diff --git a/test/unittest/continuation_test/remote_register_service_test/continuation_register_manager_proxy_test/BUILD.gn b/test/unittest/continuation_test/remote_register_service_test/continuation_register_manager_proxy_test/BUILD.gn index 97e8ed29efb9abcb228e50368c77d55f8006fb8f..81488c392d9d9fa1f7ea0f0c8e5201e6c230be29 100644 --- a/test/unittest/continuation_test/remote_register_service_test/continuation_register_manager_proxy_test/BUILD.gn +++ b/test/unittest/continuation_test/remote_register_service_test/continuation_register_manager_proxy_test/BUILD.gn @@ -56,6 +56,8 @@ config("ability_config") { defines = [ "AMS_LOG_TAG = \"Ability\"" ] if (target_cpu == "arm64") { defines += [ "_ARM64_" ] + } else if (target_cpu == "loongarch64") { + defines += [ "_LOONGARCH64_" ] } if (ability_runtime_graphics) { diff --git a/test/unittest/continuation_test/remote_register_service_test/continuation_register_manager_test/BUILD.gn b/test/unittest/continuation_test/remote_register_service_test/continuation_register_manager_test/BUILD.gn index 33087af41c1e02d83163db79ed33dd7970cdbf04..e6f3d9cb0bec4a1b4fbd9d75e9d6317b99da60d5 100644 --- a/test/unittest/continuation_test/remote_register_service_test/continuation_register_manager_test/BUILD.gn +++ b/test/unittest/continuation_test/remote_register_service_test/continuation_register_manager_test/BUILD.gn @@ -56,6 +56,8 @@ config("ability_config") { defines = [ "AMS_LOG_TAG = \"Ability\"" ] if (target_cpu == "arm64") { defines += [ "_ARM64_" ] + } else if (target_cpu == "loongarch64") { + defines += [ "_LOONGARCH64_" ] } if (ability_runtime_graphics) {