The code for determining which Python version is bundled with which
version of Anaconda has not been updated in a while. I have added 3.10
and 3.11, both of which were used in bundles this year.
I also updated the URL for the source of this data, the Anaconda release
notes, because it has moved.
XCode Command Line Tools 15.0 was recently released, and it contains a
broken version of ncurses 6.0. Some uses of Python's `curses` module
will segfault when compiled with it. The solution is to switch to using
the version of ncurses from Homebrew, which is currently 6.4. Support
for ncurses 6 was added to Python 3.7 and was backported to 3.6 and 2.7,
so this change should not break any recently supported Python versions.
Tested with Python 3.12, 3.11, and 2.7, and all tests in
the `test.test_curses` module pass without issue.
See https://github.com/python/cpython/issues/109617 and
https://github.com/python/cpython/issues/69906 for more information.
It seems that pyenv cannot install 2.7.18 on Mac M1 (Apple ARM).
openssl 1.0.2 does not have ARM support. M1 support was added in 1.1.1i according to
https://www.openssl.org/news/cl111.txt
All include directories should go into CPPFLAGS.
XCode SDK was being added to CFLAGS instead
which caused old Tcl/Tk in the SDK to override a newer one in Homebrew.
According to the POSIX spec, an unescaped backslash not followed by
an escapable character is undefined behavior,
and it has become an error in GNU grep 3.8 (2022-09-02).
The -s flag assures that nothing can be installed to user site-packages
but doesn't keep ensurepip from looking there for Pip.
If Pip is installed in the user site-packages directory, pip won't be installed
for the newly built python -- and its shim won't be created.
-I makes the build install Pip in any case.
The user site-packages installation will override it --
but we'll have the shim at least.