tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Expanding the default OPSYSVARS



Hi,

OPSYSVARS appears to be a little-known feature, but one which has the
potential to simplify our Makefiles a lot.  For example, instead of
having to do this dance:

  .include "../../mk/bsd.prefs.mk"
  
  .if ${OPSYS} == "Darwin"
  SUBST_CLASSES+=	foo

with 'SUBST_CLASSES' listed in OPSYSVARS, one only needs to do this:

  SUBST_CLASSES.Darwin+=	foo

I think one of the reasons it gets so little use is that the default
list of variables is too short.  I'd like to add the following
variables to the default list, based on some quick analysis of the
most-used variables (those used >30 times) within .if ${OPSYS} blocks:

  BUILD_TARGET
  BUILDLINK_TRANSFORM
  CONFIGURE_ARGS
  CONFIGURE_ENV
  MAKE_ENV
  PKG_SUGGESTED_OPTIONS
  SUBST_CLASSES
  USE_TOOLS

Cheers,

-- 
Jonathan Perkin  -  Joyent, Inc.  -  www.joyent.com


Home | Main Index | Thread Index | Old Index