eclipse 找不到 SDK 和 AVD 管理器
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/8854062/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Can't find SDK and AVD Manager
提问by SJoe
This is my first step in the direction of android development so apologise for any silly question.
这是我朝着 android 开发方向迈出的第一步,所以对任何愚蠢的问题表示歉意。
I have used windows installer to install the Android SDK Manager. Post installation, this is how my start menu looks like.
我已经使用 Windows 安装程序来安装 Android SDK 管理器。安装后,这就是我的开始菜单的样子。
And this is how the SDK Manager looks like:
这就是 SDK 管理器的样子:
When I try to use Eclipse pluggin, I get the following error.
当我尝试使用 Eclipse 插件时,出现以下错误。
[2012-01-13 16:29:10 - DDMS] DDMS files not found: C:\Program Files\Android\android-sdk\platform-tools\adb.exe
[2012-01-13 16:29:10 - DDMS] 未找到 DDMS 文件:C:\Program Files\Android\android-sdk\platform-tools\adb.exe
So I thought maybe I should update the SDK manager but SDK Manager update does nothing at all.
所以我想也许我应该更新 SDK 管理器,但 SDK 管理器更新什么都不做。
I searched through the forums and documentation. People keep saying that I should use the SDK and AVD Manager. I just can't find any tool by that name. Is that a seperate installation? I can find an SDK manager and a seperate AVD manager and doesn't look anything like the screenshots see in forums/documentation. Maybe I am using the wrong version! I downloaded the SDK from the here.
我搜索了论坛和文档。人们一直说我应该使用 SDK 和 AVD Manager。我就是找不到这个名字的任何工具。是单独安装吗?我可以找到一个 SDK 管理器和一个单独的 AVD 管理器,并且看起来不像论坛/文档中的屏幕截图。可能我用的版本不对!我从这里下载了 SDK 。
UPDATE 1: 13 Jan 2012
更新 1:2012 年 1 月 13 日
Here is something more I figured. When I try to update using my SDK manager, this is what I see in the log:
这是我想到的更多东西。当我尝试使用我的 SDK 管理器进行更新时,这就是我在日志中看到的内容:
Fetching http://dl-ssl.google.com/android/repository/addons_list-1.xml
Failed to fetch URL http://dl-ssl.google.com/android/repository/addons_list-1.xml, reason: Connection to http://dl-ssl.google.com refused
Fetched Add-ons List successfully
Fetching URL: http://dl-ssl.google.com/android/repository/repository-5.xml
Failed to fetch URL http://dl-ssl.google.com/android/repository/repository-5.xml, reason: Connection to http://dl-ssl.google.com refused
Fetching URL: http://dl-ssl.google.com/android/repository/addon.xml
Failed to fetch URL http://dl-ssl.google.com/android/repository/addon.xml, reason: Connection to http://dl-ssl.google.com refused
Fetching URL: http://dl-ssl.google.com/android/repository/addon.xml
For some reason, connection to http://dl-ssl.google.comis being refused and maybe that's why I am unable to update anything.
出于某种原因,与http://dl-ssl.google.com 的连接被拒绝,也许这就是我无法更新任何内容的原因。
UPDATE 2: 16 January 2012
更新 2:2012 年 1 月 16 日
Okay I haven't got any response, I am going to write down everything I am doing before I forget. Maybe it will be useful for someone else...
好吧,我没有得到任何回应,我会在忘记之前写下我所做的一切。也许它对其他人有用......
I was facing many problems while configuring the environment for Android development. I have sorted solution for couple of issues so far. Maybe I will sort out the others soon!
在为 Android 开发配置环境时,我遇到了很多问题。到目前为止,我已经为几个问题整理了解决方案。也许我会尽快整理其他人!
Environment Used:Windows XP 32 bit Eclipse Helios
使用环境:Windows XP 32位Eclipse Helios
Problem 1:Could not find SDK and AVD Manager component after installing Android SDK.
问题 1:安装 Android SDK 后找不到 SDK 和 AVD Manager 组件。
Solution to Problem 1Although there is no proper documentation, it took a while for me to understand that the latest version of Android SDK has seperated SDK from AVD Management. So once you install Android SDK, expect to see two components - 1) SDK Manager, 2) AVD Manager. I am not sure what sort of features have changed from previous version, but if you are into android development for the first time, this change could drive you nuts as all documents speak based on the previous versions - bad GOOGLE!
问题1的解决方案虽然没有适当的文档,但我花了一段时间才明白,最新版本的Android SDK已经将SDK与AVD管理分开了。因此,一旦您安装了 Android SDK,就会看到两个组件 - 1) SDK Manager,2) AVD Manager。我不确定与以前的版本相比有哪些类型的功能变化,但是如果您是第一次进入 android 开发,这种变化可能会让您发疯,因为所有文档都基于以前的版本 - 糟糕的 GOOGLE!
Problem 2During installation of SDK, the .exe for windows is unable to detect JDK.
问题2安装SDK时,windows的.exe无法检测到JDK。
Solution to Problem 2Again, older documents and forum posts seem to say that hitting the back and then hitting next once again should solve the problem. Not so with the latest version. Google has come up with a funny work around to beat this defect. Now you have a small button called "Report Error". Click that and the next button will be enabled. This should let you proceed with the installation
问题 2 的解决方案同样,较旧的文档和论坛帖子似乎都说点击背面然后再次点击下一步应该可以解决问题。最新版本不是这样。谷歌想出了一个有趣的工作来克服这个缺陷。现在您有一个名为“报告错误”的小按钮。单击该按钮,将启用下一步按钮。这应该让您继续安装
Problem 3:Installing the Eclipse ADT plugin causes the following error
问题三:安装Eclipse ADT插件导致如下错误
Cannot complete the install because of a conflicting dependency.
Software being installed: Android Hierarchy Viewer 16.0.1.v201112150204-238534 (com.android.ide.eclipse.hierarchyviewer.feature.group 16.0.1.v201112150204-238534)
Software currently installed: Eclipse IDE for Java EE Developers 1.3.0.20100617-0521 (epp.package.jee 1.3.0.20100617-0521)
Only one of the following can be installed at once:
Eclipse UI 3.6.1.M20100826-1330 (org.eclipse.ui 3.6.1.M20100826-1330)
Eclipse UI 3.6.2.M20110203-1100 (org.eclipse.ui 3.6.2.M20110203-1100)
Eclipse UI 3.6.0.I20100603-1100 (org.eclipse.ui 3.6.0.I20100603-1100)
Cannot satisfy dependency:
From: Android Hierarchy Viewer 16.0.1.v201112150204-238534 (com.android.ide.eclipse.hierarchyviewer.feature.group 16.0.1.v201112150204-238534)
To: org.eclipse.ui 3.6.2
Cannot satisfy dependency:
From: Eclipse IDE for Java EE Developers 1.3.0.20100617-0521 (epp.package.jee 1.3.0.20100617-0521)
To: org.eclipse.epp.package.jee.feature.feature.group [1.3.0.20100617-0521]
Cannot satisfy dependency:
From: Java EE IDE Feature 1.3.0.20100617-0521 (org.eclipse.epp.package.jee.feature.feature.group 1.3.0.20100617-0521)
To: org.eclipse.platform.feature.group [3.6.0.v20100602-9gF78GpqFt6trOGhL60z0oEx3fz-JKNwxPY]
Cannot satisfy dependency:
From: Eclipse Platform 3.6.0.v20100602-9gF78GpqFt6trOGhL60z0oEx3fz-JKNwxPY (org.eclipse.platform.feature.group 3.6.0.v20100602-9gF78GpqFt6trOGhL60z0oEx3fz-JKNwxPY)
To: org.eclipse.rcp.feature.group [3.6.0.v20100519-9OArFKvFtsd7WLUKh-DcYTS]
Cannot satisfy dependency:
From: Eclipse RCP 3.6.0.v20100519-9OArFKvFtsd7WLUKh-DcYTS (org.eclipse.rcp.feature.group 3.6.0.v20100519-9OArFKvFtsd7WLUKh-DcYTS)
To: org.eclipse.ui [3.6.0.I20100603-1100]
Solution to Problem 3This is caused because Eclipse IDE for Java EE Developers is an older version. So in Eclipse, go to Help >> Update Softwares. This would list the latest Eclipse IDE for Java EE Developer. Install it. Then repeat the steps to install Android ADT pluggin. This solved the problem for me.
问题 3 的解决方案这是因为 Java EE Developers 的 Eclipse IDE 版本较旧。因此,在 Eclipse 中,转到帮助 >> 更新软件。这将列出 Java EE Developer 的最新 Eclipse IDE。安装它。然后重复安装Android ADT插件的步骤。这为我解决了这个问题。
Problem 4:When you open eclipse after installing the ADT pluggin, the following error appears: [2012-01-16 16:00:10 - DDMS] DDMS files not found: C:\Program Files\Android\android-sdk\platform-tools\adb.exe
问题4:安装ADT插件后打开eclipse,出现如下错误: [2012-01-16 16:00:10 - DDMS] DDMS files not found: C:\Program Files\Android\android-sdk\platform -tools\adb.exe
Solution for Problem 4:This issue has been fixed with the help extended by Nandeesh (see below comments). I download the platform-tools directory from the following location (http://dl-ssl.google.com/android/repository/platform-tools_r10-windows.zip) and unzipped it under platform-tools directory in my installation directory. This removed the error from Eclipse ADT.
问题 4 的解决方案:此问题已在 Nandeesh 扩展的帮助下修复(请参阅下面的评论)。我从以下位置 ( http://dl-ssl.google.com/android/repository/platform-tools_r10-windows.zip)下载 platform-tools 目录并将其解压缩到我的安装目录中的 platform-tools 目录下。这消除了 Eclipse ADT 中的错误。
Problem 5:Following error occurs when I refresh using SDK manager
问题5:使用SDK manager刷新时出现如下错误
Failed to fetch URL http://dl-ssl.google.com/android/repository/addons_list-1.xml, reason: Connection to http://dl-ssl.google.com refused
Partial solution to Problem 5: I am stuck with this problem and I haven't found a solution so far. Here is what I have learnt.
问题 5 的部分解决方案:我被这个问题困住了,到目前为止我还没有找到解决方案。这是我学到的。
All the post on this error claim that this has to do with proxy settings. This is what I did: I found out my proxy setting by going to my Internet Explorer >> Internet Options >> Connections >> Lan Settings. Copied the proxy details and set it up in Eclipse >> Windows >> Preferences >> General >> Network Connections. After this I went to SDK manager >> Tools >> Options and entered proxy details in the HTTP Proxy server Box and checked the force https option. Tried refreshing - no luck. Then getting desperate, I have tried all combinations of Proxy and force https. Nothing seems to work. So, as per suggestion made by Nandeesh (refer comments below), I have started downloading the files directly based on the repository.xml found here ssl.google.com/android/repository/repository-5.xml. So far so good.
关于此错误的所有帖子都声称这与代理设置有关。这就是我所做的:我通过转到 Internet Explorer >> Internet 选项 >> 连接 >> Lan 设置找到了我的代理设置。复制代理详细信息并在 Eclipse >> Windows >> Preferences >> General >> Network Connections 中进行设置。在此之后,我转到 SDK 管理器 >> 工具 >> 选项并在 HTTP 代理服务器框中输入代理详细信息并检查强制 https 选项。尝试提神 - 没有运气。然后变得绝望,我尝试了代理和强制 https 的所有组合。似乎没有任何效果。因此,根据 Nandeesh 提出的建议(请参阅下面的评论),我已经开始根据 ssl.google.com/android/repository/repository-5.xml 中的 repository.xml 直接下载文件。
Problem 6:Unable to detect target SDK in eclipse ADT
问题六:eclipse ADT中无法检测到目标SDK
Solution for Problem 6:This is what I did. Downloaded the latest Eclipse. I now use Eclipse Indigo. Then I checked the directory structure of the SDK installed. I installed it under C:/Android/android-sdk. Avoid any spaces in the file path (that could be causing the issue). The Android/android-sdk directory should contain the following directories - platforms, platform-tools, tools, add-ons. Inside the platforms directory I see android-4.0.3 directory. This directory should have the version number as part of the directory name. If you don't see this directory, download the suitable platform from https://dl-ssl.google.com/android/repository/. The version you should be using depends on your environment. The list of all directory is available in this XML http://dl-ssl.google.com/android/repository/repository-5.xml. Download the corresponding platform an unzip the entire contents into C:/Android/android-sdk/platforms. Also download the corresponding platform-tools and unzip the entire contents into platform-tools directory. Restart eclipse. The SDK should be automatically detected. If not, go to Windows >> Preference >> Android and set the SDK installation directory. Hit apply and it should list the available targets. NOTE that the targets will be list if and only if the SDK installation is correct. So ensure that the platforms directory inside the SDK installation is correct.
问题 6 的解决方案:这就是我所做的。下载了最新的Eclipse。我现在使用 Eclipse Indigo。然后我检查了安装的SDK的目录结构。我将它安装在 C:/Android/android-sdk 下。避免文件路径中出现任何空格(这可能会导致问题)。Android/android-sdk 目录应包含以下目录 - 平台、平台工具、工具、附加组件。在平台目录中,我看到 android-4.0.3 目录。此目录应将版本号作为目录名称的一部分。如果您没有看到此目录,请从https://dl-ssl.google.com/android/repository/下载合适的平台。您应该使用的版本取决于您的环境。此 XML 中提供了所有目录的列表http://dl-ssl.google.com/android/repository/repository-5.xml。下载对应平台,将全部内容解压到C:/Android/android-sdk/platforms。同时下载相应的平台工具并将整个内容解压到平台工具目录中。重启日食。应自动检测 SDK。如果没有,请转到 Windows >> Preference >> Android 并设置 SDK 安装目录。点击应用,它应该列出可用的目标。请注意,当且仅当 SDK 安装正确时,目标才会被列出。所以确保SDK安装里面的platforms目录是正确的。
Problem 7I am seeing this when I open eclipse
问题 7我在打开 eclipse 时看到这个
No idea what went wrong. Again suspecting that this is because I manually copied the files :(
不知道出了什么问题。再次怀疑这是因为我手动复制了文件:(
Solution to Problem 7:Read solution to Problem 6. This would solve problem 7 also. The only thing that is important is that make sure your SDK is installed properly. If not manually copy the appropriate platforms and platform-tools and try once again. Ensure the structure of the files are proper and that files names do not have a space.
问题 7 的解决方案:阅读问题 6 的解决方案。这也将解决问题 7。唯一重要的是确保您的 SDK 安装正确。如果没有手动复制适当的平台和平台工具,然后再试一次。确保文件的结构正确并且文件名没有空格。
Having done all of this, I can now say that I have set up my environment and now I ready to code! This issue is RESOLVED :)
完成所有这些之后,我现在可以说我已经设置了我的环境,现在我可以开始编码了!这个问题已解决:)
采纳答案by Codeman
May or may not still be an issue - but I was unable to use a path with a space in the name ("Program Files" was the culprit). I believe this is fixed in the current release, but it is worth a try to fix your problem.
可能是也可能不是问题 - 但我无法使用名称中带有空格的路径(“程序文件”是罪魁祸首)。我相信这是在当前版本中修复的,但值得尝试解决您的问题。
回答by user2382208
problem 4: When you open eclipse after installing the ADT pluggin, the following error appears: [2012-01-16 16:00:10 - DDMS] DDMS files not found: C:\Program Files\Android\android-sdk\platform-tools\adb.exe
问题4:安装ADT插件后打开eclipse,出现如下错误:[2012-01-16 16:00:10 - DDMS] DDMS files not found: C:\Program Files\Android\android-sdk\platform -tools\adb.exe
Solution:
解决方案:
I had the same problem with my eclipse Juno. then i found that the platform-tools got corrupted. i deleted the corrupted file from sdk manager and re-installed it. Now i dint find any error messages.
我的 eclipse Juno 也有同样的问题。然后我发现平台工具已损坏。我从 sdk 管理器中删除了损坏的文件并重新安装了它。现在我找不到任何错误消息。
Hope this would help you!!
希望这对你有帮助!!
回答by 21stking
for problem 5:
对于问题 5:
The problem is your network ofcourse. Use a moderminstead of a LAN and this will work perfectly. But if you are using a LAN then ask your network administrator to help you with this.
问题当然是你的网络。使用调制解调器而不是局域网,这将完美地工作。但是,如果您使用的是 LAN,那么请让您的网络管理员帮助您解决这个问题。