Cordova: You may not have the required environment or OS to run this project

后端 未结 12 2069
半阙折子戏
半阙折子戏 2020-12-10 04:24

On Linux Mint 17.1 x86_64, Cordova v4.3.0 gives this error:

$ cordova run android

Running command: /home/naman/test/platforms/android/cordova/run 
WARNING :         


        
相关标签:
12条回答
  • 2020-12-10 04:36

    I got a same error my solution is underlying.

    1. command adb device no result.....
    2. install usb drive for mobile (my phone is lg g3)

    reeboot and command adb device again : result device showing. then tried again 3. ionic run adnroid --device "OK";

    0 讨论(0)
  • 2020-12-10 04:38

    I had the same error building the android platform, and no solution given here could help me. I decided to run the gradlew command shown by cordova, and saw there was a problem with a png file included in the cordova project. After removing it, I managed building the platform again.

    0 讨论(0)
  • 2020-12-10 04:38

    Ubuntu

    If you are having issues on Ubuntu, you may want to try installing the following packages, per the docs:

    sudo dpkg --add-architecture i386
    sudo apt-get update
    sudo apt-get install libncurses5:i386 libstdc++6:i386 zlib1g:i386
    

    You may also need to install this package:

    sudo apt-get install lib32z1
    
    0 讨论(0)
  • 2020-12-10 04:42

    You may need to uninstall the existing app on your device.

    I installed my app on that device from another computer. When I run cordova run android I get

    You may not have the required environment or OS to run this project.

    But when I try to install my apk by adb it told my that the app was already installed. So I uninstalled it an it worked.

    0 讨论(0)
  • 2020-12-10 04:42

    This is just to have one more reason for this error documented here and for them who are still searching for solution.

    When I came accross this error, I tried almost all the solutions listed on the stackoverflow.

    My issue was my device was not getting detected by adb, adb kill-server/start-server also not helped me, ***

    but changing USB port helped.


    0 讨论(0)
  • 2020-12-10 04:51

    Happens when platform is added without internet connection.

    Ensure internet is OK and type :

    cordova platform remove blackberry10

    cordova platform add blackberry10

    Try to build and run :

    cordova run

    Hope this fix your problem, also for other platform

    0 讨论(0)
提交回复
热议问题