I have the same problem. I have a main build file for the solution
calling all the build files of the projects in the solution. They are
all nearly same. But after four of the builds end succesfully the last
one fails because <csc> task cannot find the *.cs files. I tried all the
possibilities like Elie. On the other hand <csc> tasks of other build
files which are nearly same runs very well.

<csc target="library" debug="true" define="UNIT_TESTS"
output="${localbindir}/${filename}.dll">
                                <sources
basedir="${basedir}/${filename}">
                                        <include name="**/*.cs"/>
                                </sources>
                                <references refid="refs"/>
                </csc>

---------------------------Original Message-----------------------------
Hi there,

this is probably a daft one, but I don't seem to be able to figure it
out. I have a pretty simple task set up as such:

<target name="c" description="Compiles the source code">

               <!-- set up a couple of filesets -->
               <fileset id="compileThis">
                       <include name="${base.code.dir}/**/*.cs" />
               </fileset>

               <fileset id="refThis">
                       <include name="${base.dir}/bin/*.dll" />
               </fileset>

               <!-- print out the contents of eachof the filesets to
screen -->
               <foreach item="File" property="filename">
                   <in>
                       <items refid="compileThis"/>
                   </in>
                   <do>
                       <echo message="${filename}"/>
                   </do>
               </foreach>
               <foreach item="File" property="filename">
                   <in>
                       <items refid="refThis"/>
                   </in>
                   <do>
                       <echo message="${filename}"/>
                   </do>
               </foreach>

               <!-- compile the files in the fileset (using the second
fileset as
reference) -->
               <csc target="library" output="${dist.dll}"
verbose="true">
                       <sources refid="compileThis"/>
                       <references refid="refThis"/>
               </csc>
       </target>

This correctly prints out the filenames of a bunch of *.cs and *.dll
files (so the <sources> and <references> elements are definitely not
empty), but the csc task doesn't seem to do anything - the dll isn't
created, and absolutely no output is given at all. Any ideas of what I
might be doing wrong? I am running Nant 0.85rc3 with .Net 1.1
(2.0beta1 is also installed, but I tell Nant to use 1.1 via the
nant.settings.currentframework property)

thanks,
Elie


-------------------------------------------------------
This SF.Net email is sponsored by Oracle Space Sweepstakes
Want to be the first software developer in space?
Enter now for the Oracle Space Sweepstakes!
http://ads.osdn.com/?ad_idt12&alloc_id344&op=click
_______________________________________________
Nant-users mailing list
Nant-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nant-users

Reply via email to