Error while trying generates Ionic apk v2

Asked

Viewed 298 times

1

Commando:

 ionic build android --prod

Environment variables:

ANDROID_HOME

C:\Android\sdk

CLASSPATH

.;%JAVA_HOME%

JAVA_HOME

C:\Program Files (x86)\Java\jdk1.8.0_121

Path

;%JAVA_HOME%\bin

Error:

Error: Could not find gradle wrapper within Andorid SDK. Might need to update your Android SDK.
Looked here: C:\Users\Octávio Barbosa\AppData\Local\Android\sdk\tools\templates\gradle\wrapper

Does anyone know what it can be?

  • If you have the android studio installed open the project with him, then he himself already resolves these things (usually)

1 answer

2


Good afternoon friend,

I also had this problem with IONIC2, I think you have to configure the following system variables configured:

JAVA_HOME: C: Program Files Java jdk1.8.0_65 (Location of your JDK)

ANDROID_HOME: C: android-sdk-eclipse-adt-M4 sdk programs (Location where the android SDK is)

In your PATH, you will join with the paths that already exist

PATH: C: Program Files nodejs ;%JAVA_HOME% bin;%ANDROID_HOME% tools;%ANDROID_HOME% Platform-tools;

Observing: in the path variable, placed above, I am concatenating the paths of Node, java and android tools and Platform

Browser other questions tagged

You are not signed in. Login or sign up in order to post.