From e9da4879384c15da84e26d137302ae1ccc30f86a Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Wed, 1 Aug 2012 20:52:50 +0200 Subject: filter-showIncludes: filter out system headers A blacklist based approach doesn't seem easy since there are various different SDKs, MFC, ATL and whatnot each potentially with an own include path; so simply whitelist the known source and build dirs. Change-Id: I93b27bd0ffbd57237da2d23afa95dea7c0785774 --- solenv/gbuild/filter-showIncludes.pl | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'solenv') diff --git a/solenv/gbuild/filter-showIncludes.pl b/solenv/gbuild/filter-showIncludes.pl index d7082a29c083..1ed3679b14e8 100755 --- a/solenv/gbuild/filter-showIncludes.pl +++ b/solenv/gbuild/filter-showIncludes.pl @@ -43,6 +43,11 @@ while ( ) { chomp; s/\\/\//g; + + # skip system headers, i.e. everything not under source or build dirs + if ( /$ENV{'SRCDIR'}|$ENV{'OUTDIR'}|$ENV{'WORKDIR'}/ ) + { + # X: -> /cygdrive/x/ s/^(.):/\/cygdrive\/\l\1/; @@ -52,6 +57,7 @@ while ( ) { $seen{$_} = 1; print $OUT " \\\n $_"; } + } } else { # skip the first line, it always just duplicates what is being -- cgit