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:
parent
64ecd5c061
commit
cba065fe56
1 changed files with 7 additions and 1 deletions
|
@ -43,7 +43,13 @@ android {
|
||||||
}
|
}
|
||||||
protobuf {
|
protobuf {
|
||||||
protoc {
|
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 {
|
generateProtoTasks {
|
||||||
all().each { task ->
|
all().each { task ->
|
||||||
|
|
Loading…
Add table
Reference in a new issue