data: Fixes and features for loading Coati into Coati

This change facilitates loading Coati into Coati:
* removed error logs for TokenComponent setting
* fixed edge checks regarding template stuff
* separated CommonSettings to be inherited by Project- and ApplicationSettings for common settings
* pluralized SourcePaths setting in xml to allow for loading multiple directories and single files
* added CompilerFlags section to settings
* passing Compiler arguments to Parser via struct Parser::Arguments
* setting -isystem for all header search paths to avoid distinction between "" and <> headers
* parsing all headers from the SourcePaths, even the ones that are not included
* fixed parsing time measurement and display
* added utility.h file for general utility functionality
This commit is contained in:
Eberhard Graether
2015-03-16 10:07:57 +01:00
parent 0e0553c90b
commit 03cf9eeb5f
44 changed files with 442 additions and 260 deletions
+9 -2
View File
@@ -59,9 +59,10 @@ std::vector<FileInfo> FileSystem::getFileInfosFromDirectoryPaths(
std::vector<FileInfo> files;
for (const std::string& directoryPath: directoryPaths)
{
if (boost::filesystem::is_directory(directoryPath))
boost::filesystem::path path(directoryPath);
if (boost::filesystem::is_directory(path))
{
boost::filesystem::recursive_directory_iterator it(directoryPath);
boost::filesystem::recursive_directory_iterator it(path);
boost::filesystem::recursive_directory_iterator endit;
while (it != endit)
{
@@ -74,6 +75,12 @@ std::vector<FileInfo> FileSystem::getFileInfosFromDirectoryPaths(
++it;
}
}
else if (boost::filesystem::exists(path) && hasExtension(path.string(), fileExtensions))
{
std::time_t t = boost::filesystem::last_write_time(path);
boost::posix_time::ptime lastWriteTime = boost::posix_time::from_time_t(t);
files.push_back(FileInfo(path, lastWriteTime));
}
}
return files;
}