Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MSBUILD : error MSB4132: The tools version "2.0" is unrecognized. Available tools versions are "14.0", "4.0". #91

Open
iffy opened this issue Feb 21, 2019 · 2 comments

Comments

@iffy
Copy link

iffy commented Feb 21, 2019

I'd like to figure out how to solve this error and then contribute the solution to the Resolving Common Issues section.

I'm building an addon I've authored myself. (It builds fine on macOS and Linux).

Warning: unrecognized setting VCCLCompilerTool/MultiProcessorCompilation
Warning: unrecognized setting VCCLCompilerTool/MultiProcessorCompilation
Warning: unrecognized setting VCCLCompilerTool/MultiProcessorCompilation
Warning: unrecognized setting VCCLCompilerTool/MultiProcessorCompilation
Warning: unrecognized setting VCCLCompilerTool/MultiProcessorCompilation
Warning: unrecognized setting VCCLCompilerTool/MultiProcessorCompilation
Warning: unrecognized setting VCCLCompilerTool/MultiProcessorCompilation
Warning: unrecognized setting VCCLCompilerTool/MultiProcessorCompilation
gyp info spawn C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe
gyp info spawn args [ 'build/binding.sln',
gyp info spawn args   '/clp:Verbosity=minimal',
gyp info spawn args   '/nologo',
gyp info spawn args   '/p:Configuration=Release;Platform=Win32' ]
Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
MSBUILD : error MSB4132: The tools version "2.0" is unrecognized. Available tools versions are "14.0", "4.0".
gyp ERR! build error 
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onExit (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\lib\build.js:262:23)
gyp ERR! stack     at ChildProcess.emit (events.js:197:13)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:254:12)
gyp ERR! System Windows_NT 10.0.15063
gyp ERR! command "C:\\Program Files (x86)\\nodejs\\node.exe" "C:\\Users\\IEUser\\AppData\\Roaming\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\proj\nodebuckets
gyp ERR! node -v v11.8.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok 

Here's some diagnostic information. I'm happy to provide anything else you might think helpful:

  • Windows [Version 10.0.15063]
  • npm config list:
    ; cli configs
    metrics-registry = "https://registry.npmjs.org/"
    scope = ""
    user-agent = "npm/6.5.0 node/v11.8.0 win32 ia32"
    
    ; userconfig C:\Users\IEUser\.npmrc
    msvs_version = "2015"
    prefix = "C:\\Users\\IEUser\\AppData\\Roaming\\npm"
    python = "C:\\Users\\IEUser\\.windows-build-tools\\python27\\python.exe"
    
    ; globalconfig C:\Users\IEUser\AppData\Roaming\npm\etc\npmrc
    msvs_version = "2015"
    python = "C:\\Users\\IEUser\\.windows-build-tools\\python27\\python.exe"
    
    ; builtin config undefined
    prefix = "C:\\Users\\IEUser\\AppData\\Roaming\\npm"
    
    ; node bin location = C:\Program Files (x86)\nodejs\node.exe
    ; cwd = C:\Windows\system32
    ; HOME = C:\Users\IEUser
    ; "npm config ls -l" to show all defaults.
    
    
  • yarn config list:
    yarn config v1.13.0
    info yarn config
    { 'version-tag-prefix': 'v',
    'version-git-tag': true,
    'version-commit-hooks': true,
    'version-git-sign': false,
    'version-git-message': 'v%s',
    'init-version': '1.0.0',
    'init-license': 'MIT',
    'save-prefix': '^',
    'bin-links': true,
    'ignore-scripts': false,
    'ignore-optional': false,
    registry: 'https://registry.yarnpkg.com',
    'strict-ssl': true,
    'user-agent': 'yarn/1.13.0 npm/? node/v11.8.0 win32 ia32',
    lastUpdateCheck: 1550698991414,
    msvs_version: '2015',
    'yarn-offline-mirror': '\\\\vboxsrv\\project\\cache\\yarnmirror',
    'yarn-offline-mirror-pruning': false }
    info npm config
    { prefix: 'C:\\Users\\IEUser\\AppData\\Roaming\\npm',
    python: 'C:\\Users\\IEUser\\.windows-build-tools\\python27\\python.exe',
    msvs_version: '2015' }
    
  • Possibly relevant environment variables:
    I see that I've put some garbage values in for Path, but those shouldn't cause the error I'm seeing, right? Is my Path missing anything? Do I have extra things I shouldn't?
    PYTHON=C:\Users\IEUser\.windows-build-tools\python27\python.exe
    Path=C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\OpenSSH\bin;C:\Program Files (x86)\nodejs\;C:\Program Files (x86)\Yarn\bin\;C:\ProgramData\chocolatey\bin;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit\;C:\Program Files (x86)\Git\cmd;C:\mingw32\mingw32\bin;C:\nim\bin;C:\Users\IEUser\.nimble\bin;C:\Users\IEUser\.nimble\bin;C:\Users\IEUser\AppData\Roaming\npm;C:\Windows\system32\node_modules\.bin;"'node' is not recognized as an internal or external command,";"'node' is not recognized as an internal or external command,";node_modules\.bin\;C:\Users\IEUser\AppData\Local\Microsoft\WindowsApps;C:\Users\IEUser\AppData\Local\Yarn\bin
    VCTargetsPath=C:\Program Files (x86)\MSBuild\Microsoft.cpp\v4.0\v140
    VS140COMNTOOLS=C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\Tools\
    
@iffy
Copy link
Author

iffy commented Feb 21, 2019

Same problem even without the errors in my Path:

Path=C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\OpenSSH\bin;C:\Program Files (x86)\nodejs\;C:\Program Files (x86)\Yarn\bin\;C:\ProgramData\chocolatey\bin;C:\Program Files (x86)\Git\cmd;C:\mingw32\mingw32\bin;C:\nim\bin;C:\Users\IEUser\.nimble\bin;C:\Users\IEUser\.nimble\bin;C:\Users\IEUser\AppData\Roaming\npm;C:\Windows\system32\node_modules\.bin;C:\Users\IEUser\AppData\Local\Yarn\bin;C:\Windows\system32\node_modules\.bin;node_modules\.bin\;C:\Users\IEUser\AppData\Local\Microsoft\WindowsApps

@RandomJedaii
Copy link

Has this issue been resolved? I am currently experiencing the same issue while onboarding

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants