ionic build Android | error: No installed build tools found. Please install the Android build tools

后端 未结 27 3478
被撕碎了的回忆
被撕碎了的回忆 2020-11-28 05:25

When I run ionic build android command in root of ionic project, I am getting this error:

FAILURE: Build failed with an exception.

相关标签:
27条回答
  • 2020-11-28 06:06

    Warning for developers using Virtual Machines

    I spent a very long time trying to resolve this issue. I tried everything in this post and many more solutions on the web. However, after many failures and going through what everyone on the web was saying I still couldn't resolve the issue on my VM - which is a Windows 10 image on VMWare Workstation.

    After reviewing all the solutions and descriptions of machines/operating systems people were developing on the glaring difference in my setup was I was developing in a VM.

    Solution: I pulled all my code onto the host machine (Windows 10 OS), reinstalled all the dependencies, and sure as heck it all worked out first go around. After a lot of research I found some warnings that Android Studio has some known issues around installing properly in some VMs. So if you were like me & tried all solutions (many times over) and nothing worked, but you're in a VM, you may need to consider building on your host (or other physical machine)

    0 讨论(0)
  • 2020-11-28 06:08

    I have tried all the above solution. None works. Until I was linked to https://forum.ionicframework.com/t/ionic-v4-no-installed-build-tools-found/152150.

    Apparently, you must run the command as root. Sudo is not enough. You need to change to root user before you can run all the commands.

    0 讨论(0)
  • 2020-11-28 06:11

    I added <preference name="android-minSdkVersion" value="19" /> to my conf.xml and the build was successful.

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