How do i solve this problem when trying to build my ionic android app



Total time: 14.48 secs
Error: /home/matynjr/techlyt/platforms/android/gradlew: Command failed with exit code 1 Error output:
FAILURE: Build failed with an exception.

  • Where:
    Build file ‘/home/matynjr/techlyt/platforms/android/build.gradle’ line: 20

  • What went wrong:
    A problem occurred evaluating root project ‘android’.

java.lang.UnsupportedClassVersionError: com/android/build/gradle/AppPlugin : Unsupported major.minor version 52.0

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.


IGNORE ----- It’s telling you the versioning of the app is wrong. Could you show us your config.xml? Because I’m thinking you’re missing a dot in your versioning over there. ----

Edit: Go with @rapropos’ answer.


You must use JDK 1.8, and you are not.


thanks alot my issue was solved i just set my java home environment and it worked