This task compiles Visual Basic.NET source into executables or modules.
The task requires vbc.exe on the execute path, unless it or an equivalent
program is specified in the executable parameter
All parameters are optional: <vbc/> should suffice to produce a debug
build of all *.vb files.
The task is a directory based task, so attributes like
includes="**\/*.vb" and
excludes="broken.vb" can be used to control
the files pulled in. By default,
all *.vb files from the project folder down are included in the command.
When this happens the destFile -if not specified-
is taken as the first file in the list, which may be somewhat hard to control.
Specifying the output file with destfile is prudent.
Also, dependency checking only works if destfile is set.
For historical reasons the pattern
** /*.vb is preset as includes list and
you can not override it with an explicit includes attribute. Use
nested <src> elements instead of the basedir
attribute if you need more control.
As with <csc> nested src filesets of source,
reference filesets, definitions and resources can be provided.
Example
<vbc
optimize="true"
debug="false"
warnLevel="4"
targetType="exe"
definitions="RELEASE"
excludes="src/unicode_class.vb"
mainClass = "MainApp"
destFile="NetApp.exe"
optionExplicit="true"
optionCompare="text"
references="System.Xml,System.Web.Xml"
>
<reference file="${testCSC.dll}" />
<define name="RELEASE" />
<define name="DEBUG" if="debug.property"/>
<define name="def3" unless="def2.property"/>
</vbc>
|