summaryrefslogtreecommitdiffstats
path: root/Source/cmQtAutoGenInitializer.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmQtAutoGenInitializer.cxx')
-rw-r--r--Source/cmQtAutoGenInitializer.cxx13
1 files changed, 12 insertions, 1 deletions
diff --git a/Source/cmQtAutoGenInitializer.cxx b/Source/cmQtAutoGenInitializer.cxx
index deb2c04..544e1ef 100644
--- a/Source/cmQtAutoGenInitializer.cxx
+++ b/Source/cmQtAutoGenInitializer.cxx
@@ -587,7 +587,18 @@ bool cmQtAutoGenInitializer::InitCustomTargets()
addBefore = true;
}
} else {
- addBefore = true;
+ switch (this->Makefile->GetPolicyStatus(cmPolicies::CMP0151)) {
+ case cmPolicies::WARN:
+ case cmPolicies::OLD:
+ addBefore = true;
+ break;
+ case cmPolicies::REQUIRED_IF_USED:
+ case cmPolicies::REQUIRED_ALWAYS:
+ case cmPolicies::NEW:
+ this->GenTarget->AddSystemIncludeDirectory(this->Dir.IncludeGenExp,
+ "CXX");
+ break;
+ }
}
this->GenTarget->AddIncludeDirectory(this->Dir.IncludeGenExp, addBefore);
}