【问题标题】:Error:Android Pre Dex: Android SDK is not specified错误:Android Pre Dex:未指定 Android SDK
【发布时间】:2015-08-29 12:53:33
【问题描述】:

我已经从网站上下载了gdx-setup.jar 并运行它:

java -jar gdx-setup.jar

我选择我想要的选项并为idea (libgdx 1.6.2) 生成项目。当我单击生成按钮时,该工具不会向我抛出任何错误。

当我运行 idea 14.1.3 时,我转到 File > Open... 并选择生成的 ipr 文件。

当我尝试运行桌面启动器时,idea 抛出下一个错误:

Error:Android Pre Dex: [android] Android SDK is not specified

我尝试过使用不同的构建工具和 android API(当我按下来自gdx-setup.jar 的生成按钮时,它们中的大多数都会向我抛出警告)。我正在使用构建工具 20.0.0 和 API 20,并且使用此配置 gdx-setup.jar 不会向我发出警告。

我检查了一般项目的 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

有什么建议吗?

谢谢。

【问题讨论】:

    标签: java android intellij-idea libgdx


    【解决方案1】:

    进入项目结构,选择平台设置 -> SDK(左侧面板),然后通过选择 + 添加您的 Android SDK。然后在 Project Settings -> Module 中,选择 android 模块,然后选择你刚刚添加的 android SDK。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2015-09-13
      • 2013-12-03
      • 1970-01-01
      • 2015-02-03
      相关资源
      最近更新 更多