[Skiboot] [PATCH 5/6] Enforce GNU 11 as default C dialect

Joel Stanley joel at jms.id.au
Tue Jul 21 13:23:14 AEST 2015


We do not set a C version level, leaving it to the compiler to enforce
whatever it saw fit.

We require GCC 4.8 or above, which supports C11, and GCC 5.2 and clang
3.7 default to this version of the standard, so set it as the default.

Signed-off-by: Joel Stanley <joel at jms.id.au>
---
 Makefile.main | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Makefile.main b/Makefile.main
index 3851c20..eeba745 100644
--- a/Makefile.main
+++ b/Makefile.main
@@ -51,7 +51,7 @@ CPPFLAGS += -DBITS_PER_LONG=64 -DHAVE_BIG_ENDIAN
 CPPFLAGS += -ffreestanding
 
 CFLAGS := -fno-strict-aliasing -fstack-protector-all -pie -mbig-endian -m64
-CFLAGS += -Wl,--oformat,elf64-powerpc
+CFLAGS += -Wl,--oformat,elf64-powerpc -std=gnu11
 
 ifeq ($(SKIBOOT_GCOV),1)
 CFLAGS += -fprofile-arcs -ftest-coverage -DSKIBOOT_GCOV=1
-- 
2.1.4



More information about the Skiboot mailing list