As noted in this thread: http://gcc.gnu.org/ml/gcc/2005-01/msg01087.html there is no way to make use of a precompiled header without -I- in a VPATH build in case the header source and the C or C++ source file including it reside in the same source directory.
Please consider adding a flag (-icwd?) to the preprocessor which will cause the current directory to be search for pch before the source directory. Or consider to change the default pch search order. -- Summary: deprecation of -I- makes precompiled headers less usable Product: gcc Version: 4.0.0 Status: UNCONFIRMED Severity: enhancement Priority: P3 Component: pch AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: Ralf dot Wildenhues at gmx dot de CC: gcc-bugs at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19541