Coexistence of Homebrew and pyenv on MacOSX Yosemite Coexistence of Homebrew and pyenv on MacOSX Yosemite python-3.x python-3.x

Coexistence of Homebrew and pyenv on MacOSX Yosemite


I'll try to answer each of your questions.

1 Does brew "frown" upon using pyenv's Python rather than brew's?

In short, yes. They lay out the whole story here, and in short you're on your own to manage issue that come up.

2 Will brew Python and pyenv Python conflict?

No. As Tim Smith says in another answer, "nothing bad should happen if you do". Use your PATH to manage which Python you (or an application) sees (and this is what pyenv does).

3 Packages with Python dependency satisfied by brew Python working with "oustide" Python from pyenv

As Tim said, this shouldn't be a problem.

4 Use symlinks so that we only use pyenv Python?

I think you're referring to this post, and it's a fun idea, but likely perilous for maintenance. Fwiw, I'm doing this now.I lay out how to do it here.


A clarification: Homebrew uses system Python whenever it doesn't make a difference exactly which Python 2.7 it uses (which is pretty common). If you build something --with-python, that will use the first Python in PATH, if that Python is Python 2.7. Otherwise, Homebrew will install and use Homebrew python.

I would not expect that you will find it necessary to install Homebrew's python and python3 but nothing bad should happen if you do. Note that if you use pip or easy_install to install a package that installs scripts (like ipython), those scripts are written so that the package will always be invoked with the python against which it was installed. (You can always get around this behavior by running packages like python -m ipython.) Otherwise, you can control which python you're using just by setting $PATH.

Building boost-python against whatever python 3.4 will work with any other python 3.4. It will probably not work with python 3.5. (This used to be more complicated, but it isn't, anymore!)

Symlinking your pyenv pythons into /usr/local shouldn't hurt but doesn't do anything except put them in $PATH; it won't help Homebrew find them otherwise.