I’m getting this error when I try to build Android. Any advice will be greatly appreciated!
Error: Could not find gradle wrapper within Android SDK. Might need to update your Android SDK.
Update your Android SDK.
Best just install Android Studio as it will take care of all of that.
Also make sure you are using the most recent Cordova and cordova-android versions.
I don’t know what files these are.
Yes, I’ve done all the installations from Android Studio (not via the terminal).
Thanks!
Hi Sujan! Thanks for your help!
With those files I don’t have a problem anymore. I’ve updated my ionic and cordova, and it went away. Now I’m stuck this this error ONLY:
Error: ../platforms/android/gradlew: Command failed with exit code ENOENT
Ioni info:
Your system information:
Cordova CLI: 6.5.0
Ionic Framework Version: 2.0.1
Ionic CLI Version: 2.1.14
Ionic App Lib Version: 2.1.7
Ionic App Scripts Version: 1.1.3
ios-deploy version: 1.9.0
ios-sim version: 5.0.12
OS: macOS Sierra
Node Version: v7.10.0
Xcode version: Xcode 8.3.2 Build version 8E2002
NPM version - 4.2.0
I’m not sure how to get ionic cordova requirements
, this command doesn’t work in my terminal.
Many thanks!
Done! My CLI is now 3.4.0
I’ve removed the platform and added it again, then ran a cordova build command, and get these errors now:
cp: no such file or directory: /Users/podoliev/Library/Android/sdk/tools/templates/gradle/wrapper/gradlew
cp: no such file or directory: /Users/podoliev/Library/Android/sdk/tools/templates/gradle/wrapper/gradle/wrapper
chmod: File not found:
/Users/username/Documents/Development/app/platforms/android/gradle/wrapper/gradle-wrapper.properties
sed: no such file or directory:
/Users/username/Documents/Development/app/platforms/android/gradle/wrapper/gradle-wrapper.properties
Error: /Users/username/Documents/Development/app/platforms/android/gradlew: Command failed with
exit code ENOENT
Here what I got from this:
Requirements check results for android:
Java JDK: installed 1.8.0
Android SDK: installed true
Android target: not installed
Android SDK not found. Make sure that it is installed. If it is not at the default location, set the ANDROID_HOME environment variable.
Gradle: not installed
Could not find gradle wrapper within Android SDK. Might need to update your Android SDK.
Looked here: /Users/user/Library/Android/sdk/tools/templates/gradle/wrapper
Requirements check results for ios:
Apple OS X: installed darwin
Xcode: installed 8.3.2
ios-deploy: installed 1.9.0
CocoaPods: installed
Error: Some of requirements check failed
┌──────────────────────────────────────────┐
│ Update available: 7.0.1 (current: 6.5.0) │
│ Run npm install -g cordova to update. │
└──────────────────────────────────────────┘
Old thread, but just in case someone else is stuck. I came across this on an older project and solved it by updating cordova globally, and the local platform package :
npm install -g cordova
cd my_project
cordova platform update android
Cordova guidelines (https://cordova.apache.org/announcements/2017/04/05/android-release.html)
Doing so also updated the my gradle config which somehow had gotten out of date.