On 2 November 2017 at 09:09, Daniel Henrique Barboza <danie...@linux.vnet.ibm.com> wrote: > When executing 'configure' in a fresh QEMU clone, in a fresh > OS install running in a ppc64le host, this is the error > shown: > > ----- > > ../configure --enable-trace-backend=simple --enable-debug > --target-list=ppc64-softmmu > > ERROR: Unsupported CPU = ppc64le, try --enable-tcg-interpreter > > ----- > > This isn't true, ppc64le host CPU is supported. This happens because, > in a fresh install, we don't have a C compiler to autodetect > the $cpu variable to "ppc64". > > This patch moves the CC available check up a bit, just before verifying > the host CPU. This ensures that we bail out with a $CC not available > error instead of unsupported CPU (the host CPU detection without > the compiler wouldn't work properly anyway). It also allows --help to > keep working without a C compiler. With this patch, in the same ppc64le > host without gcc: > > $ ../configure --enable-trace-backend=simple --enable-debug > --target-list=ppc64-softmmu > > ERROR: "cc" either does not exist or does not work > > $ ../configure --help > > Usage: configure [options] > Options: [defaults in brackets after descriptions] > > Standard options: > --help print this message > --prefix=PREFIX install in PREFIX [/usr/local] > --interp-prefix=PREFIX where to find shared libraries, etc. > (...) > > Signed-off-by: Daniel Henrique Barboza <danie...@linux.vnet.ibm.com> > --- > configure | 25 ++++++++++++++----------- > 1 file changed, 14 insertions(+), 11 deletions(-)
Reviewed-by: Peter Maydell <peter.mayd...@linaro.org> ccing qemu-trivial since that seems like a plausible tree for this. thanks -- PMM