3
votes

Ive got CC.Net and NAnt (and MSBuild) running on a new VM-based build server (Win7-64 Pro).

CC.Net can call MSBuild just fine - but I run into problems there when dealing with project-scope builds. The conditionals just dont have what I need. Not even close.

So I decide to deal with those conditions by calling MSBuild with NAnt, which fails every time. When I run the nant script from the command prompt, I get this:

[loadtasks] Failure scanning "C:\nant\bin\extensions\common\2.0\Collection
Gen.dll" for extensions. Could not load file or assembly 'Microsoft.VSDesigner,
Version=7.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of
its dependencies. The system cannot find the file specified.
Buildfile: file:///c:/c7/projects/dyndata/dyndata.build
Target framework: Microsoft .NET Framework 4.0
Target(s) specified: build


build:

[loadtasks] Scanning directory "c:\nantcontrib\bin\lib" for extension assemblies
.
     [echo] Building DynData v7.0.7

BUILD FAILED

c:\c7\projects\dyndata\dyndata.build(24,12):
Failed to start MSBuild.
    c:\c7\projects\dyndata\dyndata.build(24,12):
    External Program Failed: C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbui
ld.exe (return code was 1)

Total time: 0.4 seconds.

c:\c7\projects\dyndata\dyndata.build(24,12):
Failed to start MSBuild.
    c:\c7\projects\dyndata\dyndata.build(24,12):
    'C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe' failed to start.

        The directory name is invalid

The Designer assembly is present on this machine, which has VS2010 Pro installed on it. The build folder is correct. The framework folder is correct. Umpteen searches for nant/msbuild and this message have yielded nothing substantive.

These items have been tried and failed to change the results:

Nant msbuild task with .net 4.0 rc

.NET projects build automation with NAnt/MSBuild + SVN (tho I am using Vault)

I tried to build the nant code so I could debug the problem via VS2010's debugger but the source project is an unworkable mess and wont even begin to build.

Ideas are welcome:)

1

1 Answers

2
votes

I think the first error about Microsoft.VSDesigner is just a warning - not a failure. On my developer box and build server I have VS2005 and VS2010 Pro installed and I do not have Microsoft.VSDesigner version 7 installed. I have version 8 and 9 installed but not 7.

It looks like the "build" target is running in nant and then then it fails. You are loading the tasks from nantcontrib then trying to start msbuild. How are you starting msbuild? Could you post the part of the nant file that starts it? What version of nant are you using? Does running nant with -v and -debug+ flags show anything helpful?