我有一个TFS生成服务,建立一个VS2008/.NET 3.5项目.NET 3.5的问题与TFS 2010生成服务
产生的dll文件看起来Reflecor精细,引用System.Drawing中V2.0.50727
不幸的是,我无法加载这些dll在一个测试.NET 3.5框中,因为'后期策略引用'似乎强制执行.NET 4版本的system.drawings。
我试图设置为true
我甚至想出货System.Drawing中V2“特定版本”来引用,没有运气。
我猜它是由2010 TFS使用.NET 4.0版本的MSBuild造成的,但我找不到任何办法至今解决这个问题...
顺便说一句,一个解决方案建在VS2008下我的车站工作得很好。
这是加载失败日志。无法在代码中找到任何4.0引用,或者在Reflector中找到二进制文件。
=== Pre-bind state information ===
LOG: User = foo\bar
LOG: DisplayName = System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
(Fully-specified)
LOG: Appbase = file:///C:/Program Files/foobar/
LOG: Initial PrivatePath = NULL
Calling assembly : (Unknown).
===
LOG: This bind starts in default load context.
LOG: Using application configuration file: C:\foobar\baz.dll.config
LOG: Using machine configuration file from c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\config\machine.config.
LOG: Post-policy reference: System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
LOG: Attempting download of new URL file:///C:\foobar\System.Drawing.DLL.
WRN: Comparing the assembly name resulted in the mismatch: Major Version
ERR: Failed to complete setup of assembly (hr = 0x80131040). Probing terminated.