Recently I started working on an Android App and after some initial problems with the new Android Studio based on IntelliJ I am back on a regular maven build process. But when setting up my project with the current version of the “old” Android IDE based on Eclipse and the Maven Android Plugin I stumbled upon some errors when trying to build the project:
Failed to execute goal com.jayway.maven.plugins.android.generation2:android-maven-plugin:3.1.1:generate-sources (default-generate-sources) on project tutorial: Execution default-generate-sources of goal com.jayway.maven.plugins.android.generation2:android-maven-plugin:3.1.1:generate-sources failed: Could not find tool 'aapt'. Please provide a proper Android SDK directory path as configuration parameter <sdk><path>...</path></sdk> in the plugin <configuration/>. As an alternative, you may add the parameter to commandline: -Dandroid.sdk.path=... or set environment variable ANDROID_HOME. -> [Help 1]
Because I am working on different machines, I had to fix this on at least one windows box too:
The original answer is available on StackOverflow and I also added my windows version of the commands as a comment to that answer.