On Thu, 4 Mar 2010 09:38:12 +0100 Marc Espie <es...@nerim.net> wrote:
> On Wed, Mar 03, 2010 at 04:46:18PM -0800, J.C. Roberts wrote: > > Boolean variables should be set to Yes instead of simply > > being defined, for uniformity and future compatibility. > > This takes time to finish changing. > > > 1.) The majority of the scripts in ports/infrastructure do not > > bother to check /etc/mk.conf at all, so saying "or" and "also" seems > > unwise without context. The best answer seems to be to preface the > > statement with, "When running make ..." > > This ought to change. It's just a bit more expensive to do it in > scripts, as it requires running make. > The first hurdle for me is checking to make sure all the scripts use the environment variables. Once those patches are in, we can revisit the /etc/mk.conf, make, and performance issues. > mk.conf is *NOT* a config file, it is a piece of Makefile ! > Yep, it's a Makefile typically used to store local configuration. ;) > > 5.) Considering the precedence set by other /etc/*.conf files like > > rc.conf, using all caps of "YES" or "NO" for true/false would be > > more consistent. --Since Marc is the main chef of the ports system, > > this should probably be his call. Chefs' choice and all that. > > No, I hate YES. I explicitly changed it because I hate it. > You can use YES if you want for your own stuff, but make has > ${V:L} explicitly to allow for any kindofase. I had a funny feeling about the capitalization. It seemed someone had obviously used "Yes" by intent in spite of the precedence for using "YES" --I left the capitalization as you prefer, but made sure everything is quoted identically with straight double quotes. ------------------------------------------------------------------- Index: ports.7 =================================================================== RCS file: /cvs/src/share/man/man7/ports.7,v retrieving revision 1.79 diff -u ports.7 --- ports.7 11 Oct 2009 21:07:06 -0000 1.79 +++ ports.7 4 Mar 2010 13:47:36 -0000 @@ -242,7 +242,7 @@ Defining .Ev NO_CHECKSUM to -.Dv Yes +.Qq Yes will skip this step. Sometimes, distfiles change without warning. The main @@ -269,7 +269,7 @@ Defining .Ev NO_DEPENDS to -.Dv Yes +.Qq Yes will skip this step. .It Ar extract Expand the distfile into a work directory. @@ -307,7 +307,7 @@ This does not recurse to dependencies unless .Ev CLEANDEPENDS is defined to -.Dv Yes . +.Qq Yes . .It Ar distclean Remove the port's distfile(s). This does not recurse to dependencies. @@ -398,7 +398,7 @@ If .Ev FORCE_UPDATE is set to -.Sq Yes , +.Qq Yes , dependencies will also be updated first, and packages will always be updated, even if there is no difference between the old and the new packages. .Pp @@ -422,7 +422,7 @@ and .Ev BULK are set to -.Sq Yes +.Qq Yes for a package build, some shortcuts are taken to allow cleaning up working directories on the fly. .Pp @@ -447,7 +447,7 @@ target with .Ev FORCE_UPDATE set to -.Sq Yes +.Qq Yes for the build. .Sh NETWORK CONFIGURATION The variables pertaining to network access have been marshalled into @@ -459,13 +459,13 @@ .Bl -tag -width MASTER_SITES .It Ev MASTER_SITE_OPENBSD If set to -.Dv Yes , +.Qq Yes , include the master .Ox site when fetching files. .It Ev MASTER_SITE_FREEBSD If set to -.Dv Yes , +.Qq Yes , include the master .Fx site when fetching files. @@ -569,16 +569,23 @@ $ env SUBPACKAGE="-server" make deinstall .Ed .Sh PORT VARIABLES -These can be changed in the environment, or in +When running make, these variables can be set in the environment, or set in .Pa /etc/mk.conf -for persistence. -They can also be set on make's command line, e.g., +for persistence, or set on make's command line, e.g., .Ic make VAR_FOO=foo .Pp -Boolean variables should be set to -.Dv Yes -instead of simply being defined, for uniformity and future compatibility. +The +.Ic ${PORTSDIR}/infrastructure/ +scripts will only acknowledge these variables when set in the environment. .Pp +Boolean variables which are flase by default should be set to +.Qq Yes +instead of simply being defined. Boolean variables which are true by defaut +should be set to +.Qq No +instead of simply being undefined. +This is for uniformity and future compatibility. +.Pp Variable names starting with _ are private to the ports infrastructure, should not be changed by the user, and are liable to change without notice. .Bl -tag -width MASTER_SITES @@ -618,9 +625,9 @@ Primary sites for distribution files if not found locally. .It Ev CLEANDEPENDS If set to -.Dv Yes , +.Qq Yes , let -.Sq clean +.Ar clean recurse to dependencies. .It Ev FETCH_CMD Command to use to fetch files. @@ -628,7 +635,7 @@ .Xr ftp 1 . .It Ev FETCH_PACKAGES If set to -.Dq Yes , +.Qq Yes , try to use .Xr pkg_add 1 to install the missing packages from @@ -641,7 +648,7 @@ If defined, only operate on a port if it can be installed 100% automatically. .It Ev USE_SYSTRACE Set to -.Sq Yes +.Qq Yes to protect the .Ar configure , build , and -------------------------------------------------------------------