Error:Android Pre Dex: Android SDK is not specified(错误:Android Pre Dex:未指定 Android SDK)
问题描述
我已经从网站下载了 gdx-setup.jar
并运行它:
I have downloaded gdx-setup.jar
from website and I run it as:
java -jar gdx-setup.jar
我选择我想要的选项并为 idea
(libgdx 1.6.2) 生成项目.当我单击生成按钮时,该工具不会向我抛出任何错误.
I select the options that I want and generate project for idea
(libgdx 1.6.2). When I click in generate button, the tool doesn't throw me any error.
当我运行 idea 14.1.3
时,我转到 File > Open... 并选择生成的 ipr 文件.
When I run idea 14.1.3
I go to File > Open... and select the ipr file generated.
当我尝试运行桌面启动器时,idea
抛出下一个错误:
When I try to run desktop launcher, idea
throw me the next error:
Error:Android Pre Dex: [android] Android SDK is not specified
我尝试过使用不同的构建工具和 android API(当我从 gdx-setup.jar
按下生成按钮时,它们中的大多数都会向我发出警告).我正在使用构建工具 20.0.0 和 API 20,并且使用此配置 gdx-setup.jar
不会向我发出警告.
I have tried with different build tools and API of android (most of them throw me warnings when I pressed generate button from gdx-setup.jar
). I am using Build tools 20.0.0 and API 20 and with this configuration gdx-setup.jar
doesn't throw me warnings.
我检查了一般项目的 local.properties:sdk.dir=/home/XXXX/Escritorio/android-sdk-linux-libgdx/
这是正确的我检查 File > project structure... > SDK's > Android SDK 也是正确的:/home/XXXX/Escritorio/android-sdk-linux-libgdx
I check local.properties of general project:
sdk.dir=/home/XXXX/Escritorio/android-sdk-linux-libgdx/
it is right
I check File > project structure... > SDK's > Android SDK and it is also right:
/home/XXXX/Escritorio/android-sdk-linux-libgdx
有什么建议吗?
谢谢.
推荐答案
进入 Project Structure,选择 Platform Settings -> SDKs(左侧面板),然后通过选择 + 添加您的 Android SDK.然后在 Project Settings -> Module 中,选择 android 模块,然后选择你刚刚添加的 android SDK.
Go in Project Structure, select Platform Settings -> SDKs (left panel) then add your Android SDK by selecting the +. Then in Project Settings -> Module , choose the android module, and choose the android SDK that you just added.
这篇关于错误:Android Pre Dex:未指定 Android SDK的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:错误:Android Pre Dex:未指定 Android SDK


- 如何使 JFrame 背景和 JPanel 透明且仅显示图像 2022-01-01
- 如何指定 CORS 的响应标头? 2022-01-01
- Eclipse 的最佳 XML 编辑器 2022-01-01
- GC_FOR_ALLOC 是否更“严重"?在调查内存使用情况时? 2022-01-01
- 转换 ldap 日期 2022-01-01
- 将 Java Swing 桌面应用程序国际化的最佳实践是什么? 2022-01-01
- java.lang.IllegalStateException:Bean 名称“类别"的 BindingResult 和普通目标对象都不能用作请求属性 2022-01-01
- 未找到/usr/local/lib 中的库 2022-01-01
- 在 Java 中,如何将 String 转换为 char 或将 char 转换 2022-01-01
- 获取数字的最后一位 2022-01-01