当前位置:   article > 正文

Idea-android-osmdroid:the project uses gradle 2.14.1 which is incompatible with java 9 or newer

Idea-android-osmdroid:the project uses gradle 2.14.1 which is incompatible with java 9 or newer

方法一:【工具使用】IDEA 2019默认使用Java11导入gradle工程问题https://blog.csdn.net/jiajane/article/details/103014036

方法二:点击open gradle settings->use java8.....

重新run

  1. 11:50:20: Executing task...
  2. Configuration on demand is an incubating feature.
  3. Download https://jcenter.bintray.com/com/android/tools/build/gradle/2.2.0/gradle-2.2.0.pom
  4. Download https://jcenter.bintray.com/com/android/tools/build/gradle-core/2.2.0/gradle-core-2.2.0.pom
  5. Download https://jcenter.bintray.com/com/android/tools/build/builder/2.2.0/builder-2.2.0.pom
  6. Download https://jcenter.bintray.com/com/android/tools/lint/lint/25.2.0/lint-25.2.0.pom
  7. Download https://jcenter.bintray.com/com/android/tools/build/transform-api/2.0.0-deprecated-use-gradle-api/transform-api-2.0.0-deprecated-use-gradle-api.pom
  8. Download https://jcenter.bintray.com/com/android/tools/build/gradle-api/2.2.0/gradle-api-2.2.0.pom
  9. Download https://jcenter.bintray.com/com/android/databinding/compilerCommon/2.2.0/compilerCommon-2.2.0.pom
  10. Download https://jcenter.bintray.com/org/ow2/asm/asm-commons/5.0.4/asm-commons-5.0.4.pom
  11. Download https://jcenter.bintray.com/net/sf/proguard/proguard-gradle/5.2.1/proguard-gradle-5.2.1.pom
  12. Download https://jcenter.bintray.com/net/sf/proguard/proguard-parent/5.2.1/proguard-parent-5.2.1.pom
  13. Download https://jcenter.bintray.com/org/jacoco/org.jacoco.core/0.7.5.201505241946/org.jacoco.core-0.7.5.201505241946.pom
  14. Download https://jcenter.bintray.com/org/jacoco/org.jacoco.build/0.7.5.201505241946/org.jacoco.build-0.7.5.201505241946.pom
  15. Download https://jcenter.bintray.com/org/jacoco/org.jacoco.report/0.7.5.201505241946/org.jacoco.report-0.7.5.201505241946.pom
  16. Download https://jcenter.bintray.com/com/google/protobuf/protobuf-java/2.5.0/protobuf-java-2.5.0.pom
  17. Download https://jcenter.bintray.com/org/antlr/antlr/3.5.2/antlr-3.5.2.pom
  18. Download https://jcenter.bintray.com/org/antlr/antlr-master/3.5.2/antlr-master-3.5.2.pom
  19. Download https://jcenter.bintray.com/com/android/tools/build/builder-model/2.2.0/builder-model-2.2.0.pom
  20. Download https://jcenter.bintray.com/com/android/tools/build/builder-test-api/2.2.0/builder-test-api-2.2.0.pom
  21. Download https://jcenter.bintray.com/com/android/tools/sdklib/25.2.0/sdklib-25.2.0.pom
  22. Download https://jcenter.bintray.com/com/android/tools/sdk-common/25.2.0/sdk-common-25.2.0.pom
  23. Download https://jcenter.bintray.com/com/android/tools/common/25.2.0/common-25.2.0.pom
  24. Download https://jcenter.bintray.com/com/android/tools/build/manifest-merger/25.2.0/manifest-merger-25.2.0.pom
  25. Download https://jcenter.bintray.com/com/android/tools/ddms/ddmlib/25.2.0/ddmlib-25.2.0.pom
  26. Download https://jcenter.bintray.com/com/android/tools/jack/jack-api/0.11.0/jack-api-0.11.0.pom
  27. Download https://jcenter.bintray.com/com/android/tools/jill/jill-api/0.10.0/jill-api-0.10.0.pom
  28. Download https://jcenter.bintray.com/com/android/tools/analytics-library/protos/25.2.0/protos-25.2.0.pom
  29. Download https://jcenter.bintray.com/com/android/tools/analytics-library/shared/25.2.0/shared-25.2.0.pom
  30. Download https://jcenter.bintray.com/com/android/tools/analytics-library/tracker/25.2.0/tracker-25.2.0.pom
  31. Download https://jcenter.bintray.com/org/bouncycastle/bcpkix-jdk15on/1.48/bcpkix-jdk15on-1.48.pom
  32. Download https://jcenter.bintray.com/org/bouncycastle/bcprov-jdk15on/1.48/bcprov-jdk15on-1.48.pom
  33. Download https://jcenter.bintray.com/org/ow2/asm/asm-tree/5.0.4/asm-tree-5.0.4.pom
  34. Download https://jcenter.bintray.com/com/android/tools/lint/lint-checks/25.2.0/lint-checks-25.2.0.pom
  35. Download https://jcenter.bintray.com/org/eclipse/jdt/core/compiler/ecj/4.5.1/ecj-4.5.1.pom
  36. Download https://jcenter.bintray.com/com/google/guava/guava/17.0/guava-17.0.pom
  37. Download https://jcenter.bintray.com/com/google/guava/guava-parent/17.0/guava-parent-17.0.pom
  38. Download https://jcenter.bintray.com/com/android/databinding/baseLibrary/2.2.0/baseLibrary-2.2.0.pom
  39. Download https://jcenter.bintray.com/com/android/tools/annotations/24.5.0/annotations-24.5.0.pom
  40. Download https://jcenter.bintray.com/net/sf/proguard/proguard-base/5.2.1/proguard-base-5.2.1.pom
  41. Download https://jcenter.bintray.com/org/ow2/asm/asm-debug-all/5.0.1/asm-debug-all-5.0.1.pom
  42. Download https://jcenter.bintray.com/org/ow2/asm/asm-parent/5.0.1/asm-parent-5.0.1.pom
  43. Download https://jcenter.bintray.com/org/antlr/antlr-runtime/3.5.2/antlr-runtime-3.5.2.pom
  44. Download https://jcenter.bintray.com/org/antlr/ST4/4.0.8/ST4-4.0.8.pom
  45. Download https://jcenter.bintray.com/com/android/tools/layoutlib/layoutlib-api/25.2.0/layoutlib-api-25.2.0.pom
  46. Download https://jcenter.bintray.com/com/android/tools/dvlib/25.2.0/dvlib-25.2.0.pom
  47. Download https://jcenter.bintray.com/com/android/tools/repository/25.2.0/repository-25.2.0.pom
  48. Download https://jcenter.bintray.com/com/google/code/gson/gson/2.2.4/gson-2.2.4.pom
  49. Download https://jcenter.bintray.com/org/apache/commons/commons-compress/1.8.1/commons-compress-1.8.1.pom
  50. Download https://jcenter.bintray.com/org/apache/commons/commons-parent/33/commons-parent-33.pom
  51. Download https://jcenter.bintray.com/org/apache/httpcomponents/httpclient/4.1.1/httpclient-4.1.1.pom
  52. Download https://jcenter.bintray.com/org/apache/httpcomponents/httpcomponents-client/4.1.1/httpcomponents-client-4.1.1.pom
  53. Download https://jcenter.bintray.com/org/apache/httpcomponents/project/4.1.1/project-4.1.1.pom
  54. Download https://jcenter.bintray.com/org/apache/httpcomponents/httpmime/4.1/httpmime-4.1.pom
  55. Download https://jcenter.bintray.com/org/apache/httpcomponents/httpcomponents-client/4.1/httpcomponents-client-4.1.pom
  56. Download https://jcenter.bintray.com/com/android/tools/lint/lint-api/25.2.0/lint-api-25.2.0.pom
  57. Download https://jcenter.bintray.com/org/ow2/asm/asm-analysis/5.0.4/asm-analysis-5.0.4.pom
  58. Download https://jcenter.bintray.com/com/intellij/annotations/12.0/annotations-12.0.pom
  59. Download https://jcenter.bintray.com/org/apache/httpcomponents/httpcore/4.1/httpcore-4.1.pom
  60. Download https://jcenter.bintray.com/org/apache/httpcomponents/httpcomponents-core/4.1/httpcomponents-core-4.1.pom
  61. Download https://jcenter.bintray.com/commons-codec/commons-codec/1.4/commons-codec-1.4.pom
  62. Download https://jcenter.bintray.com/com/android/tools/external/lombok/lombok-ast/0.2.3/lombok-ast-0.2.3.pom
  63. Download https://jcenter.bintray.com/com/android/tools/external/com-intellij/uast/145.597.3/uast-145.597.3.pom
  64. Download https://jcenter.bintray.com/com/android/tools/annotations/25.2.0/annotations-25.2.0.pom
  65. Download https://jcenter.bintray.com/com/android/tools/build/gradle/2.2.0/gradle-2.2.0.jar
  66. Download https://jcenter.bintray.com/com/android/tools/build/gradle-core/2.2.0/gradle-core-2.2.0.jar
  67. Download https://jcenter.bintray.com/com/android/tools/build/builder/2.2.0/builder-2.2.0.jar
  68. Download https://jcenter.bintray.com/com/android/tools/lint/lint/25.2.0/lint-25.2.0.jar
  69. Download https://jcenter.bintray.com/com/android/tools/build/transform-api/2.0.0-deprecated-use-gradle-api/transform-api-2.0.0-deprecated-use-gradle-api.jar
  70. Download https://jcenter.bintray.com/com/android/tools/build/gradle-api/2.2.0/gradle-api-2.2.0.jar
  71. Download https://jcenter.bintray.com/com/android/databinding/compilerCommon/2.2.0/compilerCommon-2.2.0.jar
  72. Download https://jcenter.bintray.com/org/ow2/asm/asm-commons/5.0.4/asm-commons-5.0.4.jar
  73. Download https://jcenter.bintray.com/net/sf/proguard/proguard-gradle/5.2.1/proguard-gradle-5.2.1.jar
  74. Download https://jcenter.bintray.com/org/jacoco/org.jacoco.core/0.7.5.201505241946/org.jacoco.core-0.7.5.201505241946.jar
  75. Download https://jcenter.bintray.com/org/jacoco/org.jacoco.report/0.7.5.201505241946/org.jacoco.report-0.7.5.201505241946.jar
  76. Download https://jcenter.bintray.com/com/google/protobuf/protobuf-java/2.5.0/protobuf-java-2.5.0.jar

Configuration on demand is an incubating feature.https://www.cnblogs.com/milovetingtingp/12359710.html   https://ask.csdn.net/questions/253466

  1. // Top-level build file where you can add configuration options common to all sub-projects/modules.
  2. buildscript {
  3. repositories {
  4. jcenter()
  5. mavenCentral()
  6. mavenLocal()
  7. maven {
  8. url 'https://maven.google.com/'
  9. name 'Google'
  10. }
  11. }
  12. dependencies {
  13. classpath "com.android.tools.build:gradle:${project.property('android-plugin.version')}"
  14. }
  15. }
  16. allprojects {
  17. // NOTE: project.group and project.version must be defined before including
  18. // maven-support.gradle since it uses these values...
  19. project.group = ( project.hasProperty('pom.groupId')
  20. ? project.property('pom.groupId') : "" )
  21. project.version =
  22. ( project.hasProperty('pom.version') ? project.property('pom.version') : "1.0" )
  23. apply from: "https://raw.githubusercontent.com/gradle-fury/gradle-fury/v1.1.4/gradle/maven-support.gradle"
  24. // forces all changing dependencies (i.e. SNAPSHOTs) to automagicially download
  25. // (thanks, @BillBarnhill!)
  26. configurations.all {
  27. resolutionStrategy {
  28. cacheChangingModulesFor 0, 'seconds'
  29. }
  30. }
  31. repositories {
  32. jcenter()
  33. mavenCentral()
  34. mavenLocal()
  35. maven { url "https://oss.sonatype.org/content/repositories/snapshots" }
  36. maven { url "https://repo.maven.apache.org/maven2" }
  37. maven {
  38. url 'https://maven.google.com/'
  39. name 'Google'
  40. }
  41. }
  42. tasks.withType(JavaCompile) {
  43. options.encoding = "UTF-8"
  44. }
  45. if (project.hasProperty('profile') && project.profile.split(',').contains("ci")) {
  46. apply from: "${rootDir}/gradle/quality.gradle"
  47. }
  48. }
  49. apply from: "https://raw.githubusercontent.com/gradle-fury/gradle-fury/v1.1.4/gradle/encryption.gradle"
  50. apply from: "https://raw.githubusercontent.com/gradle-fury/gradle-fury/v1.1.4/gradle/site.gradle"
  51. //copy the readme into the site folder as the index
  52. task copyReadme() << {
  53. copy{
  54. from rootDir.absolutePath + "/README.md"
  55. into rootDir.absolutePath + "/src/site/"
  56. rename ("README.md", "index.md")
  57. }
  58. }
  59. site.dependsOn copyReadme

 

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/盐析白兔/article/detail/433945
推荐阅读
相关标签
  

闽ICP备14008679号