1 Building basic knowledge
1.1 Ant build script
The core of automation is the script of expression components dependent relationships and build procedures. The Make tool uses Makefile, and Ant uses a configuration file named Build.xml based on the XML format based default file.
1.1.1 Ant Project Profile
The ANT profile describes a build project (which consists of some attribute definitions and one target tree; the target represents a desired build result (for example, generating a link good executable), And express its dependence, common build targets include initialization (Compile, unit test (TEST), installation (CLEAN), etc., each target contains it to implement it The task of execution is very rich, such as the source code compilation, file copy, execution of command line operations. Ant also provides a very important task is to implement other project profiles, making batch processing of multiple build items possible.
1.1.2 ANT configuration file example
Below is an example of a configuration file for an ANT project:
XML Version = "1.0"?>
Build File for All Improve Library Project
description>
condition>
condition>
target>
delete>
delete>
target>
Exceptions = "true" multithreaded = "true" runtime = "Dynamic" debug = "true"> defineset> compiler> linker> fileset> cc> target> Failοnerrοr = "true" vmlauncher = "false" OS = "Windows 2000"> exec> Failοnerrοr = "true" vmlauncher = "false" OS = "Windows 2000"> exec> target> Depends = "CleanAll, Autobuild, Install, Test" Description = "Make a Clean (Re) Install and test> target> provject> In this Ant profile, some of the project will be referenced, such as environment variables, root directory paths, specified compilers, etc .; project default build targets are installall, which makes initialization (init) Cleanall, Compilation (Autobuild), Install, Test (Test), etc. Introduction The library 3D_Party.lib is required to be linked via the Linker section. For the specific configuration and use of each ANT configuration file in this project, see the ANT User Manual and other reference materials, and read the ANT configuration file itself. 1.1.3 ANT Example An example of executing on the command line: