[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH] Only compile the hypervisor with -Wdeclaration-after-statement
Hi Andrew, On 05/12/2023 19:49, Andrew Cooper wrote: On 05/12/2023 6:32 pm, Julien Grall wrote:diff --git a/xen/Makefile b/xen/Makefile index ca571103c868..360fb6dcae57 100644 --- a/xen/Makefile +++ b/xen/Makefile @@ -393,6 +393,7 @@ CFLAGS-$(CONFIG_CC_SPLIT_SECTIONS) += -ffunction-sections -fdata-sectionsCFLAGS += -nostdinc -fno-builtin -fno-commonCFLAGS += -Werror -Wredundant-decls -Wwrite-strings -Wno-pointer-arith +$(call cc-option-add,CFLAGS,CC,-Wdeclaration-after-statement)I agree with the direction of the patch, but this should be a plain CFLAGS += All compilers we support, even on x86, know -Wdeclaration-after-statement so it doesn't need a toolchain-check to activate. That's good to know, I wasn't sure and.. https://godbolt.org/z/PM7bb1d55 .. I keep forgetting godbolt.org can help to check old compilers. I will update the patch in my tree. With that fixed, Acked-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> Thanks! Cheers, -- Julien Grall
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |