Sync appropriate protoc artifact for m1

Fixes compilation on M1 macOS. Check https://github.com/grpc/grpc-java/issues/7690 for further info

Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
This commit is contained in:
Aayush Gupta 2023-08-02 23:45:52 +08:00
parent 64ecd5c061
commit cba065fe56

View file

@ -43,7 +43,13 @@ android {
}
protobuf {
protoc {
artifact = "com.google.protobuf:protoc:$protobuf_version"
if ("aarch64" == System.getProperty("os.arch")) {
// mac m1
artifact = "com.google.protobuf:protoc:$protobuf_version:osx-x86_64"
} else {
// other
artifact = "com.google.protobuf:protoc:$protobuf_version"
}
}
generateProtoTasks {
all().each { task ->