Opened 3 years ago
Last modified 3 years ago
#64291 new defect
gettext libraries are not automatically installed universal when required
Reported by: | ryandesign (Ryan Carsten Schmidt) | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.7.1 |
Keywords: | universal | Cc: | mascguy (Christopher Nielsen), cooljeanius (Eric Gallager) |
Port: | gettext |
Description
Per #64288, libintl.dylib was not installed universal when a port was installed that required it (MacVim, which only supports x86_64, on an arm64 machine). I believe this happened because gettext was recently split into several subports. The libraries are now in the gettext-runtime port. But MacVim still declares a dependency only on the parent gettext port, which itself declares installs_libs no
. While this is true, it causes MacPorts not to check the architectures of gettext or apparently any of its dependencies such as gettext-runtime.
The intended solution is for all ports that use gettext to declare correct dependencies on exactly which components they use. See https://github.com/macports/macports-ports/pull/7399#issuecomment-650851785:
Additionally ports that depend on gettext should change their dependencies. So a port that previously used:
depends_lib port:gettextwould change it to:
depends_build port:gettext depends_lib port:gettext-runtimeMaking this change in the almost 500 ports that use gettext isn't going to be fun.
I originally said that license_noconflict gettext
would need to be set in each port too, but then suggested that we might be able to remove that requirement if we split the ports further and added installs_libs no
to gettext, both of which were subsequently done. When I made that suggestion I was only thinking of the distributability implications of installs_libs no
; I hadn't considered that it would turn off the architecture checks.
Maybe the best workaround for now is to comment out installs_libs no
in gettext. Does anyone agree or have a better solution?
Or should we make a mad replacement of all gettext dependencies in all ports? Technically that should be accompanied by a revbump for each port which will take a terribly long time to build. Probably best if we clearly communicate the need to change the gettext dependency in each port on the mailing list and give maintainers some time to make the change naturally as each port is updated. We can do a batch fix of remaining ports at a later time.
Change History (5)
comment:1 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)
comment:2 Changed 3 years ago by mascguy (Christopher Nielsen)
Cc: | mascguy added |
---|
comment:3 Changed 3 years ago by cooljeanius (Eric Gallager)
Cc: | cooljeanius added |
---|
comment:4 Changed 3 years ago by jmroot (Joshua Root)
It looks like the gettext
port is only needed when building the configure script, i.e. running auto(re)conf, for at least some ports. The python* ports seem fine with just gettext-runtime
for example.
comment:5 Changed 3 years ago by jmroot (Joshua Root)
Replying to ryandesign:
Technically that should be accompanied by a revbump for each port which will take a terribly long time to build.
Updating the dependencies without a rev bump will fix this issue and will do very minimal harm in this case.
Replying to ryandesign:
https://lists.macports.org/pipermail/macports-dev/2021-December/044041.html