Matt Whitlock ec695aaabe multilib.eclass: derive BUILD_* before appending ABI flags
Per [1], we cannot have ${MULTILIB_USEDEP} in BDEPEND because it would
break cross-compiles, as ${MULTILIB_USEDEP} specifies ABIs of CHOST, not
of CBUILD.

However, this leads to a problem, as multilib.eclass does not preserve
the default build-machine toolchain before it appends the ABI flags to
the host-machine toolchain. Thus, when $(tc-getBUILD_CC) later pulls a
default value for BUILD_CC from CC, the ABI flags have already been
appended to CC, and BUILD_CC inherits those flags, thus causing any
build-time helper executables to be built for a non-default ABI, whose
build-time dependencies may not be installed in ${BROOT} since
${MULTILIB_USEDEP} makes no sense in BDEPEND.

Note, the behavior is inconsistent if the user has set BUILD_CC and
friends via their package.env, as then the ABI flags are *not* applied
to the build-machine toolchain via defaulting from the host-machine
toolchain.

This commit fixes up multilib.eclass so that it derives the build-
machine toolchain variables _before_ it appends the ABI flags to the
host-machine toolchain variables and so that it overrides CBUILD to the
default ABI in the non-cross-compiling case. The result is that build-
time helper executables are always built for the build machine's
_default_ ABI, even in the non-cross-compiling case.

[1] https://bugs.gentoo.org/960506#c9

Bug: https://bugs.gentoo.org/960506
Signed-off-by: Matt Whitlock <gentoo@mattwhitlock.name>
Signed-off-by: James Le Cuirot <chewi@gentoo.org>
2026-01-03 09:01:47 +00:00
2026-01-03 07:58:11 +01:00
2025-12-19 10:51:55 +01:00
2025-12-19 10:51:55 +01:00
2025-12-19 10:51:55 +01:00
2026-01-03 05:46:50 +00:00
2025-12-19 10:51:55 +01:00
2025-12-26 21:51:25 +01:00
2025-12-19 10:51:55 +01:00
2025-12-19 10:51:55 +01:00
2025-12-30 21:00:09 +01:00
2026-01-01 23:39:31 +00:00
2025-12-19 10:51:55 +01:00
2025-12-19 10:51:55 +01:00
2025-12-19 10:51:55 +01:00
2026-01-01 21:42:49 +01:00
2025-12-31 20:35:07 +07:00
2025-12-19 10:51:55 +01:00
2025-12-29 20:28:17 +01:00
2026-01-03 08:12:23 +01:00
2025-12-19 10:51:55 +01:00
2025-12-31 00:09:05 +01:00
2025-12-19 10:51:55 +01:00
2025-12-29 21:36:09 -05:00
2025-12-19 10:51:55 +01:00
2025-12-24 17:21:05 +00:00
2025-12-19 10:51:55 +01:00
2026-01-02 00:53:03 +00:00
2025-12-19 10:51:55 +01:00
2025-12-31 11:06:45 +01:00
2025-12-31 13:05:13 +00:00
2025-12-19 10:51:55 +01:00
2025-12-28 21:03:43 +02:00
2025-12-21 18:33:34 +01:00
2026-01-01 15:32:30 -08:00
2025-12-07 11:41:15 +01:00
2025-12-22 11:07:26 +08:00
2025-12-19 10:51:55 +01:00
2025-12-19 10:51:55 +01:00
2025-12-19 10:51:55 +01:00
2026-01-02 23:51:54 +02:00
2025-12-22 13:10:05 +00:00
2025-12-19 10:51:55 +01:00
2026-01-02 21:08:55 +01:00
2025-12-19 10:51:55 +01:00
2026-01-01 08:01:15 +00:00
2025-12-19 10:51:55 +01:00
2025-12-26 21:54:04 +01:00
2025-12-19 10:51:55 +01:00
…
S
Description
No description provided
9.8 GiB
Languages
Shell 98%
Roff 1.4%
Emacs Lisp 0.2%
C 0.1%