[Lldb-commits] [PATCH] D26249: [unittests] Avoid the dependency on private LLVM headers outside MSVC
Michał Górny via lldb-commits
lldb-commits at lists.llvm.org
Wed Nov 2 09:04:52 PDT 2016
mgorny created this revision.
mgorny added reviewers: zturner, labath, k8stone.
mgorny added a subscriber: lldb-commits.
Avoid including private LLVM config.h when not using MSVC. The file is
used only to determine whether DIA SDK is available, and this can be
true only when using MSVC. Therefore, short-circuit it to false on
non-MSVC platforms to avoid the #include and fix standalone builds
on those platforms.
https://reviews.llvm.org/D26249
Files:
unittests/SymbolFile/PDB/SymbolFilePDBTests.cpp
Index: unittests/SymbolFile/PDB/SymbolFilePDBTests.cpp
===================================================================
--- unittests/SymbolFile/PDB/SymbolFilePDBTests.cpp
+++ unittests/SymbolFile/PDB/SymbolFilePDBTests.cpp
@@ -10,7 +10,11 @@
#include "gtest/gtest.h"
#include "llvm/ADT/STLExtras.h"
-#include "llvm/Config/config.h"
+#ifdef _MSC_VER // DIA SDK is available only when using MSVC
+# include "llvm/Config/config.h"
+#else
+# define HAVE_DIA_SDK 0
+#endif
#include "llvm/DebugInfo/PDB/PDBSymbolData.h"
#include "llvm/DebugInfo/PDB/PDBSymbolExe.h"
#include "llvm/Support/FileSystem.h"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D26249.76715.patch
Type: text/x-patch
Size: 611 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20161102/2ded71ac/attachment.bin>
More information about the lldb-commits
mailing list