Hello. I am building mips test image and found that make 4.3 is broken on mips, make 4.2.1-r4 works perfect. How to reproduce it? 1. Install static qemu-user with mips and register it. 2. Prepare basic mips toolchain using crossdev inside container. 3. Cross compile make. 4. Run "ebuild prepare" on any ebuild which uses make (for example coreutils). 5. Try to use "LD_LIBRARY_PATH='/usr/mips-unknown-linux-gnu/lib' strace /usr/mips-unknown-linux-gnu/usr/bin/make" instead of regular make. You will receive the following result: > make: *** [Makefile:13043: lib/alloca.h] Error 127 I will attach here a log with strace output using the following command: buildah --cap-add=CAP_SYS_PTRACE run 98e3090980d8 -- sh -c "cd /var/tmp/portage/sys-apps/coreutils-8.31-r1/work/coreutils-8.31 && LD_LIBRARY_PATH='/usr/mips-unknown-linux-gnu/lib' strace -v /usr/mips-unknown-linux-gnu/usr/bin/make" Reproducible: Always
Created attachment 617268 [details] make.log.xz
LD_LIBRARY_PATH= is generally not a valid way to set root for qemu-user. Your binfmt_mist registration should pass root path via -L option. I'm using the following: $ cat /qemu-mipsn32 #!/bin/bash exec /usr/bin/qemu-mipsn32 -L /usr/mips64-unknown-linux-gnu/ "$@" Running strace against qemu-user might also not be the best way to sxplore emulated binary. qemu-user provides a -strace option (or QEMU_STRACE variable for it). Also make sure you are not encountering bug #708758.
Thank you. I will try to debug it tomorrow.
I've compiled make 4.3 with --disable-posix-spawn and after that everything works perfect. So we will mark this issue as duplicate of 708758.
*** This bug has been marked as a duplicate of bug 708758 ***