解决MacM1芯片无法下载aarch架构grpc的方法

在用自己电脑编译运行公司项目的时候,发现里面编译后发现缺少了这些东西

  • What went wrong: Execution failed for task ':OverseaEngine:generateDebugProto'.

Could not resolve all files for configuration ':OverseaEngine:protobufToolsLocator_grpc'. Could not find protoc-gen-grpc-java-1.4.0-osx-aarch_64.exe (io.grpc:protoc-gen-grpc-java:1.4.0). Searched in the following locations: https://nexus.txzing.com/repository/maven-public/io/grpc/protoc-gen-grpc-java/1.4.0/protoc-gen-grpc-java-1.4.0-osx-aarch_64.exe


  • What went wrong: Execution failed for task ':TXZLongConnection:generateDebugProto'.

Could not resolve all files for configuration ':TXZLongConnection:protobufToolsLocator_javalite'. Could not find protoc-gen-javalite-3.0.0-osx-aarch_64.exe (com.google.protobuf:protoc-gen-javalite:3.0.0). Searched in the following locations: https://nexus.txzing.com/repository/maven-public/com/google/protobuf/protoc-gen-javalite/3.0.0/protoc-gen-javalite-3.0.0-osx-aarch_64.exe

意思大概是我的电脑需要使用aarch架构的文件,但是公司的Maven库里只有x86-74,所以是打不开的 这里需要强制设置下载的文件是x86架构,只需要在对应报错的类的依赖后面加上

复制代码
  protoc {
    artifact = 'com.google.protobuf:protoc:3.14.0:osx-x86_64'
  }
}
//另外还需要在gradle.properites里加上 
protoc_platform=osx-x86_64
//编译后即可解决

但是还是没办法运行编译模块,发现里面已经没有依赖Javafx了,之前是有集成在JDK里的,但是后来从openJdk中分离开了,因为时间紧迫没有再去解决,后续再研究。

不过一般到这里问题就解决了,JavaFx这个只是我的额外问题

封面源自影视飓风,希望自己也能无限进步

相关推荐
多啦C梦a3 分钟前
【适合小白篇】什么是 SPA?前端路由到底在路由个啥?我来给你聊透!
前端·javascript·架构
Codebee35 分钟前
OneCode 3.0: 注解驱动的Spring生态增强方案
后端·设计模式·架构
hsx66638 分钟前
Kotlin return@label到底怎么用
android
Java技术小馆1 小时前
RPC vs RESTful架构选择背后的技术博弈
后端·面试·架构
腾讯云开发者1 小时前
架构师如何与 AI 共生进化?2025 腾讯云架构师峰会来揭晓!
人工智能·架构
itgather2 小时前
安卓设备信息查看器 - 源码编译
android
whysqwhw2 小时前
OkHttp之buildSrc模块分析
android
hsx6662 小时前
从源码角度理解Android事件的传递流程
android
krysliang2 小时前
qiankun使用教程(从项目搭建到容器化部署)
前端·架构
代码改变世界ctw2 小时前
ARM汇编编程(AArch64架构)第13课:多核启动与调度
汇编·arm开发·架构