Is it necessary to compile my cocos2dx project using command line if i use android studio.

  • freela
    Likes 0

    Problem Description

    Hello Team SonarLearning

    Thankyou for your continious help.

    i have a cocos2dx project. After my hard disk crashed, i have installed all the new softwares and sdks. After installing new version of softwares, i have successfully tested my app in  android device using android studio, and in iphone using xcode. while trying to complile using command line (cocos compile -p android --android-studio) compilation failed and i found following error.

    Initialized native services in: /Users/freela/.gradle/native

    FAILURE: Build failed with an exception.

    * What went wrong:
    Could not determine java version from '10.0.1'.

    * Try:
    Run with --stacktrace option to get the stack trace. Run with --debug option to get more log output.
    Error running command, return code: 1.

    Now my question is, Is it necessary to compile my project using commandline, if i am using android studio? If command line compiation is not necessary while using android studio, i will leave this error, otherwise i should solve it.

    Thanks in advance


  • Sonar Systems admin
    Likes 0

    Yes       


    This reply has been verified.
  • freela
    Likes 0

    Thankyou for your answer.

    I was stuck in some other project for about a week,k now i am back to project.

    I have tried to solve abve errors, i am unable to solve it last last day, What may be the probable issue and its solution. Any help will be highly appreciable.

    Initialized native services in: /Users/freela/.gradle/native

    FAILURE: Build failed with an exception.

    * What went wrong:
    Could not determine java version from '10.0.1'.

    * Try:
    Run with --stacktrace option to get the stack trace. Run with --debug option to get more log output.
    Error running command, return code: 1.


  • freela
    Likes 0

    Its now solved. I have installed a new version of jdk which was creating problem, Now i have installed old version of jdk and it worked.


  • Sonar Systems admin
    Likes 0

    Good to hear it is working now, if you have anymore queries will free to post it on this website.

Login to reply