Reputation: 669
I am trying to build android project from command line. I tried to run this line in the command line:
C:\Users\davida\workspace_8\MyApp>ant debug
And this is the answer:
'ant' is not recognized as an internal or external command,
operable program or batch file.
And I tried the android developers http://developer.android.com/tools/building/building-cmdline.html, with no luck.
First, how can I know if I have installed ant on my computer? (if I navigate thru eclipse tool bar to window -> preferences I have window with Ant Menu on the left contains "Editor" and "Runtime") Is it mean that the ant installed and I can build with it from the command line??
I can debug and run with emulator and my device thru eclipse.
After searching I read that I need to set java variables so I did:
JAVA_HOME = C:\Progra~2\Java\jdk1.7.0_01
my OS: win7
Well.. I am lost any help?? If someone have step by step sample I will be glad. Thanks.
Upvotes: 1
Views: 495
Reputation: 10325
First of all you need to ensure that the ant
build system is installed (as it is not bundled with the Android SDK) - you can download ant
from here: http://ant.apache.org/bindownload.cgi.
Secondly, you must ensure that ant
has been added to your PATH
.
Upvotes: 2