Database Reference
In-Depth Information
NOTE
You can download Ant from http://ant.apache.org . You don't need to download Ivy separately just to
build Cassandra.
Ivy requires Ant, and building from source requires the complete JDK, version 1.6.0_20 or bet-
ter, not just the JRE. If you see a message about how Ant is missing tools.jar, either you don't
have the full JDK or you're pointing to the wrong path in your environment variables.
NOTE
If you want to download the most cutting-edge builds, you can get the source from Hudson, which the
Cassandra project uses as its Continuous Integration tool. See http://hudson.zones.apache.org/hudson/
job/Cassandra/ for the latest builds and test coverage information.
If you are a Git fan, you can get a read-only trunk version of the Cassandra source using this
command:
>git clone git://git.apache.org/cassandra.git
NOTE
Git is a source code management system created by Linus Torvalds to manage development of the Linux
kernel. It's increasingly popular and is used by projects such as Android, Fedora, Ruby on Rails, Perl,
and many Cassandra clients (as we'll see in Chapter 8 ) . If you're on a Linux distribution such as Ubuntu,
it couldn't be easier to get Git. At a console, just type >apt-getinstallgitand it will be installed and ready
for commands. For more information, visit http://git-scm.com/ .
Because Ivy takes care of all the dependencies, it's easy to build Cassandra once you have the
source. Just make sure you're in the root directory of your source download and execute the ant
program, which will look for a file called build.xmlin the current directory and execute the de-
fault build target. Ant and Ivy take care of the rest. To execute the Ant program and start com-
piling the source, just type:
>ant
That's it. Ivy will retrieve all of the necessary dependencies, and Ant will build the nearly 350
source files and execute the tests. If all went well, you should see a BUILD SUCCESSFUL message.
If all did not go well, make sure that your path settings are all correct, that you have the most re-
cent versions of the required programs, and that you downloaded a stable Cassandra build. You
can check the Hudson report to make sure that the source you downloaded actually can compile.
Search WWH ::




Custom Search