Module Name: src
Committed By: matt
Date: Sun Jan 2 19:24:48 UTC 2011
Modified Files:
src/share/mk: bsd.kmodule.mk
src/sys/conf: Makefile.kern.inc
Log Message:
Kernels modules are c99 (gnu99) just like the kernel.
Add(move) -std=gnu99 to CPPFLAGS (from COPTS).
To generate a diff of this commit:
cvs rdiff -u -r1.26 -r1.27 src/share/mk/bsd.kmodule.mk
cvs rdiff -u -r1.127 -r1.128 src/sys/conf/Makefile.kern.inc
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/share/mk/bsd.kmodule.mk
diff -u src/share/mk/bsd.kmodule.mk:1.26 src/share/mk/bsd.kmodule.mk:1.27
--- src/share/mk/bsd.kmodule.mk:1.26 Sat Dec 11 18:42:33 2010
+++ src/share/mk/bsd.kmodule.mk Sun Jan 2 19:24:47 2011
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.kmodule.mk,v 1.26 2010/12/11 18:42:33 martin Exp $
+# $NetBSD: bsd.kmodule.mk,v 1.27 2011/01/02 19:24:47 matt Exp $
# We are not building this with PIE
MKPIE=no
@@ -17,6 +17,7 @@
CPPFLAGS+= -nostdinc -I. -I${.CURDIR} -isystem $S -isystem $S/arch
CPPFLAGS+= -isystem ${S}/../common/include
CPPFLAGS+= -D_KERNEL -D_LKM -D_MODULE
+CPPFLAGS+= -std=gnu99
# XXX until the kernel is fixed again...
.if (defined(HAVE_GCC) && ${HAVE_GCC} == 4) || defined(HAVE_PCC)
Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.127 src/sys/conf/Makefile.kern.inc:1.128
--- src/sys/conf/Makefile.kern.inc:1.127 Fri Mar 5 23:06:49 2010
+++ src/sys/conf/Makefile.kern.inc Sun Jan 2 19:24:48 2011
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.kern.inc,v 1.127 2010/03/05 23:06:49 njoly Exp $
+# $NetBSD: Makefile.kern.inc,v 1.128 2011/01/02 19:24:48 matt Exp $
#
# This file contains common `MI' targets and definitions and it is included
# at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -57,9 +57,9 @@
INCLUDES?= -I. ${EXTRA_INCLUDES} -I${S}/../common/include -I$S/arch \
-I$S -nostdinc
CPPFLAGS+= ${INCLUDES} ${IDENT} ${PARAM} -D_KERNEL -D_KERNEL_OPT
+CPPFLAGS+= -std=gnu99
DEFCOPTS?= -O2
COPTS?= ${DEFCOPTS}
-COPTS+= -std=gnu99
DBG= # might contain unwanted -Ofoo
DEFWARNINGS?= yes
.if (${DEFWARNINGS} == "yes")