aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2013-05-20 23:17:08 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2013-05-20 23:17:08 +0000
commitfcf713ac24d40a8e57b212579e13d227d1240145 (patch)
tree8fa3789eac2d66ab0603c285d9cfa82e3f4578c9 /clang/lib/Frontend/CompilerInvocation.cpp
parent68ae91cf83adf97cb6e922cff69b8169b4a67db7 (diff)
downloadllvm-fcf713ac24d40a8e57b212579e13d227d1240145.zip
llvm-fcf713ac24d40a8e57b212579e13d227d1240145.tar.gz
llvm-fcf713ac24d40a8e57b212579e13d227d1240145.tar.bz2
Move two Darwin-specific hacks into #ifdef __APPLE__. These were stat'ing
nonexistent Darwin-specific files on every module build. llvm-svn: 182331
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
-rw-r--r--clang/lib/Frontend/CompilerInvocation.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/lib/Frontend/CompilerInvocation.cpp b/clang/lib/Frontend/CompilerInvocation.cpp
index 6af3663..3d82d7a 100644
--- a/clang/lib/Frontend/CompilerInvocation.cpp
+++ b/clang/lib/Frontend/CompilerInvocation.cpp
@@ -1690,6 +1690,7 @@ std::string CompilerInvocation::getModuleHash() const {
hsOpts.UseStandardCXXIncludes,
hsOpts.UseLibcxx);
+#ifdef __APPLE__
// Darwin-specific hack: if we have a sysroot, use the contents and
// modification time of
// $sysroot/System/Library/CoreServices/SystemVersion.plist
@@ -1710,6 +1711,7 @@ std::string CompilerInvocation::getModuleHash() const {
code = hash_combine(code, statBuf.st_mtime);
}
}
+#endif
return llvm::APInt(64, code).toString(36, /*Signed=*/false);
}