AndroidStudio编译异常Execution failed for task ‘:app:transformClassesWithDesugarForDebug解决方案

报错信息

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:transformClassesWithDesugarForDebug'.
> com.android.build.api.transform.TransformException: java.lang.IllegalArgumentException: java.lang.IllegalArgumentException

* 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

BUILD FAILED in 1s

Execution failed for task ':app:transformClassesWithDesugarForDebug'.
> com.android.build.api.transform.TransformException: java.lang.IllegalArgumentException: java.lang.IllegalArgumentException

* 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.

Execution failed for task ':app:transformClassesWithDesugarForDebug'.
> com.android.build.api.transform.TransformException: java.lang.IllegalArgumentException: java.lang.IllegalArgumentException

* 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.

Cause: java.lang.IllegalArgumentException

完整的报错信息

NDK is missing a "platforms" directory.
If you are using NDK, verify the ndk.dir is set to a valid NDK directory.  It is currently set to C:\Users\huruwo\AppData\Local\Android\Sdk\ndk\23.0.7599858.
If you are not using NDK, unset the NDK variable from ANDROID_NDK_HOME or local.properties to remove this warning.

NDK is missing a "platforms" directory.
If you are using NDK, verify the ndk.dir is set to a valid NDK directory.  It is currently set to C:\Users\huruwo\AppData\Local\Android\Sdk\ndk\23.0.7599858.
If you are not using NDK, unset the NDK variable from ANDROID_NDK_HOME or local.properties to remove this warning.

NDK is missing a "platforms" directory.
If you are using NDK, verify the ndk.dir is set to a valid NDK directory.  It is currently set to C:\Users\huruwo\AppData\Local\Android\Sdk\ndk\23.0.7599858.
If you are not using NDK, unset the NDK variable from ANDROID_NDK_HOME or local.properties to remove this warning.

NDK is missing a "platforms" directory.
If you are using NDK, verify the ndk.dir is set to a valid NDK directory.  It is currently set to C:\Users\huruwo\AppData\Local\Android\Sdk\ndk\23.0.7599858.
If you are not using NDK, unset the NDK variable from ANDROID_NDK_HOME or local.properties to remove this warning.

:app:preBuild UP-TO-DATE
:envdetectionlib:preBuild UP-TO-DATE
:envdetectionlib:preDebugBuild UP-TO-DATE
:envdetectionlib:checkDebugManifest
:envdetectionlib:processDebugManifest
:preheatqqlib:preBuild UP-TO-DATE
:preheatqqlib:preDebugBuild UP-TO-DATE
:preheatqqlib:checkDebugManifest
:preheatqqlib:processDebugManifest
:wechatloginlib:preBuild UP-TO-DATE
:wechatloginlib:preDebugBuild UP-TO-DATE
:wechatloginlib:checkDebugManifest
:wechatloginlib:processDebugManifest
:app:preDebugBuild
:envdetectionlib:compileDebugAidl
:preheatqqlib:compileDebugAidl
:wechatloginlib:compileDebugAidl
:app:compileDebugAidl
:envdetectionlib:packageDebugRenderscript NO-SOURCE
:preheatqqlib:packageDebugRenderscript NO-SOURCE
:wechatloginlib:packageDebugRenderscript NO-SOURCE
:app:compileDebugRenderscript
:app:checkDebugManifest
:app:generateDebugBuildConfig
:app:prepareLintJar UP-TO-DATE
:app:mainApkListPersistenceDebug
:app:generateDebugResValues
:app:generateDebugResources
:envdetectionlib:compileDebugRenderscript
:envdetectionlib:generateDebugResValues
:envdetectionlib:generateDebugResources
:envdetectionlib:packageDebugResources
:preheatqqlib:compileDebugRenderscript
:preheatqqlib:generateDebugResValues
:preheatqqlib:generateDebugResources
:preheatqqlib:packageDebugResources
:wechatloginlib:compileDebugRenderscript
:wechatloginlib:generateDebugResValues
:wechatloginlib:generateDebugResources
:wechatloginlib:packageDebugResources
:app:mergeDebugResources
:app:createDebugCompatibleScreenManifests
:app:processDebugManifest
:app:splitsDiscoveryTaskDebug
:envdetectionlib:platformAttrExtractor
:preheatqqlib:platformAttrExtractor
:wechatloginlib:platformAttrExtractor
:envdetectionlib:generateDebugBuildConfig
:envdetectionlib:prepareLintJar UP-TO-DATE
:envdetectionlib:javaPreCompileDebug
:envdetectionlib:processDebugJavaRes NO-SOURCE
:preheatqqlib:generateDebugBuildConfig
:preheatqqlib:prepareLintJar UP-TO-DATE
:preheatqqlib:javaPreCompileDebug
:preheatqqlib:processDebugJavaRes NO-SOURCE
:wechatloginlib:generateDebugBuildConfig
:wechatloginlib:prepareLintJar UP-TO-DATE
:wechatloginlib:javaPreCompileDebug
:wechatloginlib:processDebugJavaRes NO-SOURCE
:app:compileDebugNdk NO-SOURCE
:app:mergeDebugShaders
:app:compileDebugShaders
:app:generateDebugAssets
:envdetectionlib:mergeDebugShaders
:envdetectionlib:compileDebugShaders
:envdetectionlib:generateDebugAssets
:envdetectionlib:packageDebugAssets
:preheatqqlib:mergeDebugShaders
:preheatqqlib:compileDebugShaders
:preheatqqlib:generateDebugAssets
:preheatqqlib:packageDebugAssets
:wechatloginlib:mergeDebugShaders
:wechatloginlib:compileDebugShaders
:wechatloginlib:generateDebugAssets
:wechatloginlib:packageDebugAssets
:app:mergeDebugAssets
:app:mergeDebugJniLibFolders
:envdetectionlib:compileDebugNdk NO-SOURCE
:envdetectionlib:mergeDebugJniLibFolders
:envdetectionlib:transformNativeLibsWithMergeJniLibsForDebug
:envdetectionlib:transformNativeLibsWithIntermediateJniLibsForDebug
:preheatqqlib:compileDebugNdk NO-SOURCE
:preheatqqlib:mergeDebugJniLibFolders
:preheatqqlib:transformNativeLibsWithMergeJniLibsForDebug
:preheatqqlib:transformNativeLibsWithIntermediateJniLibsForDebug
:wechatloginlib:compileDebugNdk NO-SOURCE
:wechatloginlib:mergeDebugJniLibFolders
:wechatloginlib:transformNativeLibsWithMergeJniLibsForDebug
:wechatloginlib:transformNativeLibsWithIntermediateJniLibsForDebug
:app:processDebugJavaRes NO-SOURCE
:app:validateSigningDebug
:envdetectionlib:generateDebugRFile
:envdetectionlib:generateDebugSources
:envdetectionlib:compileDebugJavaWithJavacע: ijЩ�����ļ�ʹ�û򸲸����ѹ�ʱ�� API��
ע: �й���ϸ��Ϣ, ��ʹ�� -Xlint:deprecation ���±��롣

:envdetectionlib:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug
:preheatqqlib:generateDebugRFile
:preheatqqlib:generateDebugSources
:preheatqqlib:compileDebugJavaWithJavacע: ijЩ�����ļ�ʹ�û򸲸����ѹ�ʱ�� API��
ע: �й���ϸ��Ϣ, ��ʹ�� -Xlint:deprecation ���±��롣
ע: ijЩ�����ļ�ʹ����δ�����򲻰�ȫ�IJ�����
ע: �й���ϸ��Ϣ, ��ʹ�� -Xlint:unchecked ���±��롣

:preheatqqlib:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug
:wechatloginlib:generateDebugRFile
:app:processDebugResources
:app:generateDebugSources
:wechatloginlib:generateDebugSources
:wechatloginlib:compileDebugJavaWithJavacע: E:\work_project\zx_work\GitProject\XubeiSdkTool\wechatloginlib\src\main\java\com\android\wc\login\common\AndroidInfoUtil.javaʹ�û򸲸����ѹ�ʱ�� API��
ע: �й���ϸ��Ϣ, ��ʹ�� -Xlint:deprecation ���±��롣

:wechatloginlib:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug
:app:javaPreCompileDebug
:app:compileDebugJavaWithJavacע
  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值