From 0c5af65cfb92b7702f170999488c970fc278d9a2 Mon Sep 17 00:00:00 2001 From: Sam James Date: Fri, 23 Feb 2024 07:16:07 +0000 Subject: toolchain.eclass: allow fixincludes for mingw & special MIPS target config/i386/t-cygming always sets STMP_FIXINC regardless of the configure arg for fixincludes, so don't disable it there. The only other case is config/mips/t-sdemtk which I've handled too. Exposed by 0b75d3ce0bae8240c28c6a8f191f5130548f8475. Bug: https://bugs.gentoo.org/905118 Closes: https://bugs.gentoo.org/925204 Signed-off-by: Sam James --- eclass/toolchain.eclass | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'eclass') diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass index 67a04f297d6b..fef38790922c 100644 --- a/eclass/toolchain.eclass +++ b/eclass/toolchain.eclass @@ -1309,6 +1309,22 @@ toolchain_src_configure() { GCC_RUN_FIXINCLUDES=1 fi + case ${CBUILD}-${CHOST}-${CTARGET} in + *i686-w64-mingw32*|*x86_64-w64-mingw32*) + # config/i386/t-cygming requires fixincludes (bug #925204) + GCC_RUN_FIXINCLUDES=1 + ;; + *mips*-sde-elf*) + # config/mips/t-sdemtk needs fixincludes too (bug #925204) + # It maps to mips*-sde-elf*, but only with --without-newlib. + if [[ ${confgcc} != *with-newlib* ]] ; then + GCC_RUN_FIXINCLUDES=1 + fi + ;; + *) + ;; + esac + if [[ ${GCC_RUN_FIXINCLUDES} == 1 ]] ; then confgcc+=( --enable-fixincludes ) else -- cgit v1.2.3-65-gdbad