Date: Sat, 30 Nov 2002 17:52:05 +1100 (EST) From: Bruce Evans <bde@zeta.org.au> To: Poul-Henning Kamp <phk@FreeBSD.ORG> Cc: current@FreeBSD.ORG Subject: Re: suggested WARNS makefile magic Message-ID: <20021130174805.T3454-100000@gamplex.bde.org> In-Reply-To: <1881.1038557926@critter.freebsd.dk>
next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 29 Nov 2002, Poul-Henning Kamp wrote: > Right now, if I want to ensure that a particular program compiles > with a WARNS level of no less than 3, I have to put this in the > Makefile: > > WARNS?= 3 > .if ${WARNS} < 3 > WARNS= 3 > .endif Only in broken Makefiles. WARNS?= 3 should work in all cases (except when WARNS is set at a higher level, e.g., on the command line, in which case the setter really wants that level and individual makefiles should not override it). Makefiles may be broken by including ../Makefile.inc before setting WARNS, in which case the setting may be obained from ../Makefile.inc and any setting in the Makefile is bogus. Another common error is "WARNS= 3" to break any setting at a higher level. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20021130174805.T3454-100000>