MATLAB Answers

6

How do I install Microsoft Windows SDK 7.1?

I would like to know the specific steps needed to install Microsoft Windows SDK 7.1.

Products


Release

R2011b

19 Answers

Answer by MathWorks Support Team on 6 Nov 2018
Edited by MathWorks Support Team on 6 Nov 2018
 Accepted Answer

PREREQUISITE INFORMATION
If you have any of the following cases true, see the troubleshooting section at the bottom before proceeding with the SDK 7.1 installation.
Microsoft Visual Studio C++ 2010 SP1 installed (version greater than 10.0.30319)
.NET Framework 4.5 installed (also bundled with Visual Studio 2012 or later)
INSTALLING THE WINDOWS SDK 7.1
1. Download Windows SDK for Windows 7 and .NET Framework 4 from Microsoft at:
2. When the download is complete, choose to run winsdk_web.exe. Depending on your security settings, you may be prompted by User Account Control (UAC) to confirm “making changes to this computer”.
3. After several seconds, the Setup Wizard will appear.
4. Click through the wizard, accepting the license agreement and not changing any of the installation folders.
5. Continue through the wizard to download and install the SDK. Depending on the speed of your Internet connection, this step will take several minutes to an hour or more.
6. The setup wizard finishes.
TROUBLESHOOTING
.NET Framework 4.5 already installed
If you have .NET Framework 4.5 installed, SDK 7.1 may fail to install. In this case:
Uninstall .NET Framework 4.5.
Install the SDK 7.1 using the instructions above.
Reinstall .NET Framework 4.5.
If SDK 7.1 was already installed, but with a message saying .NET 4 could not be installed due to the presence of .NET 4.5, you may need to uninstall .NET 4.5 first as well and retry.
Microsoft Visual Studio C++ 2010 SP1 already installed
If Microsoft Visual Studio C++ 2010 SP1 is already installed, SDK 7.1 may fail to install. In this case:
Remove the 2010 Redistributable packages (both x86 and x64). For that, navigate to the windows control panel -> click on "programs" -> click on "Programs and Features" -> select the required programs to be removed.
Install SDK 7.1 using the instructions above.
Apply the SDK 7.1 patch.
Reinstall 2010 Redistributable packages.
If you have both Microsoft Visual Studio C++ 2010 SP1 and SDK 7.1 already installed, but running into various errors during compilation, apply the SDK 7.1 patch to fix the issue.
"ammintrin.h missing" error
This occurs if only SDK 7.1 was installed (without Microsoft Visual C++ 2010 SP1 present on the machine), and then the SDK 7.1 patch is applied. In this case:
Install Visual Studio C++ 2010 (if not already installed). Either Professional or Express works.
Upgrade Visual Studio C++ 2010 to SP1
If issues occur when removing the Visual Studio 2010 redistributable and .NET 4.5 redistributable using "Programs and Features" in the control panel
"Programs and Features" doesn't always do a complete job in uninstalling programs. Please follow the suggestions mentioned in the following link:
The following post addresses the issue that occurs when removing the Visual Studio 2010 and .NET 4.5 redistributable:
  • If "mex -setup" does not list Microsoft SDK 7.1, even though it is successfully installed in the system: *
Sometimes 'mex -setup' does not list the installed compilers although compiler is installed in the system. This issue is very sporadic in nature and occurs when is no .xml(e.g. mex_C_win64.xml for mingw) file present at 'C:\Users\<username>\AppData\Roaming\MathWorks\MATLAB\<MATLABRELEASEFOLDER>' location. Un-installation of all the instances of Microsoft visual studio and Microsoft C++ redistributables from the system and then installing Microsoft SDK 7.1 in administrator mode does not help here.
A temporary workaround for this issue is to copy the XML file from another machine with the similar setup to the location said above and then run mex -setup.
SUPPORTING LINKS AND INSTRUCTIONS
Installing the SDK 7.1 patch
The SDK 7.1 patch can be download and installed from:
Upgrading Microsoft Visual Studio C++ 2010 to SP1.
Microsoft Visual Studio C++ 2010 SP1 upgrade can be obtained from:

  14 Comments

Hi
I have tried installing sdk on my windows 8.1, it says installation failed. Can someone help me out with this?
If Microsoft Visual Studio C++ 2010 SP1 is already installed, SDK 7.1 may fail to install. In this case:
Remove the 2010 Redistributable packages (both x86 and x64). For that, navigate to the windows control panel -> click on "programs" -> click on "Programs and Features" -> select the required programs to be removed.
Install SDK 7.1 using the instructions above.
Apply the SDK 7.1 patch.
Reinstall 2010 Redistributable packages.
If you have both Microsoft Visual Studio C++ 2010 SP1 and SDK 7.1 already installed, but running into various errors during compilation, apply the SDK 7.1 patch to fix the issue.
Dear MathWorks Support Team: My computer's system is win10, and the version of matlab is R2014a. When I run a file of "lightspeed toolbox", the command window says "错误使用 mex;未找到支持的编译器或 SDK。有关选项,请访问 http://www.mathworks.com/support/compilers/R2014a/win64". Although I follow the index,but I fail to install visual c++ compiler.(I CAN NOT CHECK THE COMPONENT) Please help me with this problem, I would be very grateful. Best Regards

Sign in to comment.


Answer by Andre Silva on 5 Dec 2014

I have this problem again after following these exact instructions over a year ago. This is what I did to solve it using the latest .NET Framework 4.5.2
1. Uninstall all Visual Studio programs/compilers/redistributables etc.
2. Uninstall all .NET Framework programs
3. Uninstall all Windows SDK packages
4. Install Windows SDK 7.1
4a. As per instructions from here
During installation, under the "Installation Options" menu, UNCHECK the "Visual C++ Compilers" and "Microsoft Visual C++ 2010" components.
Download link:
5. Install .NET Framework 4.5.2
6. Applied the SDK 7.1 Patch
7. Reinstall the Microsoft Visual C++ 2010 redistributable packages.
x64:
x86:
8. Open Matlab, and run through the "mex -setup" steps to check the compilers have been linked with Matlab.
-Notes-
I ended up having the problem of not being able to uninstall the SDK in step 3. Some problem that was documented here.
What I did was I disabled my internet connection and using the new SDK 7.1 ISO downloaded in step 4, I was able to uninstall successfully.
--
Also, from the other mathworks link above, I found it was not possible for me to apply the 7.1 patch without a .NET framework installed. So that is why I recommend step 5 before step 6. Otherwise steps 6 and 7 are verbatim from the link.
Hope this helps someone.

  2 Comments

i tried everything but still get the error code 5100, any other way?? i've been struggling for days just to install SDK T.T
Thank you very much. It resolves all the problem in my case!

Sign in to comment.


Answer by Jinyu Xie on 1 Jul 2017
Edited by Walter Roberson
on 1 Jul 2017

  1 Comments

Here is a copy of the instruction provided by Jeremy J Wong :
"
  1. Uninstall any Visual C++ 2010 Redistributables from the control panel first.
  2. Download the corresponding offline ISO image from the Windows SDK archive.
  3. After mounting the image, open F:\Setup\SDKSetup.exe directly.
"
See "Install Instructions" in the webpage offline ISO image to understand which ISO image to download.

Sign in to comment.


Answer by hainingwyx on 13 Mar 2016

hello,I Uninstall .NET Framework 4.5,.NET Framework 4.6,Visual Studio C++ 2010 toVisual Studio C++ 2015,but when I install SDK still can't choose the visual C++ compilers.Then I check files in program files,and delete all file about .Net.Now,I can't run the winsdk_web.exe. Can you give me some advice?

  1 Comments

Install .Net Framework 4.0 and then try to run the installation package for SDK 7.1

Sign in to comment.


Answer by G. SUMA
on 15 Feb 2016
Edited by G. SUMA
on 15 Feb 2016

I tried installing sdk on my windows 8.1. It says installation failed as shown below. Can someone help me with this?

  0 Comments

Sign in to comment.


Answer by Milan
on 11 Mar 2014

Hello, I did your suggestion, first intall .NET framework, than the SDK with the attached patch. I launched Matlab:
mbuild -setup
and I got the following error message: Error: The Microsoft Windows Software Development Kit (SDK) installation is incomplete. Please be sure that the .NET Framework is installed correctly before attempting to reinstall the SDK.
Error using mbuild (line 189) Unable to complete successfully.
I am using R2013b version.
Can you suggest anything to solve the problem?

  5 Comments

I had the same problem... To be specific, I got the "... is incomplete." error when I chose the SDK, and "SDK is not installed." error when I chose the MSVC++ compiler. I dug in pretty deep till I realized that the problem was that I had installed the SDK to a different drive... And some components of the SDK have to be in the boot drive... So when the path of the SDK was queried for in the registry (HKLM\Software\Microsoft\Microsoft SDKs\Windows\v7.1\InstallationFolder), it contained the C: path... but that path, consisting of only compulsorily-on-c-drive components, did not have the rest of the executables.
My solution was to uninstall the SDK, and then reinstall, taking care not to add any of those compulsorily-on-c-drive components (check the disk usage, should be 0). Then the SDK option works.
Worst comes to worst, edit the appropriate .STP files in matlabroot\bin\win64\mbuildopts .
Hi all, I'm using MATLAB R2013b and apparently need to install this SDK in order to install a toolbox I require. The installation of the SDK fails and I get the following:
------------------------------------------------------------------------------------
A problem occurred while installing selected Windows SDK components.
Installation of the "Microsoft Windows SDK for Windows 7" product has reported the following error: Please refer to Samples\Setup\HTML\ConfigDetails.htm document for further information.
Please attempt to resolve the problem and then start Windows SDK setup again. If you continue to have problems with this issue, please visit the SDK team support page at http://go.microsoft.com/fwlink/?LinkId=130245.
Click the View Log button to review the installation log. To exit, click Finish.
------------------------------------------------------------------------------------
So, after reading about the .NET frameworks 4.0 and 4.5 I noticed that in Windows 8.1, which I'm using, 4.5 is already included and I can not uninstall it, only turn it off which I did. However, this doesn't help. The installation fails. Does anyone have a solution for me maybe?
Hi,
I have been trying to install Windows SDK in my PC. I am facing the exact same problem while installing Windows SDK. I have Windows 8.1 and .NET framework wont uninstall from my computer.
Anyone has a solution to this?

Sign in to comment.


Answer by Sina
on 20 Mar 2014

Hi
One question regarding * Troubleshooting * :
After accomplishing step 3 I have both 'Visual C++ 2010 Redistributable packages' and 'Microsoft Visual C++ Compilers 2010 SP1 Standard' installed. Then do I really need to reinstall them again as it said in step 4?

  1 Comments

Hey Sina,
We've updated the answer since then. If the redistributables are already there, and you have everything working, reinstalling them is not necessary.

Sign in to comment.


Answer by Satya
on 30 Oct 2014

I'm installing the SDK 7.1 patch from the link mentioned above.
The installation seems to be stuck and doesn't go past the 15% mark.
Any suggestion for this?

  1 Comments

Hi. I faced this problem before. But now already solved by this instruction( http://ta.speot.is/2012/04/09/visual-studio-2010-sp1-windows-sdk-7-1-install-order/)

Sign in to comment.


Answer by Federico
on 25 Nov 2014
Edited by Federico
on 26 Nov 2014

Hi!
I have windows 8.1 and on my computer there are Microsof Visual C++ 2005/2008/2010/2012 (see attached image) In order to install Windows SDK 7.1, first I have to uninstall all these Microsoft Visual C++ installed , then install SDK 7.1 and at the end re-install the all Microsoft Visual C++ unistalled before, it's right?
And if I uninstall all Microsoft Visual C++, I risk to compromise my computer?