[Buildroot] [PATCH 2/2] package/qemu: filter out long make options
Thomas Petazzoni
thomas.petazzoni at bootlin.com
Wed Jul 21 20:15:01 UTC 2021
Hello,
On Wed, 21 Jul 2021 12:46:05 -0700
Alexey Neyman <stilor at att.net> wrote:
> Since qemu started using ninja, they have the following fragment in the
> Makefile:
>
> MAKE.n = $(findstring n,$(firstword $(MAKEFLAGS)))
> NINJAFLAGS = ... $(if $(MAKE.n), -n) ...
>
> Buildroot's generated makefile in the O= directory invokes make in the
> base buildroot with --no-print-directory. However, make's placement of
> the --no-print-directory in MAKEFLAGS varies between the versions of
> the host make; make 4.3 places that at the end while make 3.82 places
> it at the beginning. As a result, if building on a system with an older
> host make, qemu's makefile invokes `ninja -n` which does not generate
> any outputs.
>
> To reproduce, on a CentOS 7 machine or docker image:
> mkdir /tmp/br-build && cd /tmp/br-build
> make -C ~/buildroot pc_x86_64_bios_defconfig O=`pwd`
> make menuconfig # Switch to glibc, enable "QEMU" and "QEMU tools"
> make all # Build succeeds
> find target -name qemu-img # No binary has been built
I'm not sure to grasp all the implications of this, but isn't this a
bug in Qemu's build machinery, that should be fixed in Qemu's Makefile
instead ?
Thomas
--
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
More information about the buildroot
mailing list