Site Tools


Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
developer:sdksamples:vcredist [2015/09/14]
127.0.0.1 external edit
developer:sdksamples:vcredist [2016/03/22] (current)
sandy
Line 1: Line 1:
 ====== Distributing Visual C++ Runtimes ====== ====== Distributing Visual C++ Runtimes ======
 > **Developer:​** //​[[developer:​cplusplusplugins|C++]]//​ > **Developer:​** //​[[developer:​cplusplusplugins|C++]]//​
-> **Summary:​** //Discusses the distribution of Microsoft Visual C++ 2005 runtimes for C++ plug-ins.//+> **Summary:​** //Discusses the distribution of Microsoft Visual C++ 2005 runtimes for C++ plug-ins//
 > **Updated:​** //June 17, 2011// > **Updated:​** //June 17, 2011//
  
-===== Overview ===== +If you do not have Visual C++ 2005 installed on your computer, the Microsoft Visual C++ 2005 Redistributable Packages install runtime components of Visual C++ Libraries required to run C++ plug-ins developed with Visual C++.
-The Microsoft Visual C++ 2005 Redistributable Packages install runtime components of Visual C++ Libraries required to run C++ plug-ins developed with Visual C++ on a computer that does not have Visual C++ 2005 installed.+
  
-These packages install runtime components of C Runtime (CRT), Standard C++, ATL, MFC, OpenMP and MSDIA libraries. For libraries that support side-by-side deployment ​model (CRT, SCL, ATL, MFC, OpenMP) they are installed into the native assembly cache, also called WinSxS folder, on versions of Windows operating system that support side-by-side assemblies.+These packages install runtime components of C Runtime (CRT), Standard C++, ATL, MFC, OpenMPand MSDIA libraries. For libraries that support side-by-side deployment ​models ​(CRT, SCL, ATL, MFC, OpenMP) they are installed into the native assembly cache, also called WinSxS folder, on versions of Windows operating system that support side-by-side assemblies.
  
-===== More Information ​===== +===== More information ​=====
-Any Rhino plug-in that you build has dependencies on assemblies (DLLs). A Rhino C++ plug-in, which is an MFC DLL, (in a release build) depends at least on the CRT (msvcr80.dll,​ msvcp80.dll) and MFC (mfc80.dll or mfc80u.dll) assemblies. You, the plug-in developer, have these assemblies on your machine because you have Visual C++ 2005 installed. But a machine without Visual C++ 2005 may not have them. In order to be able to run your plug-in on such machines, you have to redistribute these assemblies.+
  
-In order to redistribute the required assemblies, ​you need to know which version of the assemblies ​are required by your plug-in. ​For example, plug-ins built with Visual C++ 2005 SP1 will require ​different version of the Microsoft ​Visual C++ 2005 Redistributable Package than a plug-in ​built with a non-service packed version of Visual C++ 2005.+Any Rhino plug-in that you build has dependencies on assemblies ​(DLLs). A Rhino C++ plug-in, which is an MFC DLL, (in a release build) depends at least on the CRT (msvcr80.dllmsvcp80.dll) and MFC (mfc80.dll or mfc80u.dll) assemblies. You, the plug-in developer, have these assemblies on your machine because you have Visual C++ 2005 installed. But machine without ​Visual C++ 2005 may not have them. To be able to run your plug-in ​on such machines, you have to redistribute these assemblies.
  
-===== Redistributable Packages Versions ===== +To redistribute the required assemblies, ​you need to know which version of the assemblies ​your plug-in ​requires. For example, ​ a plug-in built with Visual C++ 2005 SP1 requires a different version of the Microsoft Visual C++ 2005 Redistributable Package ​than a plug-in built with a non-service packed ​version of Visual C++ 2005.
-  * If you have built your plug-in Visual C++ 2005, then you will need to redistribute ​the **[[http://​www.microsoft.com/​download/​en/​details.aspx?​id=3387|Microsoft Visual C++ 2005 Redistributable Package ​(x86)]]** ​with your application. Note, the version of these assemblies are **8.0.50727.42**.+
  
-  * If you have built your plug-in Visual C++ 2005 SP1, then you will need to redistribute the **[[http://​www.microsoft.com/​download/​en/​details.aspx?​id=5638|Microsoft Visual C++ 2005 SP1 Redistributable ​Package (x86)]]** with your application. Note, the version of these assemblies are **8.0.50727.762**.+===== Redistributable ​Packages versions =====
  
-  * If you have built your plug-in Visual C++ 2005 SP1 and have installed the [[http://​www.microsoft.com/​technet/​security/​bulletin/​MS09-035.mspx|ATL Security Update]]then you will need to redistribute the **[[http://​www.microsoft.com/​download/​en/​details.aspx?​id=14431|Microsoft Visual C++ 2005 Service Pack 1 Redistributable Package ​ATL Security Update]]** with your application. Note, the version of these assemblies are **8.0.50727.4053**.+  * If you built your plug-in ​with Visual C++ 2005, redistribute the **[[http://​www.microsoft.com/​download/​en/​details.aspx?​id=3387|Microsoft Visual C++ 2005 Redistributable Package ​(x86)]]** with your application. Note, the version of these assemblies are **8.0.50727.42**.
  
-  * If you have built your plug-in Visual C++ 2005 SP1 and have installed the [[http://​www.microsoft.com/​technet/​security/​bulletin/​MS11-025.mspx|MFC Security Update]]then you will need to redistribute the **[[http://​www.microsoft.com/​download/​en/​details.aspx?​id=26347|Microsoft Visual C++ 2005 Service Pack 1 Redistributable Package ​MFC Security Update]]** with your application. Note, the version of these assemblies ​are **8.0.50727.5592** or **8.0.50727.6195**.+  * If you have built your plug-in ​with Visual C++ 2005 SP1, redistribute the **[[http://​www.microsoft.com/​download/​en/​details.aspx?​id=5638|Microsoft Visual C++ 2005 SP1 Redistributable Package ​(x86)]]** with your application. Note, the version of these assemblies ​is **8.0.50727.762**.
  
-===== Which Package to Redistribute?​ ===== +  * If you built your plug-in ​with Visual C++ 2005 SP1 and have installed the [[http://​www.microsoft.com/​technet/​security/​bulletin/​MS09-035.mspx|ATL Security Update]]redistribute ​the **[[http://​www.microsoft.com/​download/​en/​details.aspx?​id=14431|Microsoft ​Visual C++ 2005 Service Pack 1 Redistributable Package ATL Security Update]]** with your application. Notethe version of these assemblies is **8.0.50727.4053**.
-To know which Redistributable Package to included with your plug-in ​installation,​ you need to know what is installed ​on the system that built your plug-inAndwith the dozens of Microsoft ​Windows updates that have been available over the yearsit can be a real a challenge to determine what version, service pack and security updates ​of Visual Studio 2005 you have installed+
  
-One sure fire way to know what Redistributable Package your plug-in requires is to examine your plug-ins //​Manifest//​. A manifest is an XML document that can be an external XML file or a resource embedded inside an application or an assembly (plug-in). The manifest of an isolated application is used to manage the names and versions of shared side-by-side assemblies to which the application should bind at run time. The manifest of a side-by-side assembly specifies its dependencies on names, versions, resources, and other assemblies.+  * If you built your plug-in with Visual C++ 2005 SP1 and have installed the [[http://​www.microsoft.com/​technet/​security/​bulletin/​MS11-025.mspx|MFC Security Update]], redistribute the **[[http://​www.microsoft.com/​download/​en/​details.aspx?​id=26347|Microsoft Visual C++ 2005 Service Pack 1 Redistributable Package MFC Security Update]]** with your application. Note, the versions of these assemblies are **8.0.50727.5592** or **8.0.50727.6195**. 
 + 
 +===== Which package to redistribute?​ ===== 
 + 
 +To know which Redistributable Package to include with your plug-in installation,​ you need to know what is installed on the system that built your plug-in. With the dozens of Microsoft Windows updates that have been available over the years, it can be a real challenge to determine what version, service pack, and security updates of Visual Studio 2005 you have installed.  
 + 
 +One sure way to know what Redistributable Package your plug-in requires is to examine your plug-in'​s ​//​Manifest//​. A manifest is an XML document that can be an external XML file or a resource embedded inside an application or an assembly (plug-in). The manifest of an isolated application is used to manage the names and versions of shared side-by-side assemblies to which the application should bind at run time. The manifest of a side-by-side assembly specifies its dependencies on names, versions, resources, and other assemblies.
  
 One way to determine the required assemblies of your plug-in is to use the Manifest Tool (MT.EXE) included with Visual C++ 2005. For example, from a Visual Studio command prompt, you can do the following: One way to determine the required assemblies of your plug-in is to use the Manifest Tool (MT.EXE) included with Visual C++ 2005. For example, from a Visual Studio command prompt, you can do the following:
Line 63: Line 65:
 </​code>​ </​code>​
  
-In this example, we can see that the requried ​verison of CRT and MFC is 8.0.50727.5592. In this case, we will need to included ​the [[http://​www.microsoft.com/​download/​en/​details.aspx?​id=26347|Microsoft Visual C++ 2005 Service Pack 1 Redistributable Package MFC Security Update]] when distributing this plug-in.+In this example, we can see that the required ​verison of CRT and MFC is 8.0.50727.5592. In this case, include ​the [[http://​www.microsoft.com/​download/​en/​details.aspx?​id=26347|Microsoft Visual C++ 2005 Service Pack 1 Redistributable Package MFC Security Update]] when distributing this plug-in. 
 + 
 +===== Other resources =====
  
-===== Other Resources ===== +Besides ​the Manifest Tool (MT.EXE) included with Visual C++ 2005, there are other useful tools for helping determine required assemblies. ​
-In addition to the Manifest Tool (MT.EXE) included with Visual C++ 2005, there are other useful tools for helping determine required assemblies. ​+
  
-**[[http://​www.dependencywalker.com|Dependency Walker]]**, by Steve P. Miller, is a free utility that scans any 32-bit or 64-bit Windows module (EXE, DLL, RHP, etc.) and builds a hierarchical tree diagram of all dependent modules. Dependency Walker is very useful for troubleshooting system errors related to loading and executing modules.+**[[http://​www.dependencywalker.com|Dependency Walker]]**, by Steve P. Miller, is a free utility that scans any 32-bit or 64-bit Windows module (EXE, DLL, RHP, etc.) and builds a hierarchical tree diagram of all dependent modules. Dependency Walker is useful for troubleshooting system errors related to loading and executing modules.
  
-**[[http://​weblogs.asp.net/​kennykerr/​archive/​2007/​07/​10/​manifest-view-1-0.aspx|Manifest View]]**, by Kenny Kerr, is also a free utility for viewing an application'​s manifest. This tool similar to the Manifest Tool but much easier to use.+**[[http://​weblogs.asp.net/​kennykerr/​archive/​2007/​07/​10/​manifest-view-1-0.aspx|Manifest View]]**, by Kenny Kerr, is also a free utility for viewing an application'​s manifest. This tool is similar to the Manifest Tool but much easier to use.
  
 \\ \\
developer/sdksamples/vcredist.1442255296.txt.gz · Last modified: 2016/03/16 (external edit)