Skip to content

Instantly share code, notes, and snippets.

@aljbri
Created September 21, 2020 16:39
Show Gist options
  • Save aljbri/d129e07a72f572aec6eaf9680b6d5f59 to your computer and use it in GitHub Desktop.
Save aljbri/d129e07a72f572aec6eaf9680b6d5f59 to your computer and use it in GitHub Desktop.
Microsoft Visual C++ 14.0 Build Tools

What is it about?

Sometimes while installing a new packages in Python we may get the following error:

error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools

In this tiny note, you can get the direct installer for the Microsoft Visual C++ Build Tools 14.0 and you can make an offline installer. Therefore, you can use it on a different computer

Before do anything, install or upgrade the Setuptools Python package. It contain compatibility improvements and add automatic use of compilers [source]

pip install --upgrade setuptools

link

To get the the C++ Build Tools you can get it dircetly from Microsoft throught the provided links:

  • Microsoft Visual C++ 14.0 Build Tools which comes with Microsoft Visual Studio 2015 Download Link

To create an offline installation layout

  1. After you download the installer to a location on your file system, run "visualcppbuildtools_full.exe /layout". For example, run:
visualcppbuildtools_full.exe /layout D:\VisualCppBuildTools_Full_14.0

By using the /layout switch, you can download almost all the installation packages, not just the ones that apply to the download machine. This approach gives you the files that you need to run this installer anywhere and it might be useful if you want to install components that weren't installed originally.

  1. After you run this command, a dialog box will appear that allows you to change the folder where you want the offline installation layout to reside. Next, click the Download button.

  2. When the package download is successful, you should see a message that says Setup Successful! All specified components have been acquired successfully.

Create an Offline Installation of Visual Studio

@aljbri
Copy link
Author

aljbri commented Jan 26, 2024

@Jaighalor @RakeshChowdhury thanks for your contribution.

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