I this documentation:
Cordova documentation
I cloned the latest Cordova here: https://github.com/apache/cordova-android
But when I run "ant jar" as described in the documentation, I get this error:
cordova-android-master/framework/build.xml:124: Cannot find /Users/neigaard/Library/Android/sdk/tools/ant/build.xml imported from /Users/me/cordova-android-master/framework/build.xml
Google say that is because ant/build.xml
was removed from Android SDK. I found a post saying that I should download a old Android SDK tools and replace my SDK tools folder with that, but I rely on my Android SDK to be working and up to date.
Is there no way to build the Cordova Android jar without an outdated Android SDK or is there somewhere I can download a pre-built jar or is there another way to integrate Cordova into a existing Android app?
Cordova-Android requires the Android SDK, which can be installed on either macOS, Linux, or Windows. For the base system requirements, see the Android Studio's System Requirements.
Install Java Development Kit (JDK) 7 or later.
You don't really need the .jar anymore, Cordova is distributed through gradle, so you can just add this in the dependencies section of your app gradle file:
implementation 'org.apache.cordova:framework:7.1.0'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With