This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug preprocessor/26857] New: Warning for absolute or dotted header paths
- From: "mbland at google dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 24 Mar 2006 23:33:40 -0000
- Subject: [Bug preprocessor/26857] New: Warning for absolute or dotted header paths
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
Given that some build systems try to encapsulate system headers separately from
those found in /usr/include, primarily through careful arrangement of -I flags,
it would be helpful if there was a warning flag, let's call it
-Wstrict-header-path for now, which would signal when a source file tries to do
the following:
#include "/usr/include/sys/stat.h"
#include "../../../sys/stat.h"
Ian Lance Taylor has indicated to me that this could be done as a check on
fname in do_include_common in libcpp/directives.c. I would be willing to
attempt a patch myself if this enhancement is accepted.
--
Summary: Warning for absolute or dotted header paths
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: enhancement
Priority: P3
Component: preprocessor
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: mbland at google dot com
GCC build triplet: N/A
GCC host triplet: N/A
GCC target triplet: N/A
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26857