【发布时间】:2011-06-08 05:54:27
【问题描述】:
我已经在基于 VM 的新构建服务器 (Win7-64 Pro) 上运行了 CC.Net 和 NAnt(以及 MSBuild)。
CC.Net 可以很好地调用 MSBuild - 但在处理项目范围的构建时我遇到了问题。条件只是没有我需要的。甚至没有关闭。
所以我决定通过使用 NAnt 调用 MSBuild 来处理这些情况,但每次都会失败。当我从命令提示符运行 nant 脚本时,我得到了这个:
[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
Designer 程序集存在于这台机器上,它安装了 VS2010 Pro。 构建文件夹是正确的。 框架文件夹是正确的。 对 nant/msbuild 进行了无数次搜索,但这条消息没有产生任何实质性内容。
这些项目都试过了,没能改变结果:
Nant msbuild task with .net 4.0 rc
.NET projects build automation with NAnt/MSBuild + SVN(虽然我正在使用保险柜)
我尝试构建 nant 代码,这样我就可以通过 VS2010 的调试器调试问题,但源项目一团糟,甚至无法开始构建。
欢迎提出想法:)
【问题讨论】: