Article ID: 194615 - Last Review: September 23, 2005 - Revision: 3.1 FIX: A project deletes a precompiled header that was created by another projectThis article was previously published under Q194615 On This PageSYMPTOMS
If one project uses a precompiled header (using compiler option /Yu) that
was created by another project, then the precompiled header is deleted
when you perform a Clean or Rebuild-All command in Developer Studio.
RESOLUTION
In the workarounds that follow, a YC project refers to the project that
creates the precompiled header (PCH); a YU project refers to a project
that uses, but does not create, the precompiled header.
Option 1Use a custom build step to create the PCH file. This does not impact the YU projects.In this case you can modify Project Settings for the Stdafx.cpp file so that it is built with custom build rules rather than the standard method for building the PCH file. To do this from the YC project:
Option 2Use an environment variable to set the PCH switch in the YU projects. This does not impact the YC project(s).
STATUSMicrosoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
This bug was corrected in Visual Studio 6.0 Service Pack 3.
MORE INFORMATIONSteps to reproduce the behavior
fatal error C1083: Cannot open precompiled header file: 'filename': No
such file or directory
REFERENCES
For more information about Visual Studio service packs, click the following article numbers to view the articles in the Microsoft Knowledge Base:
194022
(http://support.microsoft.com/kb/194022/
)
Visual Studio 6.0 service packs, what, where, why
194295
(http://support.microsoft.com/kb/194295/
)
How to tell that a Visual Studio service pack is installed
| Article Translations
|
Back to the top
