我正在尝试构建和部署 .NET 4
项目使用 MSBuild
Web 部署和 TeamCity
,我在本地开发机器上运行了一个 TeamCity 实例,我得到了这个工作正常(最终),但是当我尝试使用相同的设置设置一个新的 TeamCity 实例时,我收到以下错误:
\Microsoft.Common.targets(2249, 9): error MSB3086: Task could not find "sgen.exe"
using the SdkToolsPath
"C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\NETFX 4.0 Tools\" or the
registry key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v7.0A".
Make sure the SdkToolsPath is set and the tool exists in the correct processor
specific location under the SdkToolsPath and that the Microsoft Windows SDK
is installed
我正在运行 Windows Server 2008,并安装了 .NET 4,包括(我相信)MSBuild 4。我还安装了 Windows SDK 7.1,因为其他线程建议这可能是问题所在,但仍然没有运气。任何想法或建议将不胜感激。
谢谢
最佳答案
我在 TeamCity 上遇到了同样的问题。以下是我的解决步骤:
如果您接受默认安装路径, sgen.exe 将在这里找到:
C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\sgen.exe
关于.net - MSBuild 错误 MSB3086,与 TeamCity,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8140413/