Hi! On Wed, 2023-09-13 17:52:14 +0800, Yang Yujie wrote: > Library build options from --with-multilib-list used to be processed with > *self_spec, which missed the driver's initial canonicalization. This > caused limitations on CFLAGS override and the use of driver-only options > like -m[no]-lsx. > > The problem is solved by promoting the injection rules of --with-multilib-list > options to the first element of DRIVER_SELF_SPECS, to make them execute before > the canonialization. The library-build options are also hard-coded in > the driver and can be used conveniently by the builders of other non-gcc > libraries via the use of -fmultiflags. > > Bootstrapped and tested on loongarch64-linux-gnu. Seems this breaks for me with ../gcc/configure [...] --enable-werror-always --enable-languages=all --disable-gcov --disable-shared --disable-threads --target=loongarch64-linux-gnuf32 --without-headers make V=1 all-gcc See eg. http://toolchain.lug-owl.de/laminar/jobs/gcc-loongarch64-linux-gnuf32/44 : /var/lib/laminar/run/gcc-loongarch64-linux-gnuf32/44/local-toolchain-install/bin/g++ -c -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wmissing-format-attribute -Wconditionally-supported -Woverloaded-virtual -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -Werror -fno-common -DHAVE_CONFIG_H -DGENERATOR_FILE -I. -Ibuild -I../../gcc/gcc -I../../gcc/gcc/build -I../../gcc/gcc/../include -I../../gcc/gcc/../libcpp/include \ -o build/genpreds.o ../../gcc/gcc/genpreds.cc In file included from ../../gcc/gcc/config/loongarch/loongarch.h:53, from ./tm.h:50, from ../../gcc/gcc/genpreds.cc:26: ../../gcc/gcc/config/loongarch/loongarch-driver.h:82:10: fatal error: loongarch-multilib.h: No such file or directory 82 | #include "loongarch-multilib.h" | ^~~~~~~~~~~~~~~~~~~~~~ compilation terminated. make[1]: *** [Makefile:2966: build/genpreds.o] Error 1 make[1]: Leaving directory '/var/lib/laminar/run/gcc-loongarch64-linux-gnuf32/44/toolchain-build/gcc' make: *** [Makefile:4659: all-gcc] Error 2 So it failed to execute the t-multilib fragment? Happens for all my loongarch compilation tests: http://toolchain.lug-owl.de/laminar/jobs/gcc-loongarch64-linux/45 http://toolchain.lug-owl.de/laminar/jobs/gcc-loongarch64-linux-gnuf32/44 http://toolchain.lug-owl.de/laminar/jobs/gcc-loongarch64-linux-gnuf64/44 http://toolchain.lug-owl.de/laminar/jobs/gcc-loongarch64-linux-gnusf/44 And when this is fixed, it might be a nice idea to have a --with-multilib-list config in ./contrib/config-list.mk . MfG, JBG --