Date: Mon, 11 Jun 2012 16:07:26 +0200 From: Baptiste Daroussin <bapt@freebsd.org> To: Warren Block <wblock@wonkity.com> Cc: ports@freebsd.org, Jason Helfman <jhelfman@e-e.com> Subject: Re: NOPORTDOCS and NOPORTEXAMPLES Message-ID: <20120611140725.GY60433@ithaqua.etoilebsd.net> In-Reply-To: <alpine.BSF.2.00.1206110755001.82724@wonkity.com> References: <alpine.BSF.2.00.1206101408330.77586@wonkity.com> <f5dc8813da21631bff52d1017bcd6dcf.squirrel@mail.experts-exchange.com> <alpine.BSF.2.00.1206101736170.78656@wonkity.com> <20120611051759.GQ60433@ithaqua.etoilebsd.net> <alpine.BSF.2.00.1206110755001.82724@wonkity.com>
next in thread | previous in thread | raw e-mail | index | archive | help
--XiX5sJQOWZsNRXst Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Jun 11, 2012 at 08:00:53AM -0600, Warren Block wrote: > On Mon, 11 Jun 2012, Baptiste Daroussin wrote: >=20 > > On Sun, Jun 10, 2012 at 06:05:49PM -0600, Warren Block wrote: > >> On Sun, 10 Jun 2012, Jason Helfman wrote: > >> > >>>> So references to NOPORTDOCS should be replaced with references to > >>>> PORT_OPTIONS:MDOCS now? Why that but not NOPORTEXAMPLES? > >>> > >>> You can use PORT_OPTIONS:MEXAMPLES for this case. > >>> > >>> I believe I did this recently in www/flot > >> > >> But only after bsd.port.options.mk is included. Here's what I was > >> trying to do: > >> > >> .if ${PORT_OPTIONS:MDOCS} > >> OPTIONS_DEFINE+=3D REFDOCS > >> REFDOCS_DESC=3D Install the reference documents > >> OPTIONS_DEFAULT+=3D REFDOCS > >> .endif > >> > >> .if ${PORT_OPTIONS:MEXAMPLES} > >> OPTIONS_DEFINE+=3D EXAMPLES > >> EXAMPLES_DESC=3D Install the example code > >> OPTIONS_DEFAULT+=3D EXAMPLES > >> .endif > >> > >> .include <bsd.port.options.mk> > >> > > > > Why not simply that way: > > > > OPTIONS_DEFINE=3D ... DOCS EXAMPLES > > > > DOCS_DESC=3D Install the reference documents > > > > And done. > > > > Condtion an EXAMPLES on EXAMPLES options doesn't make sense to me. > > > > by default DOCS and EXAMPLES are on expect if the user set NOPORTDOCS, > > NOPORTEXAMPLES or OPTIONS_UNSET=3D DOCS EXAMPLES >=20 > The logic has probably gotten twisted around, and it's been long enough= =20 > since I did this that I don't recall the situation. I think it was just= =20 > to prevent the options screen from appearing if NOPORTDOCS and=20 > NOPORTEXAMPLES were set. >=20 > I don't see a way to do that without using the old versions of those=20 > variables. The new ones have not been set until after=20 > bsd.port.options.mk is included, and by then the dialog has been shown. Do not put OPTIONS_DEFINE and you won't get a dialog UI but still can test PORT_OPTIONS:MEXAMPLES and PORT_OPTIONS:MDOCS regards, Bapt --XiX5sJQOWZsNRXst Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEUEARECAAYFAk/V+50ACgkQ8kTtMUmk6ExXjQCeKRPoVKOZgreOY6oxkfpgMDux xggAkQHuq0bQA1VWt3xLYycvDsW3UZg= =vJcS -----END PGP SIGNATURE----- --XiX5sJQOWZsNRXst--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20120611140725.GY60433>