[lldb-dev] Restoring build with LLDB_DISABLE_PYTHON

Ed Maste emaste at freebsd.org
Tue Jul 2 10:18:14 PDT 2013


I wanted to try out a Python-less lldb, and found one build error.  Is
it fine to just remove the ePathTypePythonDir case in GetLLDBPath for
LLDB_DISABLE_PYTHON, as below?

Incidentally, I'm curious about how widely used LLDB_DISABLE_PYTHON
is.  For FreeBSD we'd eventually like to bring lldb into the base
system, so having it be usable without Python is very interesting to
us.

diff --git a/source/Host/common/Host.cpp b/source/Host/common/Host.cpp
index bbe87ba..ba8367b 100644
--- a/source/Host/common/Host.cpp
+++ b/source/Host/common/Host.cpp
@@ -1011,6 +1011,7 @@ Host::GetLLDBPath (PathType path_type, FileSpec
&file_spec)
         }
         break;

+#ifndef LLDB_DISABLE_PYTHON
     case ePathTypePythonDir:
         {
             static ConstString g_lldb_python_dir;
@@ -1053,7 +1054,8 @@ Host::GetLLDBPath (PathType path_type, FileSpec
&file_spec)
             return file_spec.GetDirectory();
         }
         break;
-
+#endif
+
     case ePathTypeLLDBSystemPlugins:    // System plug-ins directory
         {
 #if defined (__APPLE__)



More information about the lldb-dev mailing list