I struggled with the build system, and I know the real problem: 1. linux-libc-dev-ARCH-cross is useful, for some case if we maintain an cross toolchain of a port that Debian is not supported yet. The example is src:cross-toolchain-base-mipsen. I support the cross toolchain for 12 MIPS ports: EL/BE X 32/64/N32 X R2/R6.
2. It is not OK to search base headers when we configure gcc itself. https://patchwork.sourceware.org/project/gcc/patch/20240614121218.63375-1-...@gcc.gnu.org/ GCC/configure.ac detects features by the headers of linux/glibc. Let’s have a example: we are building a mips64el cross toolchain on a amd64 machine: If gcc/configure.ac sees /usr/include/limits.h before than /usr/mips64el-linux-gnuabi64/include/limits.h Our mips64el-linux-gnuabi64-gcc will have some problem. And you can find the `fixinclude` in GCC for more information. @Mattias In fact. The current gcc-X-cross searches /usr/include when configure, it is dangerous. --includedir=/usr/mipsel-linux-gnu/include --with-sysroot=/ —prefix=/usr Is not good. The prefer way should be `—prefix=/usr` only with my patch.