qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] QEMU make: ROM is too large


From: Paolo Bonzini
Subject: Re: [Qemu-devel] QEMU make: ROM is too large
Date: Tue, 30 Aug 2016 14:29:14 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0


On 22/08/2016 18:44, Thomas Hanson wrote:
> On 22 August 2016 at 08:23, Peter Maydell <address@hidden
> <mailto:address@hidden>> wrote:
> 
>     PS: just passing --enable-debug to configure should
>     be sufficient to do a no-optimization debug-symbols
>     build; do you really need to manually specify
>     CFLAGS? I wonder whether you're ending up with two
>     -Osomething options in your CFLAGS which is then
>     confusing the "override with -O2" logic in the
>     pc-bios/optionrom/Makefile.

Yes, here is a patch to fix it:

diff --git a/pc-bios/optionrom/Makefile b/pc-bios/optionrom/Makefile
index 9bdc497..eb92d75 100644
--- a/pc-bios/optionrom/Makefile
+++ b/pc-bios/optionrom/Makefile
@@ -10,10 +10,7 @@ $(call set-vpath, $(SRC_PATH)/pc-bios/optionrom)
 .PHONY : all clean build-all
 
 # Compiling with no optimization creates ROMs that are too large
-ifeq ($(filter -O%, $(CFLAGS)),)
-override CFLAGS += -O2
-endif
-ifeq ($(filter -O%, $(CFLAGS)),-O0)
+ifeq ($(lastword $(filter -O%, -O0 $(CFLAGS))),-O0)
 override CFLAGS += -O2
 endif
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]