.NET 4.0构建服务器基准组件警告MSB3644 [英] .NET 4.0 build server reference assemblies warnings MSB3644

查看:1166
本文介绍了.NET 4.0构建服务器基准组件警告MSB3644的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我得到我的构建服务器上的一堆错误:

I'm getting a bunch of errors on my build server:

C:\ WINDOWS \ Microsoft.NET \框架\ v4.0.30319 \ Microsoft.Common.targets(847,9):警告MSB3644:参考组件的框架.NETFramework,版本= V4.0未找到。要解决此问题,安装SDK或定位包这个框架版本或重新定位你的应用程序版本您拥有SDK或定位安装包的框架。请注意,组件会从全局程序集缓存(GAC)来解决和代替参考组件将被使用。因此,程序集可能无法正确​​针对您打算框架。 [D:\adis\mercury\AdisFeeds\cache\Adis.Feeds.Cache.ConsoleManager\Adis.Feeds.Cache.ConsoleManager.csproj]

C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(847,9): warning MSB3644: The reference assemblies for framework ".NETFramework,Version=v4.0" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend. [D:\adis\mercury\AdisFeeds\cache\Adis.Feeds.Cache.ConsoleManager\Adis.Feeds.Cache.ConsoleManager.csproj]

现在的问题是,我已经安装了Windows的.NET部分SDK 7.1。 ......我特别注意检查旁边的.NET 4.0引用程序集的框。

The problem is that I have already installed the .NET parts of the windows SDK 7.1. ... I was especially careful to check the box next to the .net 4.0 reference assemblies.

有没有人有任何建议,这是怎么回事了?

Does anyone have any suggestions as to what's going wrong?

有关我使用南特运行构建脚本(版本0.86)为恶性的MSBuild任务,记录和nant.contrib(0.85)。

For the record I am using Nant to run the build scripts (ver 0.86) and nant.contrib (0.85) for the msbuild nant task.

更新 我只是顺着那个角度。我编我的开发机器使用的MSBuild与诊断日志记录解决方案,然后再生成服务器上。然后,我比较日志。

Update I was just running down that angle. I compiled the solution using msbuild with diagnostic logging on my dev machine and then again on the build server. Then I compared the logs.

看来显著差异有缺乏到\ Program Files文件\任何引用参考组件路径。特别是在FrameworkPathOverride。

Seems the significant difference there is the lack of any references to the \Program Files\References Assemblies path. Specifically in FrameworkPathOverride.

所以,我想加入FrameworkPathOverride作为命令行参数的MSBuild。不幸的是,仅仅使我不幸的发现,即基准组件目录似乎只在它们的XML文件。如在只有mscorlib.xml。没有mscorlib.dll中

So I tried adding FrameworkPathOverride as a commandline parameter to msbuild. Unfortunately that just led me to the unfortunate discovery that the reference assemblies directories only seem to have the xml files in them. As in there is only mscorlib.xml. No mscorlib.dll

到底是什么回事?!?

推荐答案

好,我找到了一个解决方案,工程。你需要做两件事情: 首先添加FrameworkPathOverride作为命令行参数,并将其指向引用组件目录。类似于

Ok I found a solution that works. You need to do two things: First add FrameworkPathOverride as a commandline parameter and point it to the references assemblies directory. Something like

msbuild -p:FrameworkPathOverride="C:\Program Files\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0"

您需要做的是找到一个完整版本的引用程序集目录的第二件事。由于由Windows SDK和Visual Studio的安装安装一个副本,我只是复制我的从我的开发机器。正常工作。

The second thing you need to do is find a full version of the reference assemblies directory. Since the copy installed by the windows SDK and the one installed by visual studio, I just copied mine from my development machine. Works fine.

最后一点:这可能发生在我身上摆在首位的原因是我们构建服务器是一个很好的老的Windows Server 2003之一。太旧的Windows SDK安装到应对?

One final note: the reason this might have happened to me in the first place is that our build server is a nice old windows server 2003 one. Too old for the windows SDK install to cope with?

这篇关于.NET 4.0构建服务器基准组件警告MSB3644的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆