【问题标题】:How to rebuild Enterprise Library 6 on Win 8 and VS2015如何在 Win 8 和 VS2015 上重建 Enterprise Library 6
【发布时间】:2016-09-17 10:59:19
【问题描述】:

我已经自定义了企业库,现在想要重新构建它,但是从 VS2015 的开发人员命令提示符执行 BuildLibrary.bat(脚本文件夹)时出现一些错误。

环境:

  1. 赢8
  2. VS2015

两个问题:

1.)

无法加载文件或程序集 'file:///C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft. Build.Tasks.v12.0.dll

在我的系统上,我有一个更新的版本:

Microsoft.Build.Tasks.v4.0.dll


2.)

“C:\EntLib6Source\Blocks\EnterpriseLibrary.sln”(重建目标)(1) -> "C:\EntLib6Source\Blocks\SemanticLogging\Src\SemanticLogging.Database\SemanticLogging.Database.csproj" (重建目标)(53)-> “C:\EntLib6Source\Blocks\TransientFaultHandling\Source\TransientFaultHandling\TransientFaultHandling.csproj” (清洁目标)(35:11) -> C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\AppxPackage\Microsoft.AppXPackage.Targets(283,22): 错误 MSB4086:尝试在“10.0.11000.0”上进行数字比较 在条件下计算为“10.0.11000.0”而不是数字 “'$(TargetPlatformVersion)' >= '10.0.11000.0'”。 [C:\EntLib6Source\块 \TransientFaultHandling\Source\TransientFaultHandling\TransientFaultHandling.csproj]


“C:\EntLib6Source\Blocks\EnterpriseLibrary.sln”(重建目标)(1) -> "C:\EntLib6Source\Blocks\SemanticLogging\Src\SemanticLogging\SemanticLogging.csproj" (重建目标)(52)->(CheckPrerequisites 目标)->
C:\EntLib6Source\Blocks.nuget\nuget.targets(71,9):错误 MSB4175: 无法从程序集中加载任务工厂“CodeTaskFactory” "C:\Windows\Micros oft.NET\Framework\v4.0.30319\Microsoft.Build.Tasks.v12.0.dll”。可以 不加载文件或程序集 'file:///C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft. Build.Tasks.v12.0.dll' 或其依赖项之一。系统无法 找到指定的文件。 [C:\EntLib6Source\Blocks\SemanticLogging\Src\SemanticLogging\Seman ticLogging.csproj]

【问题讨论】:

    标签: visual-studio-2015 windows-8 enterprise-library enterprise-library-6


    【解决方案1】:

    好的,我通过覆盖工具版本解决了这个问题。 没有使用 BuildLibrary.bat。

    使用以下开关直接执行 msbuild:

    msbuild.exe EnterpriseLibrary.sln /tv:14.0 /p:Configuration=Debug

    如果您想要 Release 版本,请将 debug 替换为 release。

    附: 我还做的是升级所有项目以使用 .NET 4.6.1。 但我认为,覆盖电视就足够了。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2011-10-01
      • 2012-10-23
      • 2011-09-29
      • 1970-01-01
      • 1970-01-01
      • 2013-11-11
      • 2015-08-27
      相关资源
      最近更新 更多