diff --git a/sys/conf/kern.mk b/sys/conf/kern.mk index 5cd3a43f01b..d51aa1f1dfa 100644 --- a/sys/conf/kern.mk +++ b/sys/conf/kern.mk @@ -284,14 +284,10 @@ PHONY_NOTMAIN = afterdepend afterinstall all beforedepend beforeinstall \ CSTD?= gnu99 -.if ${CSTD} == "k&r" -CFLAGS+= -traditional -.elif ${CSTD} == "c89" || ${CSTD} == "c90" -CFLAGS+= -std=iso9899:1990 -.elif ${CSTD} == "c94" || ${CSTD} == "c95" -CFLAGS+= -std=iso9899:199409 -.elif ${CSTD} == "c99" -CFLAGS+= -std=iso9899:1999 +# c99/gnu99 is the minimum C standard version supported for kernel build +.if ${CSTD} == "k&r" || ${CSTD} == "c89" || ${CSTD} == "c90" || \ + ${CSTD} == "c94" || ${CSTD} == "c95" +.error "Only c99/gnu99 or later is supported" .else # CSTD CFLAGS+= -std=${CSTD} .endif # CSTD