BUG: fix compile flags for a single file
This commit is contained in:
parent
43a4436551
commit
3851ac2416
|
@ -2371,17 +2371,19 @@ void cmLocalUnixMakefileGenerator::OutputSourceObjectBuildRules(std::ostream& fo
|
||||||
std::string shortNameWithExt = shortName +
|
std::string shortNameWithExt = shortName +
|
||||||
(*source)->GetSourceExtension();
|
(*source)->GetSourceExtension();
|
||||||
// Only output a rule for each .o once.
|
// Only output a rule for each .o once.
|
||||||
|
std::string compileFlags = exportsDef;
|
||||||
|
compileFlags += " ";
|
||||||
if(rules.find(shortNameWithExt) == rules.end())
|
if(rules.find(shortNameWithExt) == rules.end())
|
||||||
{
|
{
|
||||||
|
|
||||||
if((*source)->GetProperty("COMPILE_FLAGS"))
|
if((*source)->GetProperty("COMPILE_FLAGS"))
|
||||||
{
|
{
|
||||||
exportsDef += (*source)->GetProperty("COMPILE_FLAGS");
|
compileFlags += (*source)->GetProperty("COMPILE_FLAGS");
|
||||||
exportsDef += " ";
|
|
||||||
}
|
}
|
||||||
this->OutputBuildObjectFromSource(fout,
|
this->OutputBuildObjectFromSource(fout,
|
||||||
shortName.c_str(),
|
shortName.c_str(),
|
||||||
*(*source),
|
*(*source),
|
||||||
exportsDef.c_str(),
|
compileFlags.c_str(),
|
||||||
shared);
|
shared);
|
||||||
rules.insert(shortNameWithExt);
|
rules.insert(shortNameWithExt);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue