首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >roboblender-3.0.1.jar: Android中不包含: javax.tools。从com.google.inject.blender.AnnotationDatabaseGenerator引用

roboblender-3.0.1.jar: Android中不包含: javax.tools。从com.google.inject.blender.AnnotationDatabaseGenerator引用
EN

Stack Overflow用户
提问于 2015-01-10 17:16:49
回答 1查看 725关注 0票数 9

我尝试构建我的android项目,我得到了:

代码语言:javascript
复制
Information:Gradle: Executing tasks: [clean, :app:compileDebugSources]
Information:1/10/15, 11:13 AM - Compilation completed successfully in 5 sec

然后,我尝试将其部署到我的设备上,并获得:

代码语言:javascript
复制
FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:lint'.
> Lint found errors in the project; aborting build.

  Fix the issues identified by lint, or add the following to your build script to proceed with errors:
  ...
  android {
      lintOptions {
          abortOnError false
      }
  }

然后,我查看了lint报告,并看到:

代码语言:javascript
复制
InvalidPackage: Package not included in Android
../../../../../.gradle/caches/modules-2/files-2.1/org.roboguice/roboblender/3.0.1/d629079b9bfa8d889ec833d1eb747e89cf789bfa/roboblender-3.0.1.jar: Invalid package reference in library; not included in Android: javax.tools. Referenced from com.google.inject.blender.AnnotationDatabaseGenerator.
../../../../../.gradle/caches/modules-2/files-2.1/org.roboguice/roboguice/3.0.1/24e814f35d5cc28eaa7e9f07a50ea69deeb2b544/roboguice-3.0.1.jar: Invalid package reference in library; not included in Android: javax.inject. Referenced from com.google.inject.Scopes.3.
../../../../../.gradle/caches/modules-2/files-2.1/org.apache.velocity/velocity/1.7/2ceb567b8f3f21118ecdec129fe1271dbc09aa7a/velocity-1.7.jar: Invalid package reference in library; not included in Android: javax.naming. Referenced from org.apache.velocity.runtime.resource.loader.DataSourceResourceLoader.
../../../../../.gradle/caches/modules-2/files-2.1/org.apache.velocity/velocity/1.7/2ceb567b8f3f21118ecdec129fe1271dbc09aa7a/velocity-1.7.jar: Invalid package reference in library; not included in Android: javax.servlet.http. Referenced from org.apache.velocity.servlet.VelocityServlet.
../../../../../.gradle/caches/modules-2/files-2.1/org.apache.velocity/velocity/1.7/2ceb567b8f3f21118ecdec129fe1271dbc09aa7a/velocity-1.7.jar: Invalid package reference in library; not included in Android: javax.servlet. Referenced from org.apache.velocity.runtime.log.ServletLogChute.

我在mac上工作,而roboguice过去一直工作到昨晚。

我有VPN代理,因为这是我的工作,mac。我试着把它关了又开。什么都没有用。

我通常在没有它的情况下成功地上网。

会出什么问题呢?

EN

回答 1

Stack Overflow用户

发布于 2015-09-18 03:42:48

尝试将lint选项添加到项目的build.gradle文件中。

代码语言:javascript
复制
 android {
  // your build config
  defaultConfig { ... }
  signingConfigs { ... }
  compileOptions { ... }
  buildTypes { ... }
  // This is important, it will run lint checks but won't abort build
  lintOptions {
      abortOnError false
  }
}

如果这不起作用,请尝试将其替换为

代码语言:javascript
复制
android {
  // your build config
  defaultConfig { ... }
  signingConfigs { ... }
  compileOptions { ... }
  buildTypes { ... }
  // This is important, it will run lint checks but won't abort build
  lintOptions {
      checkReleaseBuilds false
  }
}
票数 -1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/27874617

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档