我无法构建我的应用,请帮助我。我尝试了在互联网上看到的所有内容:
没有任何效果。
我正在使用jdk 1.8.161(我尝试过这些; 191、181,但仍然无法正常工作)
我的项目中没有统一广告。
CommandInvokationFailure: Gradle build failed.
C:/Program Files/Java/jdk1.8.0_161\bin\java.exe -classpath "C:\Program Files\Unity\Editor\Data\PlaybackEngines\AndroidPlayer\Tools\gradle\lib\gradle-launcher-5.1.1.jar" org.gradle.launcher.GradleMain "-Dorg.gradle.jvmargs=-Xmx4096m" "assembleRelease"
stderr[
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':checkReleaseDuplicateClasses'.
> 1 exception was raised by workers:
java.lang.RuntimeException: Duplicate class com.google.unity.BuildConfig found in modules classes.jar (:googlemobileads-unity:) and unity-plugin-library.jar (unity-plugin-library.jar)
Duplicate class com.google.unity.ads.AdNetworkExtras found in modules classes.jar (:googlemobileads-unity:) and unity-plugin-library.jar (unity-plugin-library.jar)
Duplicate class com.google.unity.ads.Banner found in modules classes.jar (:googlemobileads-unity:) and unity-plugin-library.jar (unity-plugin-library.jar)
Go to the documentation to learn how to <a href="d.android.com/r/tools/classpath-sync-errors">Fix dependency resolution errors</a>.
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUİLD FAILED in 1m 40s
]
stdout[
> Task :preBuild UP-TO-DATE
> Task :GoogleMobileAdsPlugin:preBuild UP-TO-DATE
> Task :GoogleMobileAdsPlugin:preReleaseBuild UP-TO-DATE
> Task :GoogleMobileAdsPlugin:checkReleaseManifest
> Task :GoogleMobileAdsPlugin:processReleaseManifest
> Task :checkReleaseManifest
> Task :generateReleaseBuildConfig
> Task :prepareLintJar
> Task :generateReleaseSources
> Task :GoogleMobileAdsPlugin:compileReleaseRenderscript NO-SOURCE
> Task :GoogleMobileAdsPlugin:generateReleaseRFile
> Task :GoogleMobileAdsPlugin:prepareLintJar
> Task :GoogleMobileAdsPlugin:generateReleaseSources
> Task :GoogleMobileAdsPlugin:javaPreCompileRelease
> Task :GoogleMobileAdsPlugin:compileReleaseJavaWithJavac
> Task :GoogleMobileAdsPlugin:bundleLibCompileRelease
> Task :javaPreCompileRelease
> Task :mainApkListPersistenceRelease
> Task :generateReleaseResValues
> Task :generateReleaseResources
> Task :mergeReleaseResources
> Task :createReleaseCompatibleScreenManifests
> Task :processReleaseManifest
> Task :processReleaseResources
> Task :compileReleaseJavaWithJavac
> Task :GoogleMobileAdsPlugin:mergeReleaseShaders
> Task :GoogleMobileAdsPlugin:compileReleaseShaders
> Task :GoogleMobileAdsPlugin:generateReleaseAssets
> Task :GoogleMobileAdsPlugin:packageReleaseAssets
> Task :mergeReleaseAssets
> Task :validateSigningRelease
> Task :signingConfigWriterRelease
> Task :checkReleaseDuplicateClasses FAILED