You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
unix: make CPython compile on Catalina / disable Tcl/Tk
I couldn't get things to build in their current state on Catalina for
several reasons.
First, it looks like a lot of developer files are no longer in /usr and our
custom Clang can't pick them without some nudging. So, we had to pass
some extra CFLAGS when building.
A bigger problem is how to deal with Tcl/Tk/Tix.
The X11.h file in Catalina's SDK appears to reference a missing xproto.h.
I no longer have a copy of older macOS, so I'm not sure what changed here.
But I couldn't get Tcl/Tk to work with the X11.h in the macOS SDK.
I attempted to install XQuartz and compile with its headers. But we ran
into mismatch issues and I didn't feel like going down the rabbit hole.
I decided to give up and disable the custom Tcl/Tk/Tix packages on macOS
and to instead use the Tcl and Tk frameworks that are part of the macOS
SDK. These have been part of the SDK since at least 10.3. And Tcl 8.5 has
been present since 10.6. This will add a run-time dependency on the Tcl/Tk
frameworks. But I think that's OK. We already rely on some frameworks at
runtime. Creating fully static binaries on macOS is effectively impossible
these days. Plus Tcl/Tk/Tix features in Python are not used very much. So
I think it is acceptable to cut corners.
One casuality is Tix. We are no longer building it. We potentially could
build it against the macOS Tcl/Tk frameworks. But the tix module has been
deprecated since Python 3.6 and we only support Python 3.7. So I think it
is acceptable to put on the chopping block. FWIW Homebrew's Python doesn't
include Tix support either. I suspect it won't be missed.
Anyway, with this commit I am able to build again on Catalina.
0 commit comments