报错:

Errors occurred while build effective model from E:\gradle-7.0\bin\caches\modules-2\files-2.1\com.google.zxing\core\3.4.0\b7eab116a61512d8b669efcd69446cc45243bd28\core-3.4.0.pom:
‘dependencyManagement.dependencies.dependency.systemPath’ for com.google.android:android:jar must specify an absolute path but is /${env.ANDROID_HOME}/platforms/android-22/android.jar in com.google.zxing:core:3.4.0

FAILURE: Build failed with an exception.

  • What went wrong:
    Failed to notify build listener.
    org.gradle.api.artifacts.result.ComponentSelectionReason.getDescription()Ljava/lang/String;

原因:IDEA版本的发行日期低于gradle版本的发行日期。就是gradle太新了,IDEA不兼容。

解决方案:更换gradle版本为当前使用的IDEA版本发行日期之前的(或升级IDEA版本)。

Logo

鸿蒙生态一站式服务平台。

更多推荐