[Lldb-commits] [PATCH] D74727: Allow customized relative PYTHONHOME

Jonas Devlieghere via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Tue Feb 18 20:36:09 PST 2020


JDevlieghere added a comment.

In D74727#1881055 <https://reviews.llvm.org/D74727#1881055>, @hhb wrote:

> > Can we maybe rename it to something like that?
>
> LLDB_RELOCATABLE_PYTHON is misleading. I'd be happy to rename it. But that may break people who already set this flag.
>
> Is there a standard procedure to do this? Maybe add the new one and remove the old one a year later? Or maybe fail when the old is set. So that at least people know how to fix?


We've made breaking changes like that in the past. This might even be a good thing when we're changing behavior.

> 
> 
>> Or maybe even just a single LLDB_PYTHON_HOME variable, with the empty value meaning we use the default python mechanism (PYTHONHOME env var, or the baked-in python default)?
> 
> To do that, we have to make LLDB_PYTHON_HOME default to PYTHON_HOME for Windows. And if windows users want to make it "relocatable", they should set LLDB_PYTHON_HOME back to empty. That's also somehow weird...

Another alternative would be to default to "Auto", like we do with the optional dependencies, in which case it would default to PYTHON_HOME. Empty would always signal a relocatable python.

>> The other thing which bugs me is that the relative python path chosen here will likely only be correct once lldb is installed. Will it be possible to run lldb (and its test suite) configured in this way directly from the build tree? I don't know if there's anything we can or should do about that, but this situation seems less than ideal...
> 
> If someone uses relative python, that mean they should be responsible to put Python at the right place. No matter it is build tree or install tree. Or in other words, the install tree won't work by default either. People still need to put a symlink to python at the right place.




Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D74727





More information about the lldb-commits mailing list