On Sat, 14 May 2022 at 16:20, Michael wrote:
>
> So I thought I'd install a simple little hex map generator. Mkhexgrid.
>
> Hasn't been updated in years, should be simple, right?
>
> Three versions of Python (37, 38, and 39)
> A full reinstall of X
>
> I mean, I can sort-of understand perl, one python, and ssl -- maybe it needed
> to rebuild something, and needed updated ssh fetching and rebuilding the
> compilation environment.
>
> But everything else? And three versions of python? And not just python 2 vs
> python 3.
For me python 2.7 sneaks in as a build dependency of ICU (that only
affects users of the latest macOS).
I see neither python 3.7 nor python 3.8 on the dependency list. Those
could be side-effects of something that you have installed earlier
which keeps depending on an older version of python. Or maybe you are
using a different OS version that has slightly different dependencies.
The following patch for ICU that replaces python 2.7 with 3.10 seems
to work for me:
--- a/devel/icu/Portfile
+++ b/devel/icu/Portfile
@@ -113,9 +113,9 @@ if {${subport} eq ${name} || ${subport} eq "${name}-lx"} {
test.args VERBOSE=1
if {${os.platform} eq "darwin" && (${os.major} < 11 || ${os.major} > 20)} {
- depends_build-append port:python27
- license_noconflict python27
- configure.python ${prefix}/bin/python2.7
+ depends_build-append port:python310
+ license_noconflict python310
+ configure.python ${prefix}/bin/python3.10
}
if {${build_arch} eq "ppc" || ${build_arch} eq "ppc64"} {
This patch should probably be applied anyway.
(Ken: is there some Tiger-like reason to keep python 2.7 as a build
dependency of ICU?)
You can check why you are getting weird dependency by running the
following command:
port rdeps mkhexgrid
Say, the reason why you need python 3.9 is because meson currently
declares a dependency on python 3.9 and that should definitely be
changed as well.
There's an open pull request for meson from 2 days ago.
> I'm assuming that somewhere, some graphical library was being used that could
> output to X as well as to ascii/curses. I just have no idea what.
Yes, mkhexgrid depends on gd2 which depends on X11 by default. Try to
run "port info gd2" or check
https://ports.macports.org/port/gd2/details/
You can avoid the need to install x11 by installing "sudo port install
gd2 -x11" before installing mkhexgrid.
All I can say is that the situation with multiple versions of
python/perl/etc. could and should be improved.
Whether or not the default variant to install gd2 with X11 support is
something that I'm not competent to judge.
"port rdeps <name>" will usually provide you enough information to
figure out why some dependency is there.
Sometimes it makes sense, sometimes it's something that could be improved.
Btw: you should usually update all your ports before installing a new port.
It could happen that by installing a new port, one of the libraries (a
dependency) will be upgraded, while another port that depends on that
same library won't be updated and may stop working.
Mojca