#Android Gradle Build Error
1 messages · Page 1 of 1 (latest)
Looks like this might be the specific part of the error that is relevant:
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.codehaus.groovy.vmplugin.v7.Java7$1 (file:/Users/blazing/.gradle/wrapper/dists/gradle-5.1.1-bin/90y9l8txxfw1s2o6ctiqeruwn/gradle-5.1.1/lib/groovy-all-1.0-2.5.4.jar) to constructor java.lang.invoke.MethodHandles$Lookup(java.lang.Class,int)
WARNING: Please consider reporting this to the maintainers of org.codehaus.groovy.vmplugin.v7.Java7$1
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
FAILURE: Build failed with an exception.
* Where:
Build file '/Users/blazing/UnityProjects/EasyMLDemo/Temp/PlayServicesResolverGradle/PlayServicesResolver.scripts.download_artifacts.gradle' line: 1025
* What went wrong:
Execution failed for task ':process_androidx.annotation.annotation-experimental-1.4.0.aar'.
> Unsupported class file major version 61
* 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 2m 3s```
Looks like one of the linked packages isn't compatible with the java version unity is using?
Hi
Do you have any other plugins installed?
Can you please try this?
- Enable Custom Main Gradle Template option
- Force Resolve libraries from EDMU
- Try making a build
I’ve done this in just an empty project with just the easy ml kit plug-in, as well as my existing project - both the same. Will try custom main gradle template shortly and let you know…
OK Enabling Custom Main Gradle Template (and also Custom Gradle Properties Template which EDMU said was needed), Force Resolve completes successfully.
Building for android failed, but I ran EDMU -> Delete Resolved Libraries, deleted the files in Plugins/Android/**.aar and then resolved again and built and it worked 👍
Playing around with it a bit further now, my game is crashing running out of memory when barcode scanning is in action but i will debug that more myself now