Location: JWare Software » AntXtras » Downloads
Downloads
Each JWare/AntXtras Foundation release consists of three packages: binaries, documents, and source. Every package has an associated hash value and a GPG-generated signature so you can verify its integrity. To authenticate a package with any PGP or GnuPG application, download our KEYS file and import it into your public keyring.
Stable Releases
You should use the newest AntXtras v2 or v3 series if possible! For older releases or a full download inventory, visit the AntXtras SF.net release area. Typical contents of a package are described in the included readme-first file. Read our Future Plans section to learn the differences between the v1, v2, and v3 series.
| Package Type | v1 Series [for Ant 1.6] | v2 Series [for Ant 1.7] | v3 Series [for Ant 1.8] |
|---|---|---|---|
| Binaries | antxtras_binaries_0.5.1.zip | antxtras_2.0.1_bin.zip (sig) | antxtras_3.0.0b1_bin.zip (sig) |
| Documents | antxtras_apidocs_0.5.1.zip | antxtras_2.0.1_doc.zip (sha) | antxtras_3.0.0b1_doc.zip (sha) |
| Sources | antxtras_sources_0.5.1.zip | antxtras_2.0.1_src.zip (sig) | antxtras_3.0.0b1_src.zip (sig) |
| ChangeLogs | changelog_0.5.1 | changelog_2.0.1 | changelog_3.0.0b1 |
Compatibility
- v2 series: Sun JaveSE 1.4 and JaveSE 1.5 platforms, Ant 1.7 only, Release Notes.
- v3 series: Sun JaveSE 1.5 and JaveSE 1.6 platforms, Ant 1.8 only, Release Notes, Licenses.
Dependencies
AntXtras only depends on standard JavaSE and Ant packages. However, if you want to use a regular expression implementation other than the builtin JRE one, you will need to download the required third-party package for that implementation. (Read Ant regular expressions for more information on what other implementations Ant supports.)
Installing AntXtras
AntXtras’s installation is similar to any optional Ant package. The following instructions describe how to install and verify AntXtras v2 or v3 in your run-time environment. For older series, see the installation instructions that comes with the distribution.
- Download, verify, and install an Ant distribution— version 1.7.1[v2] or 1.8.0[v3]. Verify that Ant is properly installed. AntXtras only uses components of the standard Ant distribution; optional tasks are not required.
- Download, verify, and install an AntXtras distribution. We suggest you download the binary distribution that contains everything you need to use AntXtras immediately. There is also a sample Ant script you can use to verify the installation is working properly. In the remaining steps we use
<ANTXTRAS_DIR>to refer to the directory into which you extracted the AntXtras distribution.- If you must manually generate all binaries for your environment, download the source-only distribution. Be sure you also download the required third-party libraries. You must use JDK 1.5 or later to compile the v3 sources.
- Update your Ant run-time environment to include the AntXtras jar file
<ANTXTRAS_DIR>/lib/jw-antxtras.jarin its classpath. There are several ways of telling Ant about third-party jar files; the easiest method is to copy the files into your Ant distribution’slibdirectory. A safer approach is to install AntXtras in its own location and update theCLASSPATHused when you run Ant (for example, by using the-liboption; see “Running Ant” for details). You can also specify a classpath directly to the<taskdef>instruction you use to load AntXtras.
- Verify the AntXtras tasks are accessible from Ant. The easiest way to do this is to run Ant against this starter script. From within the
<ANTXTRAS_DIR>/etcdirectory, run`ant -f antxtras-install-check.xml`. This Ant script doesn’t actually do anything except load the AntXtras antlib and print out its version information. If Ant is unable to locate the AntXtras antlib or its dependencies, even this simple script will fail. In the next section, we describe in detail what this starter script is doing.
- Read the Overview page to get an idea of what AntXtras can do for you. This overview includes a list of the AntXtras main components and many examples. Download the “JWare/AntXtras Foundation User Guide” as a thorough off line reference for every AntXtras component and additional examples.
- Start using AntXtras!
Loading AntXtras Antlib
Below are the steps you must follow to use AntXtras after you download and expand the AntXtras ‘_bin’ (binaries-only) distribution. If you downloaded the source distribution, you must adjust the first step below to include the location of your local build of AntXtras.
First-Time User Tip!
1. Defining path to AntXtras
Define where you’ve installed AntXtras using Ant’s <path> components. In this snippet we assume the project′s basedir is the <ANTXTRAS_DIR>/etc directory.
1: <dirname property="root.d" file="${basedir}"/> 2: <path id="jware.path"> 3: <fileset dir="${root.d}/lib"> 4: <include name="jw-antxtras.jar"/> 5: </fileset> 6: </path>
2. Loading AntXtras into Ant
Load the AntXtras antlib into your Ant script using the path previously defined in step 1.
1: <taskdef onerror="failall" 2: resource="org/jwaresoftware/antxtras/install/antlib.xml" 3: classpathref="jware.path"/>
3. Displaying AntXtras version information
Verify you can access AntXtras components from your Ant script. The simplest way to do this is to load the AntXtras version information from a core component and display the information on the Ant console.
1: <target name="about-antxtras"> 2: <vendorinfo name="antxtras"/> 3: <show message="RELEASE: ${antxtras.build.label}"/> 4: </target>
Loading Advanced Antlibs
AntXtras comes with three (3) distinct antlibs to improve maintainability and to partition less-used or test-only functionality from the most-common. To load the whole AntXtras universe (core, advanced, etc.) use the following steps instead of the steps described above which load the core jw-antxtras.jar package only.
1. Defining path to AntXtras
Define where you’ve installed AntXtras using Ant’s <path> components. In this snippet we assume the project’s basedir is the <ANTXTRAS_HOME>/etc directory.
1: <dirname property="root.d" file="${basedir}"/> 2: <path id="jware.path"> 3: <fileset dir="${root.d}/lib"> 4: <include name="*.jar"/> 5: </fileset> 6: </path>
2. Loading all of AntXtras into Ant
Load all of the AntXtras antlibs into your Ant script using the paths previously defined in step 1. We also tell Ant in the first call to <taskdef> to cache the classloader that it constructs to load classes from our “jware.path” under a reference “jware.classloader”. Our subsequent <taskdef> calls can reuse this classloader by using the standard ‘loaderref’ parameter. You can use the same technique to load additional AntXtras-based extensions like Svn4Ant or Log4Ant.
1: <taskdef onerror="failall" 2: resource="org/jwaresoftware/antxtras/install/antlib-advanced.xml" 3: classpathref="jware.path" loaderref="jware.classloader"/>
3. Displaying AntXtras version information
Verify you can access the full suite of AntXtras components from your Ant script. One way you can do this is to load the AntXtras version information defined by a core component via a function shortcut that is defined in an advanced antlib.
1: <target name="about-antxtras"> 2: <show message="RELEASE: ${$vendorinfo:antxtras?label}"/> 3: </target>
Linking to Custom Namespace
We recommend you put the foundation AntXtras components into the default Ant namespace (the ‘empty’ namespace that requires no prefix) as it lets you integrate the various AntXtras components seamlessly with standard Ant components. However, it’s simple to allocate AntXtras to its own namespace if you want. The recommended namespace URI and prefix for AntXtras Foundation is “jwaresoftware.antxtras” and “oja:” respectively. This section shows you how to setup such a configuration in your Ant script.
1. Defining AntXtras XML namespace
Define the namespace prefix for the AntXtras antlib as part of your main script’s root <project> XML element. By default, we use the “oja:” prefix for the “jwaresoftware.antxtras” namespace to refer to AntXtras Foundation components.
1: <project name="antxtras:check" basedir="." xmlns:oja="jwaresoftware.antxtras">
2. Defining path to AntXtras
Define where you’ve installed AntXtras using Ant’s <path> components. See the step 2 from either the “Loading Advanced Antlibs” or “Loading AntXtras Antlib” sections above. Let’s assume you’re loading just the core antlib.
1: <dirname property="root.d" file="${basedir}"/> 2: <path id="jware.path"> 3: <fileset dir="${root.d}/lib"> 4: <include name="jw-antxtras.jar"/> 5: </fileset> 6: </path>
3. Loading AntXtras into Ant
Load the AntXtras antlib into your Ant scripts using the path we defined in step 2. Note that we specify the URI of our declared “oja” namespace using the <taskdef>’s uri parameter.
1: <taskdef onerror="failall" 2: uri="jwaresoftware.antxtras" 3: resource="org/jwaresoftware/antxtras/install/antlib.xml" 4: classpathref="jware.path"/>
4. Displaying AntXtras version information
Verify you can access AntXtras components from your Ant script by using the <oja:vendorinfo> task to get the antlib’s version information.
1: <target name="about-antxtras"> 2: <oja:vendorinfo name="antxtras"/> 3: <oja:show message="RELEASE: ${antxtras.build.label}"/> 4: </target>
Compiling AntXtras
If you would like to compile the source distribution, AntXtras is dependent on a few other open-source products that you must download and install before trying to compile your own AntXtras binaries. If you want to compile and run the AntXtras programmer tests you will need to download the third-party distributions that contains test support files, typically the source distributions.
Main Dependencies:
- v2 series: Apache's Ant 1.7.0 or 1.7.1 (ant.apache.org/), JDK 1.4.x
- v3 series: Apache's Ant 1.8.0 or later, JDK 1.5.x
For Programmer Tests:
- JUnit 3.8.3 (junit.org/)
- v2 series: A regular expression provider like Jarkarta RegExp (jakarta.apache.org/)
As Maven2 POM:
- v2 series: jw-antxtras-2.0.1.pom
- v3 series: jw-antxtras-3.0.0b1.pom
Compiling AntXtras source is straightforward from any IDE. The AntXtras source distribution also includes an ez-build.xml Ant script in the /etc directory that can generate a complete release (antlibs, javadocs, sources). You can update the ez-build.properties file with details from your environment before doing the Ant build. Read the ez-build-README file for details.