|
Tibco Designer 5.6 comes with a tool to build design time libs. I am calling this in Jenkins from ant (1.8) to build all design libraries (a.k.a. project libraries) needed for my BusinessWorks (5.8) projects.
The command line for invoking buildlibrary is as follows:
$ /tibcoInstallationDir/designer/5.6/bin/buildlibrary -x -lib /_Builds/yourProject.libbuilder
-o /yourPath/rel/yourProject.projlib -p /yourPath/yourProject/src/yourProject
--propFile /tibcoInstallationDir/designer/5.6/bin/buildlibrary.tra
The lib argument in this command line is the location of the library builder resource relative to the root directory of the BusinessWorks project. See also ./buildlibrary -h. This command line translates into the following ant task:
<exec executable="/tibcoInstallationDir/designer/5.6/bin/buildlibrary">
<arg value="-x"/>
<arg value="-lib"/>
<arg value="/_Builds/yourProject.libbuilder"/>
<arg value="-o"/>
<arg file="/yourPath/rel/yourProject.projlib"/>
<arg value="-p"/>
<arg path="/yourPath/yourProject/src/yourProject"/>
<arg value="--propFile"/>
<arg file="/tibcoInstallationDir/designer/5.6/bin/buildlibrary.tra"/>
</exec>
This translates to the following Groovy code:
ant.exec(
executable: "/tibcoInstallationDir/designer/5.6/bin/buildlibrary"
) {
arg(value: "-x")
arg(value: "-lib")
arg(value: "/_Builds/yourProject.libbuilder")
arg(value: "-o")
arg(file: "/yourPath/rel/yourProject.projlib")
arg(value: "-p")
arg(path: "/yourPath/yourProject/src/yourProject")
arg(value: "--propFile")
arg(file: "/tibcoInstallationDir/designer/5.6/bin/buildlibrary.tra")
}
In ant there are many ways to pass command line arguments to the exec task. This is a nice demonstration of the use of the arg element and its attributes: value, file, or path. It turned out that only with the last two arg elements ant was able to pass the correct the tra properties file to the buildlibrary command on an Windows XP machine.
When building a design time library from Tibco Designer one has the option not to include other design time libraries imported in the BusinessWorks project. This option is available from Designer as option Hide Library Resources in the Project menu. When building libraires with buildlibrary one has to replace user/.TIBCO/Designer5.prefs with an empty file to get the same behaviour.
|