Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 5 Feb 2011 13:10:09 +0000
From:      Alexander Best <arundel@freebsd.org>
To:        John Baldwin <jhb@freebsd.org>
Cc:        freebsd-current@freebsd.org
Subject:   Re: [RFC] removing broken includes
Message-ID:  <20110205131009.GA37662@freebsd.org>
In-Reply-To: <201102040756.12109.jhb@freebsd.org>
References:  <20110203221257.GA76849@freebsd.org> <201102040756.12109.jhb@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--Qxx1br4bt0+wmkIi
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

On Fri Feb  4 11, John Baldwin wrote:
> On Thursday, February 03, 2011 5:12:57 pm Alexander Best wrote:
> > hi everybody,
> > 
> > i've started to check the source for broken includes, such as the one fixed in
> > r218189. so far i've run through arch=amd64 and found only two broken includes,
> > which should be fixed by the attached patch. the commands i'm using are:
> 
> The sys/conf/files fix should definitely go in.

after sys/modules/netgraph/atm/ccatm/Makefile has been fixed, maybe we could
extend the warnings at least for the kernel. that way new commits would need
to make sure that no broken includes are being added to the src.

any thoughts on this patch?

cheers.
alex

ps: -W was renamed to -Werrer. see the gcc(1) manual page.

> 
> -- 
> John Baldwin

-- 
a13x

--Qxx1br4bt0+wmkIi
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="kern.mk.diff"

Index: sys/conf/kern.mk
===================================================================
--- sys/conf/kern.mk	(revision 218319)
+++ sys/conf/kern.mk	(working copy)
@@ -3,7 +3,7 @@
 #
 # Warning flags for compiling the kernel and components of the kernel.
 #
-# Note that the newly added -Wcast-qual is responsible for generating 
+# Note that the newly added -Wcast-qual is responsible for generating
 # most of the remaining warnings.  Warnings introduced with -Wall will
 # also pop up, but are easier to fix.
 .if ${CC:T:Micc} == "icc"
@@ -12,17 +12,18 @@
 .else
 CWARNFLAGS?=	-Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes \
 		-Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual \
-		-Wundef -Wno-pointer-sign -fformat-extensions
+		-Wundef -Wno-pointer-sign -fformat-extensions \
+		-Wmissing-include-dirs
 .endif
 #
 # The following flags are next up for working on:
-#	-W
+#	-Wextra
 
 #
 # On the i386, do not align the stack to 16-byte boundaries.  Otherwise GCC
 # 2.95 adds code to the entry and exit point of every function to align the
 # stack to 16-byte boundaries -- thus wasting approximately 12 bytes of stack
-# per function call.  While the 16-byte alignment may benefit micro benchmarks, 
+# per function call.  While the 16-byte alignment may benefit micro benchmarks,
 # it is probably an overall loss as it makes the code bigger (less efficient
 # use of code cache tag lines) and uses more stack (less efficient use of data
 # cache tag lines).  Explicitly prohibit the use of SSE and other SIMD

--Qxx1br4bt0+wmkIi--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20110205131009.GA37662>