Visual Studio 2017: vcvars for toolset v140

前端 未结 4 1166
忘了有多久
忘了有多久 2021-02-09 06:35

I installed Visual Studio 2017 and toolsets v140 and v141. To work with v140 toolset, I need to set the necessary environment via vc

4条回答
  •  渐次进展
    2021-02-09 07:10

    I've managed to solve, so to speek, this issue using the following approach. For toolset v140 vcvars tries to obtain the required data from the registry (Visual Studio 14.0 installation directory), but, because it fails to do so, exits with an error. If you add to the Windows registry the required value, vcvars will work correctly. In case of toolset v140 installed along with Visual Studio 2017 this path for the default installation is C:\Program Files (x86)\Microsoft Visual Studio\Shared\14.0\.

    You need to locate the existing key where the Visual Studio 2017 installation directory is set (in my case it is HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\SxS\VS7) and add the key with name 14.0 and value C:\Program Files (x86)\Microsoft Visual Studio\Shared\14.0\

提交回复
热议问题