diff --git a/build.gradle b/build.gradle
index 82964d03..42204985 100644
--- a/build.gradle
+++ b/build.gradle
@@ -1,3 +1,6 @@
+import org.gradle.nativeplatform.platform.internal.Architectures
+import org.gradle.internal.os.OperatingSystem
+
def DEFAULT_VERSION = '1.0.0'
def DEFAULT_GROUP = 'io.github.tronprotocol'
@@ -22,6 +25,10 @@ apply plugin: 'java'
apply plugin: 'java-library'
apply plugin: 'maven-publish'
+def arch = System.getProperty("os.arch").toLowerCase(Locale.ROOT)
+def isArm64 = Architectures.AARCH64.isAlias(arch)
+def isMac = OperatingSystem.current().isMacOsX()
+
ext {
bouncycastleVersion = '1.84'
junitJupiterVersion = '5.4.2'
@@ -30,6 +37,10 @@ ext {
// grpc-netty and netty are compatibility-coupled: each grpc-java release is
// tested against a specific netty line, so bump these two together
grpcVersion = '1.81.0'
+ // https://github.com/grpc/grpc-java/issues/7690
+ // https://github.com/grpc/grpc-java/pull/12319, Add support for macOS aarch64 with universal binary
+ // https://github.com/grpc/grpc-java/pull/11371 , 1.64.x is not supported CentOS 7.
+ protocGenVersion = isArm64 || isMac ? '1.81.0' : '1.60.0'
nettyVersion = '4.1.135.Final'
vertxVersion = '4.5.27'
}
diff --git a/core/build.gradle b/core/build.gradle
index 571120a6..e932b230 100644
--- a/core/build.gradle
+++ b/core/build.gradle
@@ -6,8 +6,6 @@ plugins {
description 'Trident-Java gRPC core classes'
def protobufVersion = '3.25.8'
-// grpcVersion lives in the root ext block, next to the coupled nettyVersion
-def protocGenVersion = '1.60.0' // https://github.com/grpc/grpc-java/pull/11371 , 1.64.x is not supported CentOS 7.
dependencies {
implementation "com.google.guava:guava:$googleGuavaVersion"
diff --git a/gradle/verification-metadata.xml b/gradle/verification-metadata.xml
index 7f4cb66e..89fb3fd3 100644
--- a/gradle/verification-metadata.xml
+++ b/gradle/verification-metadata.xml
@@ -463,6 +463,20 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+