[MacPorts] #63455: mysql8 @8.0.26_0: build fails under trace mode due to too-old libtool
MacPorts
noreply at macports.org
Sat Jan 1 01:23:12 UTC 2022
#63455: mysql8 @8.0.26_0: build fails under trace mode due to too-old libtool
---------------------------+-------------------------
Reporter: chrstphrchvz | Owner: herbygillot
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.7.1
Resolution: | Keywords:
Port: mysql8 |
---------------------------+-------------------------
Comment (by kencu):
Replying to [comment:12 chrstphrchvz]:
> To avoid confusion, I proposed cleaning up the “allow newer libtool”
patching: [https://github.com/macports/macports-ports/pull/13541]
There are many thousands of ports that build calling "{{{libtool"}}}.
About the only port that specifically forces {{{/usr/bin/libtool}}} is
{{{mysql*}}}, which it should never have done, as there is no possibly way
that {{{mysql*}}} could know which libtool is the proper one to use on
darwin. By doing this forcing, they were already breaking a bunch of
builds.
So (IMHO) to avoid confusion, you might best revert your "cleanup" and put
it back the way I fixed it, so that the first {{{libtool}}} in the path is
used, not {{{/usr/bin/libtool}}}, which is the way the other 10,000 ports
that use libtool on darwin are set up. Then our proper mechanisms work.
Sure, it should be upstreamed to get them to take out
{{{/usr/binlibtool}}} and just use {{{libtool}}} like everyone else. No
idea why someone at {{{mysql}}} thought it would be a good idea to force
{{{/usr/bin/libtool}}} in the first place -- a misguided attempt to fix
something, I suspect.
There is no need to specifically patch mysql to use
{{{${prefix}}}/bin/libtool}}}, as our proper mechanisms will work, and the
other 10,000 ports that use libtool are not so patched. It won't break
anything, of course, at least not immediately, but it is, in it's own way,
as wrong as mysql forcing {{{/usr/bin/libtool}}}. Just use {{{libtool}}}
and all will be well.
> but that made no difference to this problem.
of course.
I only notice that it prevents trace mode from saying:
>
> {{{
> Warning: The following existing files were hidden from the build system
by trace mode:
> …
> /opt/local/bin/libtool
> }}}
As you would expect, if there is not a specified dep anywhere for cctools,
then that file will be ignored.
> because [122fca8e4617/macports-ports] was done without specifying
cctools as a build dependency, meaning that using trace mode defeats the
purpose of that change.
That is not, in general, correct, although it may be correct now if we
want to use cctools libtool on a system that doesn't use a macports-
clang-* compiler.
All older systems that use macports-clang-* already have added a dep for
cctools as part of the use of macports-clang=*, as you can see here:
https://ports.macports.org/port/clang-9.0/details/
so the purpose of the change was not defeated in general. But it may now
need to be extended.
> Similar patching is still done in e.g. mysql56 and mariadb; should those
instead add cctools build dependency and patch to use
`${prefix}/bin/libtool` on older systems?
This is not needed, see above, the dep to cctools is already added by the
macports-clang-* ports.
https://ports.macports.org/port/clang-9.0/details/
HOWEVER, there might now being something NEW going on.
What you may (or may not, we wait to see) have found here in this ticket
appears to be that now some newer version of macos (that is not presently
using a macports-clang compiler to build mysql) has a
{{{/usr/bin/libtool}}} that fails when building mysql, but the libtool
provided by cctools at {{{${prefix}/bin/libtool}}} does build it. Although
above you say you don't agree that this is the case, it seems to be the
case, and we await more information about whether it is or is not the case
that the libtool from cctools works but the libtool at /usr/bin/libtool
does not work.
So some newer systems might now need to be coerced to use this newer
libtool as well as the older systems that were already using it.
That new information would mean adding a dep on cctools to such systems in
mysql (which would be redundant for systems that build using a macports-
clang compiler, but that's fine), and again putting back the fix to stop
mysql from using the wrong {{{libtool}}}.
--
Ticket URL: <https://trac.macports.org/ticket/63455#comment:14>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list