Ionic build android failed


#1

Hello Guys,

Error: Could not find gradle wrapper within Android SDK. Might need to update your Android SDK.
Looked here: /Users/owais/Library/Android/sdk/tools/templates/gradle/wrapper

Whenever i run ionic build android the above error is generated. Anyone who has faced and solved the issue please let me know :slight_smile:
Thanks


#2

Have you installed the android SDK via android studio or the android SDK standalone installer?


#3

Yes I have installed android SDK @kgaspar … also the paths are defines as you can see in the error message

Error: Could not find gradle wrapper within Android SDK . showing the error of gradle wrapper in android sdk… and when I go to the path given in error

Looked here: /Users/owais/Library/Android/sdk/tools/templates/gradle/wrapper
I actually could not find any template folder here


#4

Yes I have installed android SDK @kgaspar … also the paths are defines as you can see in the error message

Error: Could not find gradle wrapper within Android SDK . showing the error of gradle wrapper in android sdk… and when I go to the path given in error

Looked here: /Users/owais/Library/Android/sdk/tools/templates/gradle/wrapper
I actually could not find any template folder here


#5

Have you checked this thread here. It is the same problem as yours. :slight_smile:


#6

Ok I am trying this… Hope for the best :slight_smile:


#7

i had the same problem.i followed another answer on a post here and it worked
here s what i did:i downloaded sdk tools package https://dl.google.com/android/repository/tools_r25.2.3-windows.zip then you extract it to C:\Users\CURRENT_USER\AppData\Local\Android\sdk.
you 'll need to replace the current user.then build again.this worked for me
here’s the link to that post if you want to
https://forum.ionicframework.com/t/error-could-not-find-gradle-wrapper-within-android-sdk-might-need-to-update-yo-ur-android-sdk/22056
and check trisna1192 answer


#8

Yes I am going to try the same one :slight_smile: thanks @redamed92


#9

You won’t need these hacky solutions any more, see my post over there:


#10

Yeah It worked… Thankyou Dear


#11

In case you are stuck with this issue in Ubuntu, please check a possible fix here:

Good luck,
Gustavo.