Antishield
Version 0.2 (December 2005)
Introduction
Antishield is an Apache Ant-based installation shield, implemented in Java. The purpose is to provide an easy, platform-independent way of distributing and installing software. To that end, Antishield enables one to specify an installation procedure (in XML format; install.xml) consisting of one or more of the following steps:- readme information;
- configuration of the distribution, including unpacking to specified destination directories;
- installation of the unpacked distribution, by running ant on specified build.xml files;
- finalization of the installation.
Download
The Antishield is provided as open-source software, under the GNU Lesser General Public License.
| Required: | Java 1.5 (or higher), Apache Ant |
| Author: | Geert-Jan M. Kruijff (please mail comments, suggestions, etc. to author) |
| Download: | antishield_v0.2.zip (703KB. December 12 2005) |
| Install: | Unzip the downloaded archive. Included are the code jar (in lib/), and a sample build script and install specification. For using the software, see the description below |
| Platforms: | Platform independent. Tested on Mac OS.X 10.4.3, Linux (SuSe, RedHat, CentOS 4.1) |
Using the Antishield to distribute software
A distribution should include the following components: a start-up script (batch file) to start the shield, an installation specification, and a distribution. Each of these components are briefly described below.Startup script
The startup script should ensure that the environment is set up properly, and then run the Antishield on the installation specification. For setting up the environment it is recommended to use a separate "XYZ-env" file in which the environment variables are defined. This will make it easier for a user to later on include the environment settings into local profiles. Each environment should at least specify the variables $JAVA_HOME and $JAVA_CMD. To start the Antishield, the startup script should add the AntiShield jar and the ant jar to the classpath, and then invoke java: e.g.,
export AISCP=lib/comsys.jar:lib/ant.jar:$CLASSPATH
java -cp $AISCP de.dfki.util.ant.AntiShield install.xml
The installation specification
The Antishield is provided with an installation specification which defines the steps to be taken in installing the distribution. The specification contains components of several types (spec type="XYZ") which are described below.shield
The "shield" component has a title argument, specifying the title of the Antishield window, and an optional logo argument which gives the path to a logo to be displayed in the Antishield.
<spec type="shield" title="CoSy Explorer v1.0 (November 2005) Installation shield" logo="./lib/cosylogo.jpg"/>
readme
The "readme" component has a label argument which specifies how this component will appear in the list of installation steps (e.g. "Read me"). Within the component the "read me" text is specified as individual text lines:
<spec type="readme" label="Read me">
<text text="READ ME"/>
</spec>
config
The "config" component specifies the path to which the distribution should be unpacked, and a list of archives to be unpacked. The element basepath specifies the directory, and whether it is configurable (i.e. a boolean indicating whether the user is prompted whether an alternative installation directory should be used). In addition, there is a package-list of archives. The package-list has an argument directory given where the archives are located, and an argument finishUnpacking. The latter determines the action the shield perform after having unpacked all the archives (default value is wait). Each archive is given as a package with arguments for filename (file), destination path under the basepath (destination), and archive type. The current version of Antishield can handle the following archive types: "zip" (unzip), "gz" (gunzip), "tar" (untar), and "jar" (unjar).
<spec type="config" label="Setting up & unpacking">
<basepath directory="." configurable="false"/>
<package-list directory="distzip" finishUnpacking="wait">
<package file="comsys.mk2.zip" destination="protocode" archivetype="zip"/>
</package-list>
</spec>
install
The "install" component specifies a list of build-files, on which ant should be run.
<spec type="install" label="Installation">
<build-list>
<buildfile file="protocode/comsys.mk2/build.xml"/>
<buildfile file="protocode/comsys.mk2/grammars/openccg/moloko/build.xml"/>
</build-list>
</spec>
