summaryrefslogtreecommitdiff
path: root/rsc/source/prj
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-06-27 14:04:39 +0200
committerStephan Bergmann <sbergman@redhat.com>2014-06-27 14:04:39 +0200
commitd75049f9785db101d6ecb043a4576652b71da2a7 (patch)
treed635d19941209e6d9ec8ef89f7d4ce668fc22983 /rsc/source/prj
parentc7d6541f5daa59d04accb30c727a83d936f02150 (diff)
rsc: fix how -isystem args are filtered out for the preproc
Change-Id: I7688f3d68be99362e79304bbac041424eee6347a
Diffstat (limited to 'rsc/source/prj')
-rw-r--r--rsc/source/prj/start.cxx17
1 files changed, 17 insertions, 0 deletions
diff --git a/rsc/source/prj/start.cxx b/rsc/source/prj/start.cxx
index 7c7cc3288dea..7c926f04d7a5 100644
--- a/rsc/source/prj/start.cxx
+++ b/rsc/source/prj/start.cxx
@@ -75,6 +75,23 @@ static bool CallPrePro( const OString& rInput,
bVerbose = true;
continue;
}
+ if (strcmp(static_cast<char *>(pCmdLine->GetEntry(i)), "-isystem") == 0)
+ {
+ // ignore "-isystem" and following arg
+ if (i < int(pCmdLine->GetCount()) - 1)
+ {
+ ++i;
+ }
+ continue;
+ }
+ if (strncmp(
+ static_cast<char *>(pCmdLine->GetEntry(i)), "-isystem",
+ strlen("-isystem"))
+ == 0)
+ {
+ // ignore args starting with "-isystem"
+ continue;
+ }
if ( !rsc_strnicmp( (char *)pCmdLine->GetEntry( i ), "-u", 2 ) ||
!rsc_strnicmp( (char *)pCmdLine->GetEntry( i ), "-i", 2 ) ||
!rsc_strnicmp( (char *)pCmdLine->GetEntry( i ), "-d", 2 ))