Files can be found at http://sourceforge.net/projects/jtaskdefs/
A complete description of Ant is here: http://ant.apache.org
The original files are here: http://www.arrizza.com/taskdefs/taskdefs.html
Documentation for jTaskdefs
Table of Contents
C# | Compile .Net Solutions |
VC6 | Compile C/C++ v6.0 .dsp files |
VC7 | Compile C/C++ v7.0 .sln files |
VB6 | Compile Visual Basic v6.0 .vbp files |
regasm | run RegAsm |
nunit | run NUnit |
vbunit | run VBUnit |
This taskdef compiles a C# solution.
Name | Required? | Default | Property | Notes |
projectrootfolder | no | current dir | CS_ROOT | the folder where the project folders are. |
projectfolder | no | targetname | none | The project folder is assumed to have the same name as the ant target |
project | no | targetname.sln | none | The project file is assumed to have the same name as the ant target |
buildmode | no | release | CSBUILDMODE | typically release or debug |
compilerfolder | no | none | CSCOMPILERFOLDER | the folder where devenv.exe can be found |
failonerror | no | true | none | if true, compilation stops on first failure. |
logfile | no | logfile.txt | CSLOGFILE | all compilation output is redirected to this file |
targets | no | targetname.sln | none | a fileset indicating which .sln to build |
This taskdef compiles a VC6 C++ solution.
Name | Required? | Default | Property | Notes |
projectrootfolder | no | current dir | VC6_ROOT | the folder where the project folders are. |
projectfolder | no | targetname | none | The project folder is assumed to have the same name as the ant target |
project | no | targetname.dsp | none | The project file is assumed to have the same name as the ant target |
buildmode | no | release | VC6BUILDMODE | typically release or debug; |
compilerfolder | no | none | VC6COMPILERFOLDER | the folder where msdev.exe can be found |
failonerror | no | true | none | if true, compilation stops on first failure. |
logfile | no | null | VC6LOGFILE | all compilation output is redirected to this file |
targets | no | targetname.dsp | none | a fileset indicating which .dsp to build |
rebuild | no | true | none | true to rebuild, false to just build |
Logfile
All output from the compilation goes to standard output (Don't forget about ant's facility for
naming a listener task on the command line! See Listeners and Loggers at http://ant.apache.org/manual/index.html )
If you use a property
<property name='VC6LOGFILE' value='vc6out.txt' />
all vc6 task output will go to that file instead. Using a logfile attribute in a target override the property and direct all output
to the given file. This example shows that the output from testvc6_3 target will go to jaa3.txt and the output from
testvc6_4 will go to jaa4.txt:
<target name='testvc6_3' depends='init' >
<vc6 buildmode='${mode}' projectrootfolder='${srcdir}' logfile='jaa3.txt' rebuild='${rebuild}'>
<targets dir='${srcdir}' includes='**/atest3.dsp' />
</vc6>
</target>
<target name='testvc6_4' depends='init4' >
<vc6 buildmode='${mode}' projectrootfolder='${srcdir}' logfile='jaa4.txt' rebuild='${rebuild}'>
<targets dir='${srcdir}' includes='**/atest4.dsp' />
</vc6>
</target>
Targets
Here is an example of the Targets fileset. Given a directory structure like this:
D:\projects\test\ant_vc6\
\atest1\atest1.dsp
\atest2\atest2.dsp
\atest3\atest3.dsp
Then this build.xml will compile all the .dsp's
<project name='testvc'
default='testvc6'
basedir='.'>
<taskdef name='vc6' classname='com.arrizza.ant.taskdefs.VC6' />
<!-- ==================================== -->
<target name='init'>
<property name='srcdir' value='d:/projects/test/ant_vc6' />
<property name='mode' value='debug' />
</target>
<target name='testvc6' depends='init'>
<vc6 buildmode='${mode}' projectrootfolder='${srcdir}'>
<targets dir='${srcdir}' includes='**/*.dsp' />
</vc6>
</target>
</project>
The output will look like this:
D:\projects\test\ant_vc6>ant -v
Apache Ant version 1.5.1 compiled on October 2 2002
Buildfile: build.xml
Detected Java version: 1.4 in: E:\tools\jdk\jre
Detected OS: Windows 2000
parsing buildfile build.xml with URI = file:D:/projects/test/ant_vc6/build.xml
Project base dir set to: D:\projects\test\ant_vc6
Build sequence for target `testvc6' is [init, testvc6]
Complete build sequence is [init, testvc6]
init:
testvc6:
[vc6] Command= msdev.exe /out logfile.txt D:\projects\test\ant_vc6\atest1\atest1.dsp /make "all - debug"
/rebuild
[vc6] Command= msdev.exe /out logfile.txt D:\projects\test\ant_vc6\atest2\atest2.dsp /make "all - debug"
/rebuild
[vc6] Command= msdev.exe /out logfile.txt D:\projects\test\ant_vc6\atest3\atest3.dsp /make "all - debug"
/rebuild
BUILD SUCCESSFUL
Total time: 6 seconds
D:\projects\test\ant_vc6>
This taskdef compiles a VC7 C++ solution.
Name | Required? | Default | Property | Notes |
projectrootfolder | no | current dir | VC7_ROOT | the folder where the project folders are. |
projectfolder | no | targetname | none | The project folder is assumed to have the same name as the ant target |
project | no | targetname.sln | none | The project file is assumed to have the same name as the ant target |
buildmode | no | release | VC7BUILDMODE | typically release or debug; |
compilerfolder | no | none | VC7COMPILERFOLDER | the folder where devenv.exe can be found |
failonerror | no | true | none | if true, compilation stops on first failure. |
logfile | no | logfile.txt | VC7LOGFILE | all compilation output is redirected to this file |
targets | no | targetname.sln | none | a fileset indicating which .sln to build |
rebuild | no | true | none | true to rebuild, false to just build |
See the vc6 taskdef for an example of using the Targets parameter.
This taskdef compiles a VB6 project.
Name | Required? | Default | Property | Notes |
projectrootfolder | no | current dir | VB6_ROOT | the folder where the project folders are. |
projectfolder | no | targetname | none | The project folder is assumed to have the same name as the ant target |
project | no | targetname.vbp | none | The project file is assumed to have the same name as the ant target |
compilerfolder | no | none | VB6COMPILERFOLDER | the folder where vb6.exe can be found |
failonerror | no | true | none | if true, compilation stops on first failure. |
logfile | no | logfile.txt | VB6LOGFILE | all compilation output is redirected to this file |
targets | no | targetname.vbp | none | a fileset indicating which .vbp to build |
Not much to say at this time
Not much to say at this time
Not much to say at this time