From b923a4c0d1a330e40f0a05f3bc94bb4f32ce1cbb Mon Sep 17 00:00:00 2001 From: Sam James Date: Tue, 19 Nov 2024 09:22:16 +0000 Subject: toolchain.eclass: wire up libdiagonstics See https://gcc.gnu.org/wiki/libdiagnostics. New shared library for diagnostics in GCC. Also provides the 'sarif-replay' tool. Signed-off-by: Sam James --- eclass/toolchain.eclass | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'eclass') diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass index f131da7dbd68..edff7254c905 100644 --- a/eclass/toolchain.eclass +++ b/eclass/toolchain.eclass @@ -333,6 +333,7 @@ if [[ ${PN} != kgcc64 && ${PN} != gcc-* ]] ; then # it was disabled in 13. tc_version_is_at_least 14.0.0_pre20230423 ${PV} && IUSE+=" rust" TC_FEATURES+=( rust ) tc_version_is_at_least 14.2.1_p20241026 ${PV} && IUSE+=" time64" + tc_version_is_at_least 15.0.0_pre20241124 ${PV} && IUSE+=" libdiagnostics" fi if tc_version_is_at_least 10; then @@ -1732,8 +1733,8 @@ toolchain_src_configure() { gcc_shell="${BROOT}"/bin/sh fi - if is_jit ; then - einfo "Configuring JIT gcc" + if is_jit || _tc_use_if_iuse libdiagnostics ; then + einfo "Configuring shared gcc for JIT/libdiagnostics" local confgcc_jit=( "${confgcc[@]}" @@ -1757,8 +1758,11 @@ toolchain_src_configure() { --disable-nls --disable-objc-gc --disable-systemtap + --enable-host-shared --enable-languages=jit + $(use_enable libdiagnostics) + # Might be used for the just-built GCC. Easier to just # respect USE=graphite here in case the user passes some # graphite flags rather than try strip them out. -- cgit v1.2.3-65-gdbad