<target name="compile" description="Compile the source code.">
<echo message="Building assembly ${ project.name}." />
<csc target="library" keyfile="${project.name}.snk" output="${output.path}/${project.name }.dll" debug="${build.debug}" verbose="true">
<sources>
<include name="**/*.cs" />
</sources>
<references>
<lib>
<include name="{libraries.path}\some\path" />
<include name="{libraries.path}\other\path" />
</lib>
<include name="Some.dll" />
<include name="Other.dll" />
</references>
</csc>
</target>
When calling this target from NAnt, I get a type or namespace could not be found compilation error with the verbose output looking something like the following:
[csc] Output file 'D:\TeamDevelopment\BuildArea\Output\Project 1.0\Project.Website\Project.Website.dll' does not exist, rebuilding.
[csc] Compiling 9 files to 'D:\TeamDevelopment\BuildArea\Output\Project 1.0\Project.Website\Project.Website.dll'.
[csc] Contents of C:\Documents and Settings\genzweb\Local Settings\Temp\tmp23E6.tmp.
[csc] /fullpaths /debug "/define:DEBUG" "/define:TRACE" /nologo "/target:library" "/out:D:\TeamDevelopment\BuildArea\Output\Project 1.0\Project.Website\Project.Website.dll" "/keyfile:D:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website\Project.Website.snk" "D:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website\Bdp\Form1.aspx.cs" "D:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website\Bdp\Form1.aspx.designer.cs" "D:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website\DatePicker\DatePicker.aspx.cs" "D:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website\Properties\AssemblyInfo.cs" "D:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website\Properties\VersionInfo.cs" "D:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website\Tmf\Form1.aspx.cs" "D:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website\Tmf\Form1.aspx.designer.cs" "D:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website\Default.aspx.cs" "D:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website\Default.aspx.designer.cs"
[csc] Starting 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\csc.exe (@"C:\Documents and Settings\genzweb\Local Settings\Temp\tmp23E6.tmp")' in 'D:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website'
[csc] d:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website\Bdp\Form1.aspx.cs(18,7): error CS0246: The type or namespace name 'Some' could not be found (are you missing a using directive or an assembly reference?)
[csc] d:\TeamDevelopment\BuildArea\Source\Project 1.0\Project.Website\Bdp\Form1.aspx.designer.cs(15,19): error CS0246: The type or namespace name 'Other' could not be found (are you missing a using directive or an assembly reference?)
It appears almost as if my references aren't being included as parameters of the csc.exe call. I have other projects that use similar methods for compiling without problems. I've checked my working source directory and the build files do include the correct references. Ideas? Thanks in advance.
------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________ nant-developers mailing list nant-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/nant-developers