Sto provando a creare un'applicazione per PhoneGap ma quando eseguo cordova platform add android
, ottengo l'errore:
Error: An error occured during creation of android sub-project.
/Users/chrisruno/.cordova/lib/android/cordova/3.3.0/bin/node_modules/q/q.js:126
throw e;
^
Error: Please install Android target 19 (the Android newest SDK). Make sure you have the latest Android tools installed as well. Run "android" from your command-line to install/update any missing SDKs or tools.
at /Users/chrisruno/.cordova/lib/android/cordova/3.3.0/bin/lib/check_reqs.js:80:29
at _fulfilled (/Users/chrisruno/.cordova/lib/android/cordova/3.3.0/bin/node_modules/q/q.js:798:54)
at self.promiseDispatch.done (/Users/chrisruno/.cordova/lib/android/cordova/3.3.0/bin/node_modules/q/q.js:827:30)
at Promise.promise.promiseDispatch (/Users/chrisruno/.cordova/lib/android/cordova/3.3.0/bin/node_modules/q/q.js:760:13)
at /Users/chrisruno/.cordova/lib/android/cordova/3.3.0/bin/node_modules/q/q.js:574:44
at flush (/Users/chrisruno/.cordova/lib/android/cordova/3.3.0/bin/node_modules/q/q.js:108:17)
at process._tickCallback (node.js:415:13)
at /usr/local/lib/node_modules/cordova/src/platform.js:282:30
at ChildProcess.exithandler (child_process.js:641:7)
at ChildProcess.EventEmitter.emit (events.js:98:17)
at maybeClose (child_process.js:743:16)
at Process.ChildProcess._handle.onexit (child_process.js:810:5)
Ho eseguito brew install android-sdk
prima della mano. Ho anche eseguito android
e ho detto che ero già sul 19. Sto installando 20 e 4.3, 4.2, 4.1.2 e 4.0 ora per vedere se soddisferà qualche tipo di dipendenza.
Questo è il mio ~ / .profile:
export PATH="/usr/local/Cellar/android-sdk/22.6.2/tools:$PATH"
L'ho provato anche con questo:
PATH=$PATH:/Applications/Eclipse/Android\ SDK/platform-tools:/Applications/Eclipse/Android\ SDK/tools
export PATH