I have a Oculus Go .apk thats about 800mb. It builds but at the last moment throws an error i've not come across in Unity. i've seen this issue raised up in Unity forums, but no definitive answer on who to fix it. I have 3 scenes. One basic landing scene, then two 360 Videos. I've built this app plenty of times to gear vr, revived it for the Oculus go and now I'm running into this problem. Is there a way to bump up the memory? Below is the error. Any help in resolving this is greatly appreciated.
CommandInvokationFailure: Gradle build failed.
/Library/Java/JavaVirtualMachines/jdk1.8.0_131.jdk/Contents/Home/bin/java -classpath "/Applications/Unity/Hub/Editor/2018.1.0f2/PlaybackEngines/AndroidPlayer/Tools/gradle/lib/gradle-launcher-4.0.1.jar" org.gradle.launcher.GradleMain "-Dorg.gradle.jvmargs=-Xmx2048m" "assembleRelease"
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':packageRelease'.
> Java heap space
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED in 13s
The setTestClassesDir(File) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use the setTestClassesDirs(FileCollection) method instead.
The getTestClassesDir() method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use the getTestClassesDirs() method instead.
The ConfigurableReport.setDestination(Object) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use the method ConfigurableReport.setDestination(File) instead.
24 actionable tasks: 14 executed, 10 up-to-date
exit code: 1