Cordova版本:请安装Android目标:“android-22”。我不想要android-22。我想要android-19 - 我该怎么办? [英] Cordova build: Please install Android target: "android-22". I dont want android-22. I want android-19 - what do i do?
问题描述
我在尝试使用我的phonegap设置和构建我的第一个应用程序。
I'm struggling with my phonegap setup and building my first app.
我创建了一个hello1项目。我添加了Android项目
I created a hello1 project. I added the android project
平台已添加
Platform android already added
现在当我运行cordova版本时,会出现错误 -
Now when I run the cordova build, I get the error -
错误:请安装Android目标:android-22
Error: Please install Android target: "android-22"
我没有android-22。我有android-19。我想要我的项目用android-19构建。
I do not have android-22. I do have android-19. I want my project to be built with android-19. How can I make that happen?
我有android-22,我卸载了(修复一个更大的问题)。我不明白我应该改变这个工作的文件。
项目中的 project.properties
在此步骤之后,它自动包含目标为android-22。
I had android-22 which I uninstalled (for fixing a bigger problem). I do not understand which file should I be making a change in for this to work.
The project.properties
in the project comes after this step and it automatically contains the target as android-22.
我已经正确添加了我的env变量。
C:\Users \user\android-sdks\platform-tools; C:\Users\user\android-sdks\tools
I have added my env variables correctly.
C:\Users\user\android-sdks\platform-tools;C:\Users\user\android-sdks\tools
这没有帮助。这只是我想要调试的一个更大的问题的一部分。请帮忙。
It doesn't help. This is just part of a bigger problem that I'm trying to debug. Please help.
推荐答案
对于SDK 21 (android-21)
$ cordova platforms remove android
$ cordova platforms add android@3.7.1
对于SDK 22 (Android 4.1.1, -22
)
For SDK 22 (Android 4.1.1, "android-22"
)
$ cordova platforms remove android
$ cordova platforms add android@4.1.1
更多信息: https://cordova.apache.org/announcements/2015/07/21/cordova-android-4.1.0.html
这篇关于Cordova版本:请安装Android目标:“android-22”。我不想要android-22。我想要android-19 - 我该怎么办?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!