【问题标题】:Android Studio Setup: android-23 not installedAndroid Studio 设置:未安装 android-23
【发布时间】:2016-03-13 12:17:28
【问题描述】:

我今天在两台 PC 上安装了两次 Android Studio(版本 1.5.1,内部版本 141.2456560),现在我已经两次看到此错误。换句话说,两台计算机都出现了相同的错误,它们都运行 Windows 10 Pro(x64,版本 1511,内部版本 10586.164)。

未安装以下 SDK 组件:android-23

有什么问题?我该如何解决这个问题?

【问题讨论】:

  • 以管理员身份运行 Android Studio。它适用于我的情况。

标签: android android-studio installation windows-10


【解决方案1】:

这可能是由 Android Studio 的安装脚本中的问题引起的。也可能是缺少管理员权限造成的。

点击重试!这在我遇到此错误时有所帮助。

安装日志可能如下所示。

Android SDK was installed to C:\Users\Bob\AppData\Local\Android\sdk


Installing Archives:
  Preparing to install archives
  Installing SDK Platform Android 6.0, API 23, revision 2
  Failed to rename directory C:\Users\Bob\AppData\Local\Android\sdk\platforms\android-23 to C:\Users\Bob\AppData\Local\Android\sdk\temp\RemotePlatformPkgInfo.old01.

SDK Manager: failed to install
-= Warning ! =-
A folder failed to be moved. On Windows this typically means that a program is using that folder (for example Windows Explorer or your anti-virus software.)
Please momentarily deactivate your anti-virus software or close any running programs that may be accessing the directory 'C:\Users\Bob\AppData\Local\Android\sdk\platforms\android-23'.
When ready, press YES to try again.
Note: you  can use --force to override to yes.
[y/n] =>
  Installing Android SDK Build-tools, revision 23.0.2
    Installed Android SDK Build-tools, revision 23.0.2
  Installing Local Maven repository for Support Libraries, revision 28
    Installed Local Maven repository for Support Libraries, revision 28
  Installing Google Repository, revision 24
    Installed Google Repository, revision 24
  Installing Android SDK Platform-tools, revision 23.1.0
    Stopping ADB server succeeded.
    Installed Android SDK Platform-tools, revision 23.1.0
  Installing Google APIs Intel x86 Atom System Image, Google Inc. API 23, revision 12
    Installed Google APIs Intel x86 Atom System Image, Google Inc. API 23, revision 12
    Stopping ADB server succeeded.
    Starting ADB server succeeded.
  Done. 5 packages installed.


Installing Archives:
  Preparing to install archives
  Installing SDK Platform Android 6.0, API 23, revision 2
    Installed SDK Platform Android 6.0, API 23, revision 2
  Done. 1 package installed.
Android SDK is up to date.
Creating Android virtual device
Android virtual device Nexus_5_API_23_x86 was successfully created

请注意安装程序如何无法从以下位置重命名目录:

C:\Users\Bob\AppData\Local\Android\sdk\platforms\android-23

到:

C:\Users\Bob\AppData\Local\Android\sdk\temp\RemotePlatformPkgInfo.old01

这可能是问题的原因。

在 Windows 上,这通常意味着程序正在使用该文件夹 (例如 Windows 资源管理器或您的防病毒软件。)

“程序”可能是 Android Studio 安装程序本身!在这种情况下,是 Android Studio 安装程序做错了,但会指责其他程序这样做。

这也可能意味着 Android Studio 安装程序在尝试重命名或移动 AppData 中的文件夹时没有管理员权限。因此,右键单击 Android Studio Setup EXE 文件并选择以管理员身份运行可能有助于避免此错误。

或者!它可能试图超越自己并以错误的顺序进行操作,即在仍然坐在树枝上的情况下切割树枝!

在我的情况下,单击重试就足够了。这可以通过日志看到。

Installing Archives:
  Preparing to install archives
  Installing SDK Platform Android 6.0, API 23, revision 2
    Installed SDK Platform Android 6.0, API 23, revision 2
  Done. 1 package installed.

完成设置后,无论有无错误,您都可以运行 SDK Manager 来查看是否安装了“android-23”组件。启动 Android Studio,从 Quick Start 菜单中单击 Configure 按钮,然后单击 SDK Manager。然后导航到外观和行为、系统设置、Android SDK。选中“显示包详细信息”框并确保选择的所有 API 级别 23 包的状态为“已安装”。您可以通过这种方式卸载、安装、重新安装和更新软件包。

【讨论】:

    【解决方案2】:

    就我而言: 我只是再次执行 .exe 文件以管理员身份运行。 并按照进一步的步骤-> 转到设置 -> 其他设置 -> 隐私:检查未知来源选项。 最后进入设置->附加设置->开发者选项:勾选通过USB安装选项。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2017-05-11
      • 1970-01-01
      • 2017-07-28
      • 1970-01-01
      • 2023-04-07
      • 2020-10-17
      • 2017-08-12
      • 1970-01-01
      相关资源
      最近更新 更多