Update scaninc to include missing .include files in assembler files

This commit is contained in:
Marcus Huderle
2019-08-28 16:52:33 -05:00
committed by huderlem
parent b420b98d63
commit 1a2b430646
4 changed files with 20 additions and 7 deletions

View File

@@ -97,19 +97,26 @@ int main(int argc, char **argv)
}
for (auto include : file.GetIncludes())
{
bool exists = false;
std::string path("");
for (auto includeDir : includeDirs)
{
std::string path(includeDir + include);
path = includeDir + include;
if (CanOpenFile(path))
{
bool inserted = dependencies.insert(path).second;
if (inserted)
{
filesToProcess.push(path);
}
exists = true;
break;
}
}
if (!exists && file.FileType() == SourceFileType::Asm)
{
path = include;
}
bool inserted = dependencies.insert(path).second;
if (inserted && exists)
{
filesToProcess.push(path);
}
}
includeDirs.pop_back();
}