Search Unity

Android build Failing

Discussion in 'Android' started by ry511, Jun 9, 2021.

  1. ry511

    ry511

    Joined:
    Jul 24, 2016
    Posts:
    62
    Hey Everyone,

    I am trying to build for android and am getting the following error logged. I am having trouble telling what exactly is going wrong as there is little info provided.

    FAILURE: Build failed with an exception.
    * What went wrong:
    Execution failed for task ':launcher:packageDebug'.
    > A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
    > java.lang.OutOfMemoryError (no error message)
    * 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 12m 52s

    I have tried increasing Max JVM heap size in Preference > External Tools but that did not change anything. Any other advice on how to resolve this?
     
  2. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,905
    How are you building, via Build Settings window, or Build Configurations?
     
  3. ry511

    ry511

    Joined:
    Jul 24, 2016
    Posts:
    62
    Hey,
    Thanks for getting back to me!

    I am building with a build configuration. The default android one I believe.

    upload_2021-6-9_19-20-46.png
     
  4. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,905
  5. ry511

    ry511

    Joined:
    Jul 24, 2016
    Posts:
    62