Date: Mon, 8 Apr 2013 13:18:24 +0000 From: Alexey Dokuchaev <danfe@FreeBSD.org> To: William Grzybowski <wg@FreeBSD.org> Cc: svn-ports-head@freebsd.org, svn-ports-all@freebsd.org, ports-committers@freebsd.org Subject: Re: svn commit: r315759 - head/graphics/sane-backends Message-ID: <20130408131824.GA88766@FreeBSD.org> In-Reply-To: <201304081226.r38CQlZe065130@svn.freebsd.org> References: <201304081226.r38CQlZe065130@svn.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Apr 08, 2013 at 12:26:47PM +0000, William Grzybowski wrote: > New Revision: 315759 > URL: http://svnweb.freebsd.org/changeset/ports/315759 > > Log: > - Fix inverted logic for USB option > > @@ -53,7 +53,7 @@ LDFLAGS+= -L${LOCALBASE}/lib > .include "Makefile.man" > .include <bsd.port.pre.mk> > > -.if ${PORT_OPTIONS:MUSB} > +.if empty(PORT_OPTIONS:MUSB) > CONFIGURE_ARGS+= --disable-libusb > .endif While technically empty()-form is equivalent to !-form, the latter should had been probably used instead, for the following reasons: - !-form is given as an example in PH (Example 5-12); - In the same PH page, in the last note, empty() is only suggested as alternative syntax when traditional check cannot be used for some reason; - empty()-form is more error prone: it's relatively easy to make mistakes like empty(${FOO}) vs. correct emtpy(FOO) which go unnoticed as make(1) does not issue any warning; - Let's not increase diversity in syntax; most ports use !-form. ./danfe
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130408131824.GA88766>