This article applies to the Windows SDK for Windows Server 2008 and .NET Framework 3.5. Problem: If your usage scenario matches the one listed below, you will be unable to build in the Windows SDK command line build environment. If you type cl.exe in the SDK command window and press Enter, you will see this error:
This application has failed to start because mspdb80.dll was not found. Re-installing the application may fix this problem.
Computer setup required to repro issue:
1. Windows XP on x86 machine (which has version 5.1.2600.2180 of REG.exe)
2. Visual Studio 2005 installed, but Visual Studio 2008 is NOT installed
Cause: When the SDK build environment window is launched, the SDK file SetEnv.cmd launches Reg.exe. Reg.exe generates standard output when a valid KeyPath is specified and also generates error output when invalid Value is specified. In this scenario, the KeyPath is valid but the value doesn’t exist:
REG QUERY "%VSRegKeyPath%" /v 9.0
! REG.EXE VERSION 3.0
Error: The system was unable to find the specified registry key or value
The second call to REG in setenv.cmd is grabbing the output from the call above and setting VSRoot=VERSION 3.0, which breaks the Windows SDK build environment. (Other versions of REG.EXE will immediately throw an error when an invalid KeyPath/Value combination is specified.)
Workaround: follow these instructions to manually edit SetEnv.cmd to remove the second call to REG:
FOR /F "tokens=2* delims= " %%A IN ('REG QUERY "%VSRegKeyPath%" /v 9.0') DO SET VSRoot=%%B
Either comment out using the REM command (like this):
REM FOR /F "tokens=2* delims= " %%A IN ('REG QUERY "%VSRegKeyPath%" /v 9.0') DO SET VSRoot=%%B
OR delete the line completely.
||Karin Meier||Windows SDK PM||Build Environment.Samples.Community||
The MSDN Windows SDK Developer Center is the place to find resources and links to Windows SDK products, release notes, technical articles, and more.