diff options
author | Paolo Bonzini | 2016-08-30 14:30:11 +0200 |
---|---|---|
committer | Paolo Bonzini | 2016-08-30 16:28:46 +0200 |
commit | 336d5881a927cd80e8c0ff61c7f76b1433f91bb0 (patch) | |
tree | 6b60765e8527cd3b943fad4c6722b0eb88bb2847 /pc-bios/optionrom | |
parent | Revert "Change net/socket.c to use socket_*() functions" (diff) | |
download | qemu-336d5881a927cd80e8c0ff61c7f76b1433f91bb0.tar.gz qemu-336d5881a927cd80e8c0ff61c7f76b1433f91bb0.tar.xz qemu-336d5881a927cd80e8c0ff61c7f76b1433f91bb0.zip |
optionrom: cope with multiple -O options
Reproducer:
CFLAGS="-g3 -O0" ./configure --target-list=aarch64-softmmu,arm-softmmu --enable-vhost-net --enable-virtfs
Here CFLAGS ends up with "-O2 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 ... -g3 -O0"
and pc-bios/optionrom/Makefile forgets to add the -O2 it needs.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'pc-bios/optionrom')
-rw-r--r-- | pc-bios/optionrom/Makefile | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/pc-bios/optionrom/Makefile b/pc-bios/optionrom/Makefile index 9bdc49798c..afa48f1cf1 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 |