Getting Java and Ant
From Whirled
This is part of the Setting up your programming environment tutorial.
Contents |
Windows
- Install the Java JDK (this example is being tested with JDK 5 - the standard version, not the NetBeans or EE versions).
- On Windows you will not need to install Ant as you can use the batch files to build and test your game.
- After your JDK installation, you should be able to go to your cmd line, type "java -version", and get an output that looks similar to
c:\Documents and Settings\xxx>java -version java version "1.5.0_16" Java<TM> 2 Runtime Environment, Standard Edition <build 1.5.0_16-b02> Java HotSpot<TM> Client VM <build 1.5.0_16-b02, mixed mode, sharing>
Unix
- Install the Java JDK (this example is being tested with JDK 5) and set your JAVA_HOME environment variable to the directory in which you installed the JDK.
- Get and install the Ant build environment. You may have it installed already. Run the following at in your command shell:
% ant -version Apache Ant version 1.7.0 compiled on September 23 2007
If you get a message telling you the version of ant, then you are set and ready to proceed to the Get Flex section. But if you don't get that message, you'll need to download and install Ant, per sections below:
Under Ubuntu or Debian, type the following to install Ant:
% sudo apt-get install ant
If you're running another Unix dialect, you can download an appropriate distribution from: http://ant.apache.org/
Mac OS X
Depending on the Mac operating system you have installed, you might already have both Java and ant installed. Try typing the following on a command line.
bash-3.2$ java -version java version "1.5.0_13" Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_13-b05-237) Java HotSpot(TM) Client VM (build 1.5.0_13-119, mixed mode, sharing)
bash-3.2$ ant -version Apache Ant version 1.7.0 compiled on September 23 2007
If one or both of them is not installed, then you will need to
- Install the Java JDK (this example is being tested with JDK 5) and set your JAVA_HOME environment variable to the directory in which you installed the JDK.
- Install MacPorts, and then run
% sudo port install apache-ant
Next Step
- Now move on to Getting the Flex SDK

