无法解决 Android Studio 中的依赖项 [英] Unable to resolve dependency in Android Studio

查看:54
本文介绍了无法解决 Android Studio 中的依赖项的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

启动 Android Studio 时,出现此错误:

When starting Android Studio, I get this error:

错误:无法解析:app@debugAndroidTest/compileClasspath"的依赖:无法解析 com.android.support.test:runner:1.0.1.

Error:Unable to resolve dependency for ':app@debugAndroidTest/compileClasspath': Could not resolve com.android.support.test:runner:1.0.1.

推荐答案

在 Linux 下在一个新项目上安装 Android Stidio 后,如果您没有执行此步骤,则可能会出现此错误 (如此处所述):

Under Linux on a new project you may get this error after installation Android Stidio if you haven't did this step (as described here):

如果您运行的是 64 位版本的 Ubuntu,则需要使用以下命令安装一些 32 位库:

If you are running a 64-bit version of Ubuntu, you need to install some 32-bit libraries with the following command:

sudo apt-get install libc6:i386 libncurses5:i386 libstdc++6:i386 lib32z1 libbz2-1.0:i386

如果您运行的是 64 位 Fedora,则命令为:

If you are running 64-bit Fedora, the command is:

sudo yum install zlib.i686 ncurses-libs.i686 bzip2-libs.i686

这篇关于无法解决 Android Studio 中的依赖项的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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