From owner-svn-src-all@FreeBSD.ORG Thu Feb 16 05:52:55 2012 Return-Path: Delivered-To: svn-src-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3B6A1106564A; Thu, 16 Feb 2012 05:52:55 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail09.syd.optusnet.com.au (mail09.syd.optusnet.com.au [211.29.132.190]) by mx1.freebsd.org (Postfix) with ESMTP id A9C328FC0A; Thu, 16 Feb 2012 05:52:54 +0000 (UTC) Received: from c211-30-171-136.carlnfd1.nsw.optusnet.com.au (c211-30-171-136.carlnfd1.nsw.optusnet.com.au [211.30.171.136]) by mail09.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id q1G5QAL8020279 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 16 Feb 2012 16:26:36 +1100 Date: Thu, 16 Feb 2012 16:26:10 +1100 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Warner Losh In-Reply-To: <201202152120.q1FLKww4081902@svn.freebsd.org> Message-ID: <20120216160800.P1018@besplex.bde.org> References: <201202152120.q1FLKww4081902@svn.freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r231780 - head/share/mk X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Feb 2012 05:52:55 -0000 On Wed, 15 Feb 2012, Warner Losh wrote: > Log: > Wordsmith the can't find kernel error message, and suggest which > variable to set to override. > > Modified: > head/share/mk/bsd.kmod.mk > > Modified: head/share/mk/bsd.kmod.mk > ============================================================================== > --- head/share/mk/bsd.kmod.mk Wed Feb 15 21:03:26 2012 (r231779) > +++ head/share/mk/bsd.kmod.mk Wed Feb 15 21:20:58 2012 (r231780) > @@ -9,7 +9,7 @@ SYSDIR= ${_dir} > .endfor > .if !defined(SYSDIR) || !exists(${SYSDIR}/kern/) || \ > !exists(${SYSDIR}/conf/kmod.mk) > -.error "can't find kernel source tree" > +.error "can't locate the kernel source tree, set SYSDIR to override." > .endif > > .include "${SYSDIR}/conf/kmod.mk" This adds 2 punctuation errors: - comma (comma splice) - period. Error messages are not terminated in KNF. However, most of the others in *.mk are terminated. This one also differs from the style of most of the others in quoting the string. The only other one that uses quotes is the only other one that doesn't use a period. It is unclear what tokens can go after .error. In C, the tokens after #error should always be quoted, since some tokens are special. About 1/3 of the others don't contrace "cannot" to "can't". None of the others has the comma splice error. This might be because none of the others has multiple clauses. When clauses are spliced using a comma, the comma must be followed by a conjunctive adverb, but a semicolon usually works and helps keep error messages short. Bruce