[ 
https://issues.apache.org/jira/browse/CB-7752?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14204312#comment-14204312
 ] 

Mark L commented on CB-7752:
----------------------------

I am hitting the same problem, Os X 10.9.5,  cordova 4.0.0.   (Strangely, the 
file structure indicates it's running a cached version of 3.6.  Android SDK 
Built Tools 21.1.1. Using ionic, and running 'ionic platform android' get:
Error: Please install Android target "android-19".
Hint: Run "android" from your command-line to open the SDK manager.
    at 
/Users/[user]/.cordova/lib/npm_cache/cordova-android/3.6.4/package/bin/lib/check_reqs.js:174:19

I looked at check_reqs.js.  There appears to be a faulty regex obtaining the 
android version, but fixing it does not solve the problem (filed issue CB-7994 
"Faulty regex in check_reqs.js").
check_reqs.js obtains the data 'target=android-19' from file:  
~/.cordova/lib/npm_cache/cordova-android/3.6.4/package/framework/project.properties
 .
This is done in the line of code reported by the error message, calling:
output.match(valid_target) ,  where valid_target is "android-19" obtained from 
file project.properties
It's beyond my capability to find output.match() to see how that works, though.
Hope this helps a bit.
I thought that Android Build Tools should work for versions underneath it (so 
that 21.1.1 should work for a target of android-19.

> cordova platform add android won't create platform because it wants 
> android-19 installed
> ----------------------------------------------------------------------------------------
>
>                 Key: CB-7752
>                 URL: https://issues.apache.org/jira/browse/CB-7752
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: CLI
>    Affects Versions: 3.5.0
>         Environment: Mac 10.5.6
> Cordova CLI 3.6.3
>            Reporter: Steve Husting
>              Labels: android, cli
>             Fix For: 3.6.3
>
>
> I followed these steps:
> npm update -g cordova
> cordova -v [returned 3.6.3...]
> cordova create helloCordova
> cd helloCordova
> cordova platform add android
> After the line, "Creating android project..." is the error message: 'Please 
> install Android target "android-19". Hint: Run "android" from your 
> command-line to open the SDK Manager.' 
> I went ahead and ran android to install android-19. Is this really supposed 
> to happen for a new project? I though we were supposed to determine on our 
> own what versions we want to support. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to