Cordova 6.5.0. Failed to build android apps after updating android studio to 2.3.1 and SDK tools

时光怂恿深爱的人放手 提交于 2019-12-11 04:43:48

问题


I am working on three different phonegap projects, I was able to build to android platform until I did the biggest thing I regret for it "UPDATE"

Previously I was able to use command phonegap build android or cordova build android, and the build was successful with no errors

But after update I found the first problem :

Error: Android SDK not found. Make sure that it is installed. If it is not at the default location, set the ANDROID_HOME environment variable.

Although, Android_home was set before, but I ensured it again. then I tried to build but failed for same error. Later I found solution on this thread Installing-Android-SDK-Tools

I downloaded tools_r25.2.3-windows.zip and extracted contents to sdk folder, then problem (ANDROID_HOME not found) Solved!!

After that I tried to phonegap build android, then I got this error

Error: Error code 1 for command: cmd with args: /s,/c,"D:\myProject\platforms\android\gradlew cdvBuildDebug -b D:\myProject\platforms\android\build.gradle -Dorg.gradle.daemon=true -Pandroid.useDeprecatedNdk=true"

I got mad, even I tried to create new project phonegap create myApp and moved content of www folder and config.xml, then phonegap build android, but no luck Failed again for same reason mentioned above

来源:https://stackoverflow.com/questions/43714710/cordova-6-5-0-failed-to-build-android-apps-after-updating-android-studio-to-2-3

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!