[Lldb-commits] [PATCH] D71482: [lldb/CMake] Rename LLDB_DISABLE_PYTHON to LLDB_ENABLE_PYTHON

Michał Górny via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Fri Dec 13 13:19:36 PST 2019


mgorny added inline comments.


================
Comment at: lldb/cmake/modules/LLDBConfig.cmake:43
+  else()
+    set(default_enable_python ON)
+  endif()
----------------
JDevlieghere wrote:
> mgorny wrote:
> > JDevlieghere wrote:
> > > mgorny wrote:
> > > > I know that the same thing is done above but… what's the point of setting it to `ON` again?
> > > It's just setting the default to the old value. If the value was set, we should honor it, both if it was `OFF` or `ON`.
> > But it's already set to `ON` a few lines above.
> Do you mean the `DEFINED`? That just checks if the variable exists, not its value. 
No, I mean you have:

```
set(default_enable_python ON)
#...
if (DEFINED LLDB_DISABLE_PYTHON)
  #...
  else()
    set(default_enable_python ON)
```

This is superfluous since the default is already `ON`.


Repository:
  rLLDB LLDB

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D71482/new/

https://reviews.llvm.org/D71482





More information about the lldb-commits mailing list