InstallAnywhere Ant Task Reference
InstallAnywhere 2024 R2
InstallAnywhere includes an Ant task to build installers from Ant. The InstallAnywhere Ant task (iaant.jar) is located in your InstallAnywhere application folder:
IA_HOME\resource\build\iaant.jar
Tip:To integrate the InstallAnywhere Ant task in an Ant project, set the classpath of the InstallAnywhere Ant task to the location of iaant.jar.
Note:The use of iaant.jar requires Java 1.4 or later.
The following Ant task parameters are available:
• | Build Parameters |
• | Platform Options |
• | Build Options |
• | Installer Options |
Use the following parameters to control the build process for the InstallAnywhere Ant task.
Attribute |
Description |
IAProjectFile |
The location of the InstallAnywhere project that you want to build. This is a required parameter. |
IALocation |
The location where InstallAnywhere is installed. This is an optional parameter. Note:If IALocation is not specified, the task searches for a copy of InstallAnywhere to run against. If InstallAnywhere is not installed in one of the default locations, the task checks the InstallAnywhere product registry for a valid location. |
i5OSLogin |
The host name, user name and password of an iSeries machine in the following format: hostname_or_ip/userName/password For example: <buildinstaller IAProjectFile="Project_File" IALocation="IA_HOME" i5OSLogin="hostname_or_ip/userName/password"> After the project successfully builds, an asterisk-masked i5OSLogin parameter (password portion) prints to the console. This is an optional parameter. |
propertiesfile |
The location of a BuildProperties.xml file. If this parameter is used, all other attributes are ignored. This is an optional parameter. |
failOnError |
Stop the build process if the command exits with a return code other than 0. Defaults to false. This is an optional parameter. |
Platform options correspond to platform targets on the InstallAnywhere Build Targets tab. By default, the platform options you set in the InstallAnywhere Ant task supersede the corresponding settings in your InstallAnywhere project file and activate or deactivate all targets associated with the platform/VM combination you specify.
Note:Platform options do not activate or deactivate the targets you define in the Ant project’s Configuration section. The InstallAnywhere Ant task will always build the targets you define in the Configurations section regardless of platform options defined here or in the InstallAnywhere project file.
Parameter |
Description |
BuildLinuxWithVM |
True/False |
BuildLinuxWithoutVM |
True/False |
LinuxVMPackLocation |
Path |
BuildHPUXWithVM |
True/False |
BuildHPUXWithoutVM |
True/False |
HPUXVMPackLocation |
Path |
BuildAIXWithVM |
True/False |
BuildAIXWithoutVM |
True/False |
AIXVMPackLocation |
Path |
BuildSolarisWithVM |
True/False |
BuildSolarisWithoutVM |
True/False |
SolarisVMPackLocation |
Path |
BuildNamedUNIXWithVM |
True/False |
BuildNamedUNIXWithoutVM |
True/False |
NamedUNIXVMPackLocation |
Path |
NamedUNIXTitle |
String |
BuildWindowsWithVM |
True/False |
BuildWindowsWithoutVM |
True/False |
WindowsVMPackLocation |
Path |
BuildWindows64WithVM |
True/False |
BuildWindows64WithoutVM |
True/False |
Windows64VMPackLocation |
Path |
BuildUNIXAll |
True/False Note:This parameter corresponds with Unix (All)/Generic Unix build target in the Build Installers view on the Build page of the Advanced Designer. |
BuildOSX |
True/False |
WantAuthenticationOSX |
True/False |
WantAuthenticationOSXShowGUI |
True/False |
BuildPureJava |
True/False |
OverrideAllPlatformSettings |
True/False Note:When you set OverrideAllPlatformSettings to True, Ant overrides all the platform settings in the InstallAnywhere project with the platform options provided in the Ant task. For example, if your InstallAnywhere project targets Windows and Linux systems and your Ant task adds a OS X target (BuildOSX="true"), the Ant task builds installers for Windows, Linux, and OS or OS X. However, if you also set OverrideAllPlatformSettings to True, Ant builds an installer for OS or OS X only. |
Build options specify build distribution settings.
Parameter |
Description |
BuildCDROMInstaller |
True/False |
BuildWebInstaller |
True/False |
BuildMergeModule |
True/False |
BuildReadOnlyMergeModule |
True/False |
BuildWorkdirLocation |
Path Note:BuildWorkdirLocation overrides the default working directory with a relative or full path. (Relative paths are relative to the location of the project file.) Incidentally, the working directory is also the default build output location. If you use both the BuildWorkdirLocation and BuildOutputLocation options, the BuildOutputLocation takes precedence over the working directory for build output. |
BuildOutputLocation |
Path |
OptimizeCDROMInstaller |
True/False |
OptimizeWebInstaller |
True/False |
OptimizeMergeModule |
True/False |
AutoPopulateLabels |
True/False |
AutoCleanComponents |
True/False |
Installer options affect the behavior of the installers that the project builds.
Parameter |
Description |
InstallerStdErrRedirect |
Path |
InstallerStdOutRedirect |
Path |
InstallerValidVMList |
String |
InstallerInitialHeapSize |
Int |
InstallerMaxHeapSize |
Int |
UNIXDefaultUI |
Silent/Console/GUI |
WindowsDefaultUI |
Silent/Console/GUI |
Windows64DefaultUI |
Silent/Console/GUI |
Note:In order to redirect InstallAnywhere’s build process output to Ant’s log, you must specify a redirector as described in the Ant documentation (Exec task). For information about using Ant, see http://ant.apache.org/manual/.
Build Configurations
Build configurations support InstallAnywhere projects that include multiple build targets for the same platform but use different VMs. Each target in a build configuration identifies a build target to add to those that already exist in the InstallAnywhere project file. Ant always builds the targets that you define in the InstallAnywhere Ant task’s Configuration section.
Tag |
Description |
|||||||||||||||||||||||||||
configuration |
Contains targets that append additional build targets to those already defined in the InstallAnywhere project file. Attributes The following are attributes of the configuration element:
|
|||||||||||||||||||||||||||
locales |
Contains targets that append additional build targets to those already defined in the InstallAnywhere project file. Nested Element(s) The following are nested element(s) of the locales element:
|
|||||||||||||||||||||||||||
target |
Contains the settings to define a single build target. Targets must include a platform setting. Attributes of Target Element The following are attributes of the target element:
|
See Also