Click to Rate and Give Feedback
MSDN
MSDN Library
Visual Studio 2005
Visual Studio
Visual C++
Reference
Libraries Reference
 Visual C++ Libraries as Shared Side...
This page is specific to
Microsoft Visual Studio 2005/.NET Framework 2.0

Other versions are also available for the following:
Visual C++ Libraries 
Visual C++ Libraries as Shared Side-by-Side Assemblies 

In Visual C++ 2005, the ATL, MFC, Standard C++, and CRT libraries support the new deployment model available on Windows XP, Windows Server 2003, and Windows Vista. The DLLs corresponding to all Visual C++ libraries have been grouped into several shared side-by-side assemblies and are installed into the native assembly cache, also called the WinSxS folder, under the operating system root directory. Similarly, while building a C++ application using Visual C++ 2005, by default the compiler and the linker generate a manifest file that describes runtime dependencies of this application on Visual C++ libraries.

Visual C++ libraries cannot be used by a C/C++ application without a manifest binding the application to these libraries. If a C/C++ application that depends on a Visual C++ library does not use a manifest, then an attempt to load the Visual C++ library as a dependent DLL from the application-local folder will result in an error message indicating that this is an unsupported way of loading a Visual C++ library.

NoteNote

On versions of Windows that do not support deployment of shared side-by-side assemblies, such as Windows 98 and Windows 2000 Server, the Visual C++ libraries are installed in the System32 folder and WinSxS folder under the operating system root directory. This setup enables running Visual C++ applications on these operating system versions because they do not support manifest-based binding of applications to dependent DLLs. On these operating systems, when an application is loaded, the corresponding manifest file is ignored and the operating systems searches for dependent DLLs using paths set in the current running environment. However, on upgrading the operating system to a version that support manifest-based binding, such as Windows XP, Windows Server 2003, or Windows Vista, applications built with manifests start using the DLLs installed in the WinSxS folder.

This change to the deployment model of Visual C++ libraries prevents the problem of version conflicts between DLLs that occur when you add updates or configurations to a machine, and will allow support of side-by-side installation of two different Visual C++ toolsets. It will also allow you to produce reliable, self-describing applications and components that will not conflict with existing components. For more information on the advantages of new deployment model, please see Concepts of Isolated Applications and Side-by-side Assemblies. To learn about how this may impact deployment of existing native C++ applications, please refer to Redistributing Visual C++ Files.

Visual C++ libraries have been packaged in several shared side-by-side assemblies with corresponding manifest files.

Assembly Name DLLs included in the assembly Visual C++ Library

Microsoft.VC80.ATL

atl80.dll

Active Template Library

Microsoft.VC80.CRT

msvcr80.dll

msvcp80.dll

msvcm80.dll

C Runtime Library, release DLLs

Microsoft.VC80.DebugCRT

msvcr80d.dll

msvcp80d.dll

msvcm80d.dll

C Runtime Library, debug DLLs

Microsoft.VC80.MFC

mfc80.dll

mfcm80.dll

mfc80u.dll

mfcm80u.dll

Microsoft Foundation Classes, release DLLs

Microsoft.VC80.DebugMFC

mfc80d.dll

mfcm80d.dll

mfc80ud.dll

mfcm80ud.dll

Microsoft Foundation Classes, debug DLLs

Microsoft.VC80.MFCLOC

mfc80chs.dll

mfc80deu.dll

mfc80esp.dll

mfc80ita.dll

mfc80kor.dll

mfc80cht.dll

mfc80enu.dll

mfc80fra.dll

mfc80jpn.dll

Microsoft Foundation Classes, localized resources

Microsoft.VC80.OpenMP

vcomp.dll

OpenMP Library, release DLLs

Microsoft.VC80.DebugOpenMP

Vcompd.dll

OpenMP Library, debug DLLs

When you build applications with Visual C++ 2005, you may need to redistribute Visual C++ libraries and deploy the corresponding DLLs to customers' desktops. For more information please see Deployment (C++).

Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Warning      jorendorff   |   Edit   |   Show History
Microsoft offers redistributable merge modules that you can build into your MSI to correctly install these DLLs, but it seems those merge modules require Windows Installer 3.0. (At least, people are sometimes unable to install MSIs that use these merge modules, and upgrading to Windows Installer 3.0 or later seems to fix the problem.) Depending on your needs this may or may not be okay.

Bizarrely, this means there is no good deployment story for a simple Visual C++ 2005 app that uses the C or C++ standard libraries. Your options are: (1) statically link the CRT -- which is not always possible; (2) forget SxS deployment and deploy these DLLs to your application directory -- but you must also manually create a manifest in order to get this to work; (3) somehow hack around this in MSI -- I haven't attempted this; (4) require your customers to have Windows Installer 3.0 or later -- which means some Windows 2000 and 2003 customers will need to upgrade; or (5) go back to an older version of VC++.

Tags What's this?: Add a tag
Flag as ContentBug
Re:Warning      Ted_   |   Edit   |   Show History
The Windows Installer 3.0 requirement is no longer true for apps built with VC2005 SP1. They only require Windows Installer 2.0 to be available.
Tags What's this?: Add a tag
Flag as ContentBug
VS2005 SP1 installs wrong MSMs      Erik Cassel   |   Edit   |   Show History

WARNING: VS2005 SP1 installs some MSM files with version 8.0.50727.42, but builds your code against 8.0.50727.762. WHen you deploy your app on a raw WinXP machine, it gets the 8.0.50727.42 redistributables from the MSMs, which won't work with your installed app.

My workaround is to put the 8.0.50727.762 MSM versions into "C:\Program Files\Common Files\Merge Modules"

Here are some example affected files:

Microsoft_VC80_CRT_x86.msm

Microsoft_VC80_ATL_x86.msm

Deployment project prerequisites      GrkEngnr   |   Edit   |   Show History

You could also check the properties of your deployment project and click the Prerequisites button which brings up a list of available prerequisites such as .Net, CRT, and Windows Installer. I often choose these 3 components and when a user first runs my installer, it will check if the prerequisites are installed. If not, the installer will run the prerequisite installers first.

Tags What's this?: Add a tag
Flag as ContentBug
Processing
© 2009 Microsoft Corporation. All rights reserved. Terms of Use | Trademarks | Privacy Statement | Site Feedback
Page view tracker