2016-07-07: Recompile when vc90.pdb is not the PDB file used when creating this precompiled header

Source: Internet
Author: User

When you use VS2008 to include multiple projects in a solution, when you set the intermediate directory for multiple projects to the same directory, the "recompile vc90.pdb is not the PDB file that was used when the precompiled header was created when you compiled the incremental compilation, re-create the precompiled header problem," This causes the entire solution to be fully regenerated every time.

Get the following information on MSDN:

You could receive a "PRJ0008" or "C2471" or "C1083" or "D8022" or "LNK1103" or similar error message when you try to Bui LD a solution in Visual C + +

Symptoms:

    • D8022:cannot Open ' rsp00000215921192.rsp '
    • Prj0008:could Not delete file ' Vc90.idb '.
    • C1083:cannot Open Program database file ' vc90.pdb '
    • C2471:cannot Update program database ' vc90.pdb '
    • lnk1103:debugging information corrupt.

Cause:

This problem occurs if all of the following conditions is true:

    1. You had a solution with more than one project in it.
    2. Both or more of the projects is not dependent on each other.
    3. You have parallel builds enabled. (Tools-Options:projects and Solutions, Build and Run: "Maximum number of parallel project builds" is set to a value Greater than 1)
    4. You is building on a system with multiple CPUs (cores).
    5. Both or more of the Non-dependent projects is configured to use the same intermediate and/or Output directory.
    6. A specific race condition in Mspdbsrv.exe remains uncorrected.

Resolution:

To resolve the problem does one or more of the following:

    • Reconfigure the Non-dependent projects to specify a intermediate and Output directory that's different from one another, e.g. Output directory = "$ (solutiondir) $ (ProjectName) \$ (configurationname)", Intermediate directory = "$ (OutDir)".
    • Adjust your solution's Project Dependencies (Project---project dependencies ...) So, each are dependent on another.
    • Disable parallel builds.
    • Add the "/onecpu" boot option to your boot. ini file.
    • Change your BIOS settings to enable/use only one CPU.
    • File a problem report with Microsoft Technical support and keep bugging the ___ out of them until they eventually fix MSP Dbsrv.

Status:

The problem is a combination of both a user project configuration error as well as a race condition in Microsoft ' s "Mspdbs Rv.exe "utility that does no properly handle more than one thread calling it in the same time for the same file resulting In the file ' s HANDLE being left open.

Additionally Visual Studio itself and/or its build system (VCBUILD and/or MSBUILD) (or all three!) should be made smart en Ough to detect and alert the user's such user errors so, corrective action can be taken.

This problem have been around for a loooooong time.

applies To:

    • Microsoft Visual C + + 2005
    • Microsoft Visual C + + 2008
    • Others?

respectfully submitted:

"Fish" (David B. Trout)
[email protected]

P.S:

You ' re welcome. :)

Fish (David B. Trout)

Finally, the above problem is resolved successfully by reconfiguring the project's intermediate output directory.

Legacy issues: When each project is built, Vc90.pdb and Vc90.idb files are generated in the corresponding intermediate directories, and if the intermediate directories of all the projects are configured in the same directory, the PDB files generated later will overwrite the PDB files generated in the project sequence, resulting in a PDB file that may no longer be the file generated by its corresponding project when part of the source code is modified. , so the entire solution needs to be rebuilt. Purely speculative, subsequent validation of the conclusion can be used in a way that builds the project incrementally.

https://social.msdn.microsoft.com/Forums/vstudio/en-US/25731965-bf98-4bb7-97b7-6d1a0b21b733/ Cant-open-vc90pdb-in-visual-c-2008-rebuild?forum=vcgeneral

2016-07-07: Recompile when vc90.pdb is not the PDB file used when creating this precompiled header

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.