The builds tools for v120 (Platform Toolset = 'v120') cannot be found

前端 未结 16 1487
后悔当初
后悔当初 2020-12-04 09:47

Using visual studio 2012 on windows 8 x64 aparantly this is caused by msbuild being moved into .net but I havn\'t seen how to fix it yet.

4>C:\\Program Fi         


        
16条回答
  •  误落风尘
    2020-12-04 10:45

    To add up to Kevin and Lex's answers:

    We had a similar situation at work where both the developers and the build server had Visual Studio 2013. Our solution had a VS 2013 C++ project and compiled fine when built on developer's machine or on the build server within the IDE. The issue was when triggering builds using TFS build definitions. We were still using an old build template (version 11.1) instead of 12.0. Fortunately, a simple attribute addition to the template xaml file solved the issue. In the Sequence portion "Compile the Project", there is a xaml node that starts with

    mtbwa:MSBuild CommandLineArgument=....
    

    You can add a "ToolPath" attribute and point it to the right path of the MSBuild.exe you wish to invoke, based on Kevin's answer. For instance:

    ToolPath="C:\Program Files (x86)\MSBuild\12.0\Bin"
    

提交回复
热议问题