0

When I run ionic cordova build android command in root of ionic project, I get this error:

FAILURE: Build failed with an exception.

Where: myAPP/platforms/android/CordovaLib/cordova.gradle' line: 64

What went wrong: A problem occurred evaluating root project 'android'.
No installed build tools found. Please install the Android build tools version 19.1.0 or higher.

My environment variables:

ANDROID_HOME = C:\Program Files\Android\Android Studio\gradle\m2repository\com\android

GRADLE_HOME = C:\Program Files\Android\Android Studio\gradle\gradle-3.2

Path = C:\Program Files\Android\Android Studio\gradle\m2repository\com\android\tools\sdk-common;C:\Program Files\Android\Android Studio\gradle\gradle-3.2\lib;C:\Program Files\Android\Android Studio\gradle\m2repository\com\android\tools\build\builder

Installed build tools (in this folder: C:\Program Files\Android\Android Studio\gradle\m2repository\com\android\tools\build\builder):

2.3.0

2.3.1

2.3.2

2.3.3

In C:\Program Files\Android\Android Studio\gradle\m2repository\com\android\tools\sdk-common folder:

25.3.0

25.3.1

25.3.2

25.3.3

Tio
  • 73
  • 1
  • 2
  • 14
  • Possible duplicate of [this](https://stackoverflow.com/questions/31190355/ionic-build-android-error-no-installed-build-tools-found-please-install-the). When you are at the command line can you do `adb`? – Philip Brack Oct 22 '17 at 15:46
  • 1
    check out this answer. The problem seems to be similar: https://stackoverflow.com/a/42639125/4495917 – Javier Sirgo Oct 23 '17 at 08:02
  • Thanks for both of you, I tried everything from both of the link you sent me. It still doesn't work. Same error message. I downloaded the tools from here: https://dl.google.com/android/repository/sdk-tools-windows-3859397.zip. Then I copied the folders and files in the Android Studio's tools folder. I didn't want to replace those files because the folder and file names are different. It was suggested that I replace them here: https://stackoverflow.com/questions/42613882/error-could-not-find-gradle-wrapper-within-android-sdk-might-need-to-update-yo/42639125#42639125 – Tio Oct 27 '17 at 07:28

0 Answers0