From 8ef29784e1546a58f556aacaceafab5ad513aba7 Mon Sep 17 00:00:00 2001 From: Brian Isganitis Date: Fri, 18 Mar 2022 14:19:30 -0700 Subject: [PATCH] Fix Proto compilation on M1 Macs The Maven artifact upstream doesn't have an ARM version of Proto compiler. Since updating the artifact breaks the compilation, this explicitly requests x86 protoc binary which is then run via Rosetta. Build completes successfully. Change-Id: Ia13f28a6f019ad53e88f6dd4a8788ab7ec1ebead Test: Manual --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index e4ade88af8..68ed73d60a 100644 --- a/build.gradle +++ b/build.gradle @@ -170,7 +170,7 @@ dependencies { protobuf { // Configure the protoc executable protoc { - artifact = "com.google.protobuf:protoc:${protocVersion}" + artifact = "com.google.protobuf:protoc:${protocVersion}${PROTO_ARCH_SUFFIX}" } generateProtoTasks { all().each { task ->