Patch by David Forsythe to build lldb on FreeBSD!
I did not take the patch for ClangExpressionParser.cpp since there was a
recent change by Peter for the same line. Feel free to disagree. :-)
Reference:
----------------------------------------------------------------------
r136580 | pcc | 2011-07-30 15:42:24 -0700 (Sat, 30 Jul 2011) | 3 lines
Add reloc arg to standard JIT createJIT()
Fixes non-__APPLE__ build. Patch by Matt Johnson!
----------------------------------------------------------------------
Also, I ignore the part of the patch to remove the RegisterContextDarwin*.h/.cpp.
git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@136720 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/lldb.cpp b/source/lldb.cpp
index ec3495a..b6610b7 100644
--- a/source/lldb.cpp
+++ b/source/lldb.cpp
@@ -56,6 +56,10 @@
#include "Plugins/Process/Linux/ProcessLinux.h"
#endif
+#if defined (__FreeBSD__)
+#include "Plugins/Platform/FreeBSD/PlatformFreeBSD.h"
+#endif
+
#include "Plugins/Platform/gdb-server/PlatformRemoteGDBServer.h"
#include "Plugins/DynamicLoader/Static/DynamicLoaderStatic.h"
@@ -116,6 +120,9 @@
ProcessLinux::Initialize();
DynamicLoaderLinuxDYLD::Initialize();
#endif
+#if defined (__FreeBSD__)
+ PlatformFreeBSD::Initialize();
+#endif
//----------------------------------------------------------------------
// Platform agnostic plugins
//----------------------------------------------------------------------
@@ -181,6 +188,10 @@
ProcessLinux::Terminate();
DynamicLoaderLinuxDYLD::Terminate();
#endif
+
+#if defined (__FreeBSD__)
+ PlatformFreeBSD::Terminate();
+#endif
DynamicLoaderStatic::Terminate();