Date: Fri, 23 Nov 2007 22:25:00 +0300 From: Dmitry Marakasov <amdmi3@amdmi3.ru> To: Rainer Schwarze <rsc@admadic.de> Cc: freebsd-ports@FreeBSD.org Subject: Re: Newbie: problem using SUB_LIST in Makefile - SOLVED Message-ID: <20071123192500.GA37829@hades.panopticon> In-Reply-To: <4746DE95.8070304@admadic.de> References: <47443BE1.2080308@admadic.de> <20071123012758.GA29752@hades.panopticon> <4746DE95.8070304@admadic.de>
next in thread | previous in thread | raw e-mail | index | archive | help
* Rainer Schwarze (rsc@admadic.de) wrote: > You have the powers of a seer :-) > This is what I was appending to OPTIONS: > CWRAPPER "use C wrapper (no suid perl script needed)" on :)) > > .include <bsd.port.pre.mk> > > > > .if !defined(WITHOUT_CWRAPPER) > > Just a newbie question: Is there a reason to use !defined(WITHOUT_...) > instead of defined(WITH_...) ? There was once a rule that you should check for non-default values. I.e. if you have OPTIONS= CWRAPPER "C wrapper" on you should check for WITHOUT_CWRAPPER and if you have OPTIONS= CWRAPPER "C wrapper" off you should check for WITH_CWRAPPER The cause of this is that WITH(OUT)_CWRAPPER may be defined in /etc/make.conf, make environment or make commandline, and that should have higher priority than value set with OPTIONS. For example, you have: OPTIONS= CWRAPPER "C wrapper" on and in /etc/make.conf: WITHOUT_CWRAPPER= yes # I don't want any *** C wrappers!!! Thus, both WITHOUT_CWRAPPER and WITH_CWRAPPER will be defined, but the port will behave correctly if you check for WITHOUT_CWRAPPER. Actually, this was fixed, so you can check for either WITH_ or WITHOUT_ as you like (http://lists.freebsd.org/pipermail/freebsd-ports/2007-April/039831.html), but I prefer to stick with scheme described above. -- Dmitry A. Marakasov | jabber: amdmi3@jabber.ru amdmi3@amdmi3.ru | http://www.amdmi3.ru
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20071123192500.GA37829>