Files
Sourcetrail/src/lib/utility/utilityCxx.cpp
T
Eberhard Graether f11be042a6 build: ship clang compiler header within Sourcetrail package on macOS and Linux
* replace path to local compiler headers with packaged ones in include path detection
* added app settings migration to replace local compiler header path with path to packaged headers
2018-06-18 14:08:50 +02:00

29 lines
647 B
C++

#include "utility/utilityCxx.h"
#include "utility/ResourcePaths.h"
#include "utility/utilityApp.h"
namespace utility
{
std::vector<FilePath> replaceOrAddCxxCompilerHeaderPath(const std::vector<FilePath>& headerSearchPaths)
{
if (utility::getOsType() == OS_WINDOWS)
{
return headerSearchPaths;
}
std::vector<FilePath> newHeaderSearchPaths;
for (const FilePath& path : headerSearchPaths)
{
if (!path.getConcatenated(L"/stdarg.h").exists())
{
newHeaderSearchPaths.push_back(path);
}
}
newHeaderSearchPaths.push_back(ResourcePaths::getCxxCompilerHeaderPath().getCanonical());
return newHeaderSearchPaths;
}
}