Building Android Apps Dependencies [needs revision]

Some errors I came accross when trying out to build Ionic Android app following getting started tutorial.

I’m writing it 1 day later therefor it might not be all correct, but still might give a hint what to do for others (and future me).

Error: Missing Cordova

Solution:

sudo npm install -g cordova

ERROR: Error: ANDROID_HOME is not set and “android” command not in your PATH. You must fulfill at least one of these conditions.

Solution:

  1. Download and install SDK or Android Studio
  2. Edit ~/bash_profile and add so you don’t have to run these commands again:

Best thing about installing Android Studio is that it installs default SDK’s, system images and HAX acceleration:

Android AVD HAX accelleration running

export ANDROID_HOME=/<installation location>/android-sdk-macosx # export ANDROID_HOME=~/Library/Android/sdk export PATH=${PATH}:$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools export PATH=${PATH}:$ANDROID_HOME/tools:$ANDROID_HOME/tools/

ERROR: Error: Please install Android target “android-19”.

Hint: Run “android” from your command-line to open the SDK manager.

Solution:

$ android
Error: Please install Android target "android-19". Hint: Run "android" from your command-line to open the SDK manager.

Error: Ant

Solution: Install Bower, than install Ant

bower install ant