-1

How do I fix these errors when I try to build a project leaving these errors:

1)CommandInvokationFailure: Gradle build failed.

2)Build completed with a result of 'Failed' in 287 seconds

3)UnityEditor.BuildPlayerWindow+BuildMethodException: 3 errors at UnityEditor.BuildPlayerWindow+DefaultBuildMethods.BuildPlayer (UnityEditor.BuildPlayerOptions options) [0x002ca] in <22954a70fcec46f29620f943d3d7bf23>:0 at UnityEditor.BuildPlayerWindow.CallBuildMethods (System.Boolean askForBuildLocation, UnityEditor.BuildOptions defaultBuildOptions) [0x00080] in <22954a70fcec46f29620f943d3d7bf23>:0 UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)

enter image description here

enter image description here

5
  • See 2nd error on bottm with red exclamation point. Looks like either Android has issue of the Java install on machine needs updating.
    – jdweng
    Commented Mar 16, 2021 at 17:54
  • @jdweng Can I then manually install the sdk? Commented Mar 16, 2021 at 17:55
  • @jdweng or should I just reinstall java? Commented Mar 16, 2021 at 17:58
  • Do not know. Just know the OpenJDK is failing or one of its components.
    – jdweng
    Commented Mar 16, 2021 at 18:20
  • @jdweng Thank you very much, right now I'll try Commented Mar 16, 2021 at 18:27

1 Answer 1

-2

Fixed the problem, when running Unity hub, please install the Android platform first.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.