Android Studio Gradle错误Failed to load native library 'native-platform.dll'

本文介绍了一种常见问题,即在使用AndroidStudio时遇到的build失败情况,具体表现为无法启动守护进程并提示加载native-platform.dll失败。文章给出了定位问题及解决方法,包括找到并删除指定的.lock文件。

之前由于电脑没电导致自动关机,重新开机打开Android Studio后无法build项目了,报了以下这个错误:

Error:Unable to start the daemon process.
This problem might be caused by incorrect configuration of the daemon.
For example, an unrecognized jvm option is used.
Please refer to the user guide chapter on the daemon at https://docs.gradle.org/3.3/userguide/gradle_daemon.html
Please read the following process output to find out more:
-----------------------

FAILURE: Build failed with an exception.

* What went wrong:
Failed to load native library 'native-platform.dll' for Windows 10 x86.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
复制代码

网上找了下资料,预计是native-platform.dll这个文件出了问题,定位这个文件的位置,一般在C:\Users<你自己的用户名>.gradle\native中

打开23(你自己的gradle版本),如果只有一个native-platform.dll.lock文件,只要将这个文件后缀.lock删掉即可。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值