I was using eclipse ide to build apk file . Now i want to create apk file in command line in linux. But when i say ant debug it gives following error :
Unable to obtain resource from anttasks.jar
java.util.zip.ZipException : error in opening zip file
Problem : failed to create task or type checkenv
Cause : The name is undefined
Action : Check the spelling
Action : Check that any custom tasks/types have been declared
Action : Check that any <presetdef>/<macrodef> declarations have taken place
I have ant version 1.9.2 . and android version 17. I have build.xml file .
Edit : I changed my ant version into 1.8.0 , But whatever i do still i am getting those failed to create task or type checkenv error .
In the Android menu, go to Build > Build Bundle(s) / APK (s) > Build APK(s). Android Studio will start building the APK for you. Once done, a pop-up on the bottom right will notify you of its completion.
The Gradle build is a process of creating a Gradle project. When we run a gradle command, it will look for a file called build. gradle in the current directory. This file is also called the Gradle build script. The build configuration, tasks, and plugins are described in this file.
Check this following developer link
http://developer.android.com/tools/building/building-cmdline.html
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