Skip to content

Instantly share code, notes, and snippets.

@jeppeburchardt
Created July 17, 2013 12:54
Show Gist options
  • Save jeppeburchardt/6020327 to your computer and use it in GitHub Desktop.
Save jeppeburchardt/6020327 to your computer and use it in GitHub Desktop.
node gyp msbuild misssing registry warning MSB8003: Could not find WindowsSDKDir variable from the registry. TargetFrameworkVersion or PlatformToolset may be set to an invalid version number
call "C:\Program Files\Microsoft SDKs\Windows\v7.1\bin\Setenv.cmd" /Release /x86
call "C:\Program Files\Microsoft SDKs\Windows\v7.1\bin\Setenv.cmd" /Release /x64
@isimmons
Copy link

isimmons commented Jul 5, 2015

Still having to do this. Thanks for posting. How to make this change permanent? I have to do this every time. Thanks again

Update: I use cmder so I added the appropriate line from above to the end of my cmder/vendor/init.bat file followed by a cls just to put the cursor at the top. Now it happens automatically when I open my console.

Copy link

ghost commented Jul 15, 2015

I was lucky to find this bug solution here, i just experience this problem and thankfully this worked:
call "C:\Program Files\Microsoft SDKs\Windows\v7.1\bin\Setenv.cmd" /Release /x86

This did not:
call "C:\Program Files\Microsoft SDKs\Windows\v7.1\bin\Setenv.cmd" /Release /x64

My System:
OS Name: Microsoft Windows 7 Enterprise
OS Version: 6.1.7601 Service Pack 1 Build 7601
OS Manufacturer: Microsoft Corporation
OS Configuration: Standalone Workstation
OS Build Type: Multiprocessor Free
System Model: All Series
System Type: x64-based PC
Processor(s): 1 Processor(s) Installed.

C:\Users\Void>node -v
v0.12.4

C:\Users\Void>npm -v
2.10.1

Null

@KillingSpree
Copy link

GIANT Thanks! You've finished my ~6 hrs googling spree. I wish found solutions like this instantly :)

@vatsalpande
Copy link

I am working on Windows 8 and having same issue. Tried installing Windows SDK. Checked the folder path as mentioned above but it does not have setenv.cmd file at all. Please suggest

@AlanLes
Copy link

AlanLes commented Nov 18, 2015

I'm here with the same issue, but windows 10.
SDK which I downloaded and installed is:
https://dev.windows.com/en-us/downloads/windows-10-sdk

@clodio
Copy link

clodio commented Nov 30, 2015

unfortunately, i don't have a bin folder under "C:\Program Files\Microsoft SDKs\Windows\v7.1\

@Yousha
Copy link

Yousha commented Aug 15, 2016

And I dont have Setenv.cmd...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment