Android Studio Gradle 同步和构建错误 [英] Android studio Gradle sync and build error

查看:56
本文介绍了Android Studio Gradle 同步和构建错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是 android studio 和 gradle 的新手,我得到了 AS 0.5.我下载了 0.8.1 更新包,并通过删除已安装的文件并将更新文件复制到程序文件文件夹进行更新.它运行正常,但是当我尝试同步 gradle 时,出现此错误.这真的很令人沮丧,因为我的互联网连接速度非常慢,我尝试删除 .gradle 文件,然后再试一次,但没有运气.任何帮助将不胜感激.由于 r23 错误,我的 ADT 目前一团糟.我以为 AS 会提供一条出路,现在我又被卡住了.

I am new to android studio and gradle and i got AS 0.5. I downloaded the 0.8.1 update package and updated by deleting the installed files and copying the update files to the program files folder. It runs correctly but when i try to sync gradle, i get this error. It's really frustrating because i have an extremely slow internet connection and i have tried deleting the .gradle file and trying again wit no luck. Any help will be appreciated. My ADT is currently messed up because of the r23 bug. I thought AS will offer a way out and now I'm stuck again.

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 http://gradle.org/docs/1.12/userguide/gradle_daemon.html

Please read below process output to find out more:

18:44:13.593 [main] DEBUG o.g.l.daemon.bootstrap.DaemonMain - Assuming the daemon was started with following jvm opts: [-XX:MaxPermSize=256m, -XX:+HeapDumpOnOutOfMemoryError, -Xmx1024m, -Dfile.encoding=windows-1252]

FAILURE: Build failed with an exception.

* What went wrong:
Could not create service of type DaemonContext using DaemonServices.createDaemonContext().

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

推荐答案

以管理员身份运行 Android Studio.它为我解决了问题.

Run Android Studio as administrator. It fixed the problem for me.

这篇关于Android Studio Gradle 同步和构建错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆