Python dependencies (was: MacPorts 2.9.0-beta1 now available for testing)

grey artkiver at gmail.com
Tue Jan 2 19:51:20 UTC 2024


Thanks for the explanation! I had done some dependency walks with some
pointers from neverpanic, but hadn't been able to make heads or tails
of why some of the things were the way they were.

On Tue, Jan 2, 2024 at 8:20 AM Joshua Root <jmr at macports.org> wrote:
>
> On 2/1/2024 11:24, grey wrote:
> > Installing llvm-17 goes OK, but:
> >
> > Why are python310 and python311 considered dependencies if I already
> > have python312 installed and selected? Pretty sure that some other BSD
> > ports systems I use do not seem to regress like MacPorts in similar
> > dependency walks, the fact that my MacPorts now has three versions of
> > Python installed seems a bit wonky to me.
>
> Ports usually depend on a specific version of python so the build
> environment will be consistent. The MacPorts default python version only
> just changed from 3.11 to 3.12, so some ports just haven't been switched
> over yet. Others aren't compatible with the newer version. And then...
> there's this specific example.
>
> Python 3.11 and later need to be built with a C11 compiler. On older
> systems, Xcode doesn't ship one, so the C11 compiler that gets used is
> one of the clang-* ports. The dependency on python311 in llvm-17
> shouldn't be hard to switch over to python312, but python312 will also
> have to be configured to avoid using the clang versions that use it.
>
> The python310 dependency comes from libpsl, which is an indirect
> dependency of cmake, which is needed to build all recent llvm versions.
> This is trickier because all of the C11 capable clang versions need
> cmake. We could possibly only hold back the python used by libpsl on
> platforms without C11 support in Xcode, though that would mean a less
> tested configuration for some users. Or it could probably be solved with
> more use of *-bootstrap ports.
>
> - Josh


More information about the macports-dev mailing list