更新Android Studio及更新targetSdkVersion 33 后的问题解决

Invoke-customs are only supported starting with android 0 –min-api 26

https://stackoverflow.com/questions/49891730/invoke-customs-are-only-supported-starting-with-android-0-min-api-26

按照网上办法设java1.8,不起作用。最后按照编译时报错的最后一页,点击上面的解决方案,去设置,解决此问题。不明所以。

Unable to make field private final java.lang.String java.io.File.path accessible: module java.base does not “opens java.io” to unnamed module

修改Gradle Plugin版本与Gradle版本匹配。


修改gradle的java版本

gradle.properties

增加一行

org.gradle.java.home=

Apps targeting Android 12 and higher are required to specify an explicit value for android:exported when the corresponding component has an intent filter defined.

Manifest中启动activity增加android:exported

发表评论

电子邮件地址不会被公开。 必填项已用*标注