However its is a LOT simpler than that. Just install XCode 3.0 TOOLS, from the optional installs section of your Leopard distribution disk and it will install and setup
/usr/share/ant -> ant-1.7.0
/usr/share/maven -> maven-2.0.6
/usr/share/junit -> junit-4.1
and it will throw cvs, subversion and a multitude of other tools in for good measure. Unfortunately Xcode 3 wont run on Tiger (10.4.x), where you are stuck with Xcode 2.5, which may not setup all this goodness, but since i dont have a Tiger Machine anymore, i cant verify this.
So: to start the investigation of the java frameworks/platforms listed above, I just added the following to the end of my /etc/profile, to make sure the packages can find the installed goodies.
JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/1.5/Home; export JAVA_HOME
ANT_HOME=/usr/share/ant; export ANT_HOME
MAVEN_HOME=/usr/share/maven; export MAVEN_HOME
JUNIT_HOME=/usr/share/junit; export JUNIT_HOME