Home

Awesome

For those of you who have the 'pleasure' of integrating CA Aion apps in an automated build, I give you:

CA Aion MsBuildTasks

Aion.MsBuildTasks are 2 msbuild tasks for building CA Aion apps (CA Aion Business Rules Expert).

Setup for integrating Aion in a version control system

The application these tasks were made for is using subversion for version control. There are lots of .app files with multiple levels of includes. Because Aion doesn't handle the libincpath paths very well we have decided on using an absolute path in all of the libincpath paths that is pointed to

C:\ApplicationName

In our buildscript we make a symbolic link (via mklink) from our source folder to the absolute path decided on so that each developer and the buildserver can check out the code to a directory of their choice. For usage see the MapSourceDirectory target in the Build.target file.

Usage

See Build.target for building 3 main .app files. This will identify all the includes necessary to build the .app's, will restore the code from the app and will build only the necessary .app files and in the correct order.

	<Target Name="BuildAion">
		<ItemGroup>
		  <SourceDir Include='$(SourceDirectory)' />
		</ItemGroup>
		<ItemGroup>
		  <StartApplications Include="%(SourceDir.FullPath)\FirstMain.app" />
		  <StartApplications Include="%(SourceDir.FullPath)\SecondMain.app" />
		  <StartApplications Include="%(SourceDir.FullPath)\ThridMain.app" />
		</ItemGroup>
		<PropertyGroup>
		  <StartApplicationsList>@(StartApplications, '|')</StartApplicationsList>
		</PropertyGroup>

		<MSBuild Projects="Aion.proj" targets="Build" Properties="StartApplication=$(StartApplicationsList);ApplicationSourceDirectory=%(SourceDir.FullPath);ShouldRestoreCodeFromApp=true;BuildTimeOutInSeconds=90"
				StopOnFirstFailure="True" />
	</Target>

App header example

In the following example this app (ApplicationDataLib) has 3 includes, 2 from own source and 1 from the Aion class libraries (the one that ends with -C):

The LibIncPath holds a comma seperated string of directories where the includes can be found.

<pre> #Library4 ApplicationDataLib #Revision 0 #LibOwner nickvane #LibModStamp 2012/01/12 13:05 #LibIncPath C:\ApplicationName\SOURCE #Includes ApplicationSysLib ApplicationIOLib datalib-C #LibDLL ApplicationDataLib #LibExe ApplicationDataLib #ErrHandling MB ... CODE REMOVED ... </pre>