This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: macOS python install shares /usr/local with homebrew and can conflict
Type: Stage:
Components: Installation, macOS Versions: Python 3.10, Python 3.9
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: barry-scott, ned.deily, ronaldoussoren
Priority: normal Keywords:

Created on 2021-02-08 19:57 by barry-scott, last changed 2022-04-11 14:59 by admin.

Messages (6)
msg386649 - (view) Author: Barry Alan Scott (barry-scott) * Date: 2021-02-08 19:57
The popular homebrew system installs its binaries into /usr/local/bin.

The macOS python install also defaults to /usr/local/bin where it
puts symlinks to Python like:

% ls -l /usr/local/bin/python3.10
lrwxr-xr-x  1 root  73  8 Feb 19:45:50 2021 /usr/local/bin/python3.10@ -> ../../../Library/Frameworks/Python.framework/Versions/3.10/bin/python3.10

I understand that there are issues when homebrew installed code requires home brew's python but finds the version.

Having installation options to control both where the symlinks are installed or not having any symlinks installed would help.

This would make it easier to work with both and homebrew.

From researching it seems that homebrew cannot be configure to use another folder for its installation.
msg386652 - (view) Author: Ned Deily (ned.deily) * (Python committer) Date: 2021-02-08 20:14
Similar to Issue43167, there already is a mechanism to do that: on the "Installation Type" window of the macOS installer app sequeence, select "Customize" and then deselect the "UNIX command-line tools" package. Another option is to use the macOS "installer" command line tool instead and supply it with a choice changes file that deselects the package.

Noted in passing: apparently Homebrew has moved to using /opt/homebrew as its root for installs on Apple Silicon Macs rather than /usr/local.  And it is possible to use other prefixes as long as you are willing to let homebrew build the packages from source (admittedly not as convenient).
msg386655 - (view) Author: Barry Alan Scott (barry-scott) * Date: 2021-02-08 20:22
From "UNIX command-line tools" its not clear to me that that prevents
symlinks in /usr/local/bin. Maybe word it as "Add python to /usr/local/bin".

Is this documented anywhere?

I just looked at the download page and did not seen any linked pages that might explain the options.
msg386657 - (view) Author: Ned Deily (ned.deily) * (Python committer) Date: 2021-02-08 20:28
On the Installation Type -> Customize window in the installer, there is an explanation of a package when you can click on it. For Unix command-line tools package, the explanation (at the bottom of the window) is:

"This package installs the unix tools in /usr/local/bin for compatibility with older releases of Python. This package is not necessary to use Python."

This also appears in the output from the installer command-line tool.
msg386661 - (view) Author: Barry Alan Scott (barry-scott) * Date: 2021-02-08 20:39
I was wondering what the bottom text box was for.

The usual UX for check boxes is to toggle when the text of the control is clicked.

Because of that I avoid clicking on check boxes that I do not know if I want to change. Hence I did not get to see the description of the options.

The PKG installer is odd in not having that behaviour.

To check I remember this correctly I use Apple Mail Preferences
and click the text on a check box item.
msg386663 - (view) Author: Ned Deily (ned.deily) * (Python committer) Date: 2021-02-08 20:42
> I was wondering what the bottom text box was for. [...]

I suggest you take that UX issue up with Apple as we have no control over the macOS Installer app and it has worked that way for a long, long time :)

If the proposed solution in Issue43167 of adding some text to the installer Welcome or ReadMe windows is sufficient, we can close this as a duplicate thereof.
Date User Action Args
2022-04-11 14:59:41adminsetgithub: 87334
2021-02-08 20:42:33ned.deilysetnosy: + ronaldoussoren
messages: + msg386663
components: + macOS
2021-02-08 20:39:13barry-scottsetmessages: + msg386661
2021-02-08 20:28:29ned.deilysetmessages: + msg386657
2021-02-08 20:22:02barry-scottsetmessages: + msg386655
2021-02-08 20:14:12ned.deilysetnosy: + ned.deily
messages: + msg386652
2021-02-08 19:57:04barry-scottcreate