Notices: This section not yet converted to new layout. Download stats are rolling back out.

Visual C++ Build Tools 2015

14.0.25420.1

Package test results are passing.

This package was approved by moderator flcdrg on 9/1/2016.

Overview

Visual C++ Build Tools 2015 provides the essential tools for building C++ applications and libraries targeting Windows desktop. If you want to build your C++ projects targeting Windows desktop without having Visual Studio installed on your computer, Visual C++ Build Tools 2015 provides the requisite C++ compilers, libraries, build scripts, and Windows SDKs.

Customizations

You can customize the installation either by adding optional available features or by specifying own installation configuration file.

Adding optional features

Optional features (Phone tools, etc.) are available but not installed by default.
You can provide optional parameters to include them during the install.
Here is example that includes the Android and iOS build tools:

choco install VisualCppBuildTools -packageParameters "--Features Win81SDKCppBuildSKUV1,Win10EmulatorV1"

Available features: see AdminDeployment.xml

Using own configuration file

Specifying the optional features above modifies the configuration file used during installation (AdminDeployment.xml). If that is not enough you can provide this file on your own.
Example:

choco install VisualCppBuildTools -packageParameters "--AdminFile c:\path to your\AdminDeployment.xml"
choco install VisualCppBuildTools -packageParameters "--AdminFile http://path/to/your/AdminDeployment.xml"

To install Visual C++ Build Tools 2015, run the following command from the command line or from PowerShell:

C:\> choco install visualcppbuildtools

To upgrade Visual C++ Build Tools 2015, run the following command from the command line or from PowerShell:

C:\> choco upgrade visualcppbuildtools

Files

Hide
  • tools\VSModules.psm1 Show
    # Parse input argument string into a hashtable
    # Format: /AdminFile:file location /Features:WebTools,Win8SDK /ProductKey:AB-D1
    function Parse-Parameters ($s)
    {
        $parameters = @{ }
    
        if (!$s)
        {
            Write-Debug "No package parameters."
            return $parameters
        }
    
        Write-Debug "Package parameters: $s"
        $s = ' ' + $s
        [String[]] $kvpPrefix = @(" --")
        $kvpDelimiter = ' '
    
        $kvps = $s.Split($kvpPrefix, [System.StringSplitOptions]::RemoveEmptyEntries)
        foreach ($kvp in $kvps)
        {
            Write-Debug "Package parameter kvp: $kvp"
            $delimiterIndex = $kvp.IndexOf($kvpDelimiter)
            if (($delimiterIndex -le 0) -or ($delimiterIndex -ge ($kvp.Length - 1))) { continue }
    
            $key = $kvp.Substring(0, $delimiterIndex).Trim().ToLower()
            if ($key -eq '') { continue }
            $value = $kvp.Substring($delimiterIndex + 1).Trim()
    
            Write-Debug "Package parameter: key=$key, value=$value"
            $parameters.Add($key, $value)
        }
    
        return $parameters
    }
    
    # Generates customizations file. Returns its path
    function Generate-Admin-File($parameters, $defaultAdminFile)
    {
        $adminFile = $parameters['AdminFile']
        $features = $parameters['Features']
        if (!$adminFile -and !$features)
        {
            return $null
        }
    
        $localAdminFile = (Join-Path $env:temp 'AdminDeployment.xml')
        if (Test-Path $localAdminFile)
        {
            Remove-Item $localAdminFile
        }
    
        if ($adminFile)
        {
            if (Test-Path $adminFile)
            {
                Copy-Item $adminFile $localAdminFile -force
            }
            else
            {
                if (($adminFile -as [System.URI]).AbsoluteURI -ne $null)
                {
                    Get-ChocolateyWebFile 'adminFile' $localAdminFile $adminFile
                }
                else
                {
                    throw 'Invalid AdminFile setting.'
                }
            }
        }
        elseif ($features)
        {
            Copy-Item $defaultAdminFile $localAdminFile -force
        }
    
        return $localAdminFile
    }
    
    # Turns on features in the customizations file
    function Update-Admin-File($parameters, $adminFile)
    {
        if (!$adminFile) { return }
        $s = $parameters['Features']
        if (!$s) { return }
    
        $features = $s.Split(',')
        [xml]$xml = Get-Content $adminFile
    
        foreach ($feature in $features)
        {
            $node = $xml.DocumentElement.SelectableItemCustomizations.ChildNodes | ? {$_.Id -eq "$feature"}
            if ($node -ne $null)
            {
                $node.Selected = "yes"
            }
        }
        $xml.Save($adminFile)
    }
    
    function Generate-Install-Arguments-String($parameters, $adminFile)
    {
        $s = "/Quiet /NoRestart /Log $env:temp\vs.log"
    
        if ($adminFile)
        {
            $s = $s + " /AdminFile $adminFile"
        }
    
        $pk = $parameters['ProductKey']
        if ($pk)
        {
            $s = $s + " /ProductKey $pk"
        }
    
        return $s
    }
    
    function Install-VS {
    <#
    .SYNOPSIS
    Installs Microsoft Visual C++ Build Tools
    
    .DESCRIPTION
    Installs Microsoft Visual C++ Build Tools with ability to specify additional features.
    
    .PARAMETER PackageName
    The name of the Microsoft Visual C++ Build Tools package - this is arbitrary.
    It's recommended you call it the same as your nuget package id.
    
    .PARAMETER Url
    This is the url to download the VS web installer.
    
    .EXAMPLE
    Install-VS 'VisualCppBuildTools' 'http://download.microsoft.com/download/5/f/7/5f7acaeb-8363-451f-9425-68a90f98b238/visualcppbuildtools_full.exe'
    
    .OUTPUTS
    None
    
    .NOTES
    This helper reduces the number of lines one would have to write to download and install Microsoft Visual C++ Build Tools.
    This method has no error handling built into it.
    
    .LINK
    Install-ChocolateyPackage
    #>
    param(
      [string] $packageName,
      [string] $url,
      [string] $exeName,
      [string] $checksum
    )
            Write-Debug "Running 'Install-VS' for $packageName with url:`'$url`'";
     
        $installerType = 'exe'
        $validExitCodes = @(
            0, # success
            3010, # success, restart required
            2147781575 # pending restart required
        )
     
        $defaultAdminFile = (Join-Path $PSScriptRoot 'AdminDeployment.xml')
        Write-Debug "Default AdminFile: $defaultAdminFile"
     
        $packageParameters = Parse-Parameters $env:chocolateyPackageParameters
        if ($packageParameters.Length -gt 0) { Write-Output $packageParameters }
     
        $adminFile = Generate-Admin-File $packageParameters $defaultAdminFile
        Write-Debug "AdminFile: $adminFile"
     
        Update-Admin-File $packageParameters $adminFile
     
        $silentArgs = Generate-Install-Arguments-String $packageParameters $adminFile
        
        Write-Output "Install-ChocolateyPackage $packageName $installerType $silentArgs $url -validExitCodes $validExitCodes"
        Install-ChocolateyPackage $packageName $installerType $silentArgs $url -validExitCodes $validExitCodes -Checksum $checksum -ChecksumType sha256
    
    }
    
    function Uninstall-VS {
    <#
    .SYNOPSIS
    Uninstalls Microsoft Visual C++ Build Tools
    
    .DESCRIPTION
    Uninstalls Microsoft Visual C++ Build Tools.
    
    .PARAMETER PackageName
    The name of the VisualCppBuildTools package.
    
    .PARAMETER ApplicationName
    The VisualStudio app name - i.e. 'Microsoft Visual C++ Build Tools'.
    
    .PARAMETER UninstallerName
    This name of the installer executable - i.e. 'vs_community.exe'.
    
    .EXAMPLE
    Uninstall-VS 'VisualCppBuildTools' 'Microsoft Visual C++ Build Tools' 'visualcppbuildtools_full.exe'
    
    .OUTPUTS
    None
    
    .NOTES
    This helper reduces the number of lines one would have to write to uninstall Visual Studio.
    This method has no error handling built into it.
    
    .LINK
    Uninstall-ChocolateyPackage
    #>
    param(
      [string] $packageName,
      [string] $applicationName,
      [string] $uninstallerName
    )
        Write-Debug "Running 'Uninstall-VS' for $packageName with url:`'$url`'";
    
        $installerType = 'exe'
        $silentArgs = '/Uninstall /force /Passive /NoRestart'
    
        $app = Get-WmiObject -Class Win32_Product | Where-Object { $_.Name -like "$applicationName*"} | Sort-Object { $_.Name } | Select-Object -First 1
        if ($app -ne $null)
        {
            $uninstaller = Get-Childitem "$env:ProgramData\Package Cache\" -Recurse -Filter $uninstallerName | ? { $_.VersionInfo.ProductVersion.StartsWith($app.Version)}
            if ($uninstaller -ne $null)
            {
                Uninstall-ChocolateyPackage $packageName $installerType $silentArgs $uninstaller.FullName
            }
        }
    }
    
    Export-ModuleMember Install-VS, Uninstall-VS
    
  • tools\ChocolateyUninstall.ps1 Show
    Import-Module (Join-Path $(Split-Path -parent $MyInvocation.MyCommand.Definition) 'VSModules.psm1')
     
    Uninstall-VS 'VisualCppBuildTools' 'Microsoft Visual C++ Build Tools' 'visualcppbuildtools_full.exe'
  • tools\ChocolateyInstall.ps1 Show
    Import-Module (Join-Path $(Split-Path -parent $MyInvocation.MyCommand.Definition) 'VSModules.psm1')
     
    Install-VS 'VisualCppBuildTools' 'http://download.microsoft.com/download/5/f/7/5f7acaeb-8363-451f-9425-68a90f98b238/visualcppbuildtools_full.exe' 'visualcppbuildtools_full.exe' '1E1774869ABD953D05D10372B7C08BFA0C76116F5C6DF1F3D031418CCDCD8F7B'
  • tools\AdminDeployment.xml Show
    <?xml version="1.0" encoding="utf-8"?>
    <AdminDeploymentCustomizations xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.microsoft.com/wix/2011/AdminDeployment">
      <BundleCustomizations TargetDir="default" NoCacheOnlyMode="default" NoWeb="default" NoRefresh="default" SuppressRefreshPrompt="default" Feed="default" />
      <SelectableItemCustomizations>
        <SelectableItemCustomization Id="VSUV1PreReqV1" Selected="no" FriendlyName="Visual Studio 2015 Update 1 Prerequisite" />
        <SelectableItemCustomization Id="VSUV3RTMV1" Selected="no" FriendlyName="Visual Studio 2015 Update 3" />
        <SelectableItemCustomization Id="MicroUpdateV3.4" Selected="no" FriendlyName="Update for Microsoft Visual Studio 2015 (KB3165756)" />
        <SelectableItemCustomization Id="Win81SDK_CppBuildSKUV1" Hidden="no" Selected="yes" FriendlyName="Windows 8.1 SDK" />
        <SelectableItemCustomization Id="PythonToolsForVisualStudioV6" Hidden="no" Selected="no" FriendlyName="Python Tools for Visual Studio (June 2016)" />
        <SelectableItemCustomization Id="ClickOnceV1" Hidden="no" Selected="no" FriendlyName="ClickOnce Publishing Tools" />
        <SelectableItemCustomization Id="PowerShellToolsV1" Hidden="no" Selected="no" FriendlyName="PowerShell Tools for Visual Studio" />
        <SelectableItemCustomization Id="Windows10_ToolsAndSDKV13" Hidden="no" Selected="no" FriendlyName="Tools (1.4.1) and Windows 10 SDK (10.0.14393)" />
        <SelectableItemCustomization Id="Win10_EmulatorV1" Selected="no" FriendlyName="Emulators for Windows 10 Mobile (10.0.10240)" />
        <SelectableItemCustomization Id="Win10_EmulatorV2" Selected="no" FriendlyName="Emulators for Windows 10 Mobile (10.0.10586)" />
        <SelectableItemCustomization Id="Win10_EmulatorV3" Hidden="no" Selected="no" FriendlyName="Emulators for Windows 10 Mobile (10.0.14393)" />
        <SelectableItemCustomization Id="XamarinVSCoreV5" Hidden="no" Selected="no" FriendlyName="C#/.NET (Xamarin v4.1.1)" />
        <SelectableItemCustomization Id="XamarinPT_V1" Selected="no" FriendlyName="Xamarin Preparation Tool" />
        <SelectableItemCustomization Id="MDDJSCoreV11" Hidden="no" Selected="no" FriendlyName="HTML/JavaScript (Apache Cordova) Update 10" />
        <SelectableItemCustomization Id="AndroidNDK11C_V1" Hidden="no" Selected="no" FriendlyName="Android Native Development Kit (R11C, 32 bits)" />
        <SelectableItemCustomization Id="AndroidNDK11C_32_V1" Hidden="no" Selected="no" FriendlyName="Android Native Development Kit (R11C, 32 bits)" />
        <SelectableItemCustomization Id="AndroidNDK11C_64_V1" Hidden="no" Selected="no" FriendlyName="Android Native Development Kit (R11C, 64 bits)" />
        <SelectableItemCustomization Id="AndroidNDKV1" Hidden="no" Selected="no" FriendlyName="Android Native Development Kit (R10E, 32 bits)" />
        <SelectableItemCustomization Id="AndroidNDK_32_V1" Hidden="no" Selected="no" FriendlyName="Android Native Development Kit (R10E, 32 bits)" />
        <SelectableItemCustomization Id="AndroidNDK_64_V1" Hidden="no" Selected="no" FriendlyName="Android Native Development Kit (R10E, 64 bits)" />
        <SelectableItemCustomization Id="AndroidSDKV1" Hidden="no" Selected="no" FriendlyName="Android SDK" />
        <SelectableItemCustomization Id="AndroidSDK_API1921V1" Hidden="no" Selected="no" FriendlyName="Android SDK Setup (API Level 19 and 21)" />
        <SelectableItemCustomization Id="AndroidSDK_API22V1" Hidden="no" Selected="no" FriendlyName="Android SDK Setup (API Level 22)" />
        <SelectableItemCustomization Id="AndroidSDK_API23V1" Hidden="no" Selected="no" FriendlyName="Android SDK Setup (API Level 23)" />
        <SelectableItemCustomization Id="AntV1" Hidden="no" Selected="no" FriendlyName="Apache Ant (1.9.3)" />
        <SelectableItemCustomization Id="L_MDDCPlusPlus_iOS_V7" Hidden="no" Selected="no" FriendlyName="Visual C++ iOS Development (Update 3)" />
        <SelectableItemCustomization Id="L_MDDCPlusPlus_Android_V7" Hidden="no" Selected="no" FriendlyName="Visual C++ Android Development (Update 3)" />
        <SelectableItemCustomization Id="L_MDDCPlusPlus_ClangC2_V6" Hidden="no" Selected="no" FriendlyName="Clang with Microsoft CodeGen (July 2016)" />
        <SelectableItemCustomization Id="L_IncrediBuild_V1" Selected="no" FriendlyName="IncrediBuild" />
        <SelectableItemCustomization Id="JavaJDKV1" Hidden="no" Selected="no" FriendlyName="Java SE Development Kit (7.0.550.13)" />
        <SelectableItemCustomization Id="Node.jsV1" Hidden="no" Selected="no" FriendlyName="Joyent Node.js" />
        <SelectableItemCustomization Id="VSEmu_AndroidV1.1.622.2" Hidden="no" Selected="no" FriendlyName="Microsoft Visual Studio Emulator for Android (July 2016)" />
        <SelectableItemCustomization Id="WebSocket4NetV1" Hidden="no" Selected="no" FriendlyName="WebSocket4Net" />
        <SelectableItemCustomization Id="GitForWindowsx64V6" Hidden="no" Selected="no" FriendlyName="Git for Windows" />
        <SelectableItemCustomization Id="GitForWindowsx86V6" Hidden="no" Selected="no" FriendlyName="Git for Windows" />
        <SelectableItemCustomization Id="GitHubVSV1" Hidden="no" Selected="no" FriendlyName="GitHub Extension for Visual Studio" />
        <SelectableItemCustomization Id="VS_SDK_GroupV5" Hidden="no" Selected="no" FriendlyName="Visual Studio Extensibility Tools Update 3" />
        <SelectableItemCustomization Id="VS_SDK_Breadcrumb_GroupV5" Selected="no" FriendlyName="Visual Studio Extensibility Tools Update 3" />
        <SelectableItemCustomization Id="Win10_VSToolsV13" Hidden="no" Selected="no" FriendlyName="Tools for Universal Windows Apps (1.4.1) and Windows 10 SDK (10.0.14393)" />
        <SelectableItemCustomization Id="Win10SDK_HiddenV1" Hidden="no" Selected="no" FriendlyName="Windows 10 SDK (10.0.10240)" />
        <SelectableItemCustomization Id="Win10SDK_HiddenV2" Selected="no" FriendlyName="Windows 10 SDK (10.0.10586)" />
        <SelectableItemCustomization Id="Win10SDK_HiddenV3" Hidden="no" Selected="no" FriendlyName="Windows 10 SDK (10.0.10586)" />
        <SelectableItemCustomization Id="Win10SDK_HiddenV4" Selected="no" FriendlyName="Windows 10 SDK (10.0.14393)" />
        <SelectableItemCustomization Id="Win10SDK_VisibleV1" Hidden="no" Selected="no" FriendlyName="Windows 10 SDK 10.0.10240" />
        <SelectableItemCustomization Id="UWPPatch_KB3073097_HiddenV3" Selected="no" FriendlyName="KB3073097" />
        <SelectableItemCustomization Id="JavaScript_HiddenV12" Selected="no" FriendlyName="JavaScript Project System for Visual Studio" />
        <SelectableItemCustomization Id="AppInsightsToolsVisualStudioHiddenVSU3RTMV1" Selected="no" FriendlyName="Developer Analytics Tools v7.0.2" />
        <SelectableItemCustomization Id="AppInsightsToolsVSWinExpressHiddenVSU3RTMV1" Selected="no" FriendlyName="Developer Analytics Tools v7.0.2" />
        <SelectableItemCustomization Id="AppInsightsToolsVWDExpressHiddenVSU3RTMV1" Selected="no" FriendlyName="Developer Analytics Tools v7.0.2" />
        <SelectableItemCustomization Id="UWPStartPageV1" Selected="no" FriendlyName="Tools for Universal Windows Apps Getting Started Experience" />
        <SelectableItemCustomization Id="VisualCppBuildTools_ATLMFC_SDK" Hidden="no" Selected="no" FriendlyName="ATL/MFC SDK" />
        <SelectableItemCustomization Id="VisualCppBuildTools_NETFX_SDK" Hidden="no" Selected="no" FriendlyName=".NET Framework SDK" />
      </SelectableItemCustomizations>
    </AdminDeploymentCustomizations>

Virus Scan Results

In cases where actual malware is found, the packages are subject to removal. Software sometimes has false positives. Moderators do not necessarily validate the safety of the underlying software, only that a package retrieves software from the official distribution point and/or validate embedded software against official distribution point (where distribution rights allow redistribution).

Chocolatey Pro provides runtime protection from possible malware.

Dependencies

This package has no dependencies.

Package Maintainer(s)

Software Author(s)

  • Microsoft

Tags

Release Notes

  • Updated to latest version with new logic including cheksum validation

Version History

Version Downloads Last updated Status
Visual C++ Build Tools 2015 14.0.25123.0 690 Thursday, April 21, 2016 approved
Visual C++ Build Tools 2015 Technical Preview 14.0.24720.01 272 Tuesday, April 5, 2016 approved

Discussion for the Visual C++ Build Tools 2015 Package

Ground rules:

  • This discussion is only about Visual C++ Build Tools 2015 and the Visual C++ Build Tools 2015 package. If you have feedback for Chocolatey, please contact the google group.
  • This discussion will carry over multiple versions. If you have a comment about a particular version, please note that in your comments.
  • The maintainers of this Chocolatey Package will be notified about new comments that are posted to this Disqus thread, however, it is NOT a guarantee that you will get a response. If you do not hear back from the maintainers after posting a message below, please follow up by using the link on the left side of this page or follow this link to contact maintainers. If you still hear nothing back, please follow the package triage process.
  • Tell us what you love about the package or Visual C++ Build Tools 2015, or tell us what needs improvement.
  • Share your experiences with the package, or extra configuration or gotchas that you've found.
  • If you use a url, the comment will be flagged for moderation until you've been whitelisted. Disqus moderated comments are approved on a weekly schedule if not sooner. It could take between 1-5 days for your comment to show up.

comments powered by Disqus
Chocolatey.org uses cookies to enhance the user experience of the site.
Ok