VC++2005编译错误fatal error C1902解决

最近几天中了病毒,老是杀不干净。并且好像感染了VS环境。

每当编译C++程序的时候就

fatal error C1902: Program database manager mismatch; please check your installation。搜遍网络最后在微软网站搜到:

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=10577&SiteID=1

RESOLUTION

A supported hotfix is now available from Microsoft, but it is only intended to correct the problem that is described in this article. Only apply it to systems that are experiencing this specific problem. This hotfix may receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next Visual Studio 2005 service pack that contains this hotfix.
To resolve this problem immediately, contact Microsoft Product Support Services to obtain the hotfix. For a complete list of Microsoft Product Support Services telephone numbers and information about support costs, visit the following Microsoft Web site:

http://support.microsoft.com/contactus/?ws=support (http://support.microsoft.com/contactus/?ws=support)Note In special cases, charges that are ordinarily incurred for support calls may be canceled if a Microsoft Support Professional determines that a specific update will resolve your problem. The usual support costs will apply to additional support questions and issues that do not qualify for the specific update in question.

 

问题是一个高手自己解决的,具体道理我也没搞清楚,解决了就没深究,记录下方法,防止下次再出问题。

Here are steps how I got it and solve:
1. I like to compile some sources from the command prompt, so I added to the PATH environment variable - "C:\Program Files\Microsoft Visual Studio 8\VC\Bin". After that I had to copy some files from "C:Program Files\Microsoft Visual Studio 8\Common7\IDE" to get cl.exe working (one of files was mspdb80.dll).
2. Some time later I tryed to compile a project from MSDev and got C1902 error.
3. With MSDN search I got to this place to see Jonathan Caves's helpful message about mspdbsrv.exe.
4. I just copied that EXE to VC\Bin and everithing becomes Ok.
5. Now I can compile anything .

原文地址:https://www.cnblogs.com/flyingfish/p/677605.html