Our dev environment makes heavy use of directories with locally modified headers that should be seen by the compiler instead of the \"committed\" \"repository\" versions.
AFAIK, there is no other way to desactivate the behaviour you are complaining about other than using the form #include <foo.h>
instead of #include "foo.h"
in your code.
ISTR, but I've failed to find a reference, that the rationale for deprecating -I-
without providing another mechanism for that aspect is that libraries commonly use the form #include "foo.h"
to ensure they get their own internal header file foo.h
and the use of -I-
broke them in some cases if someone else happened to have a file similarly named earlier on the search path.