bsd.pkg.mk says: # To sanitize the environment, set PKGSRC_SETENV=${SETENV} -i.

We'd like this to become the default. Steps:

  1. Do bulk builds with the existing defaults on a few platforms (e.g., NetBSD, macOS, Illumos, Linux)
  2. Rerun the bulk builds from scratch, this time with PKGSRC_SETENV=${SETENV} -i
  3. Compare before and after to see which package builds break
  4. Fix them
  5. Flip the switch to sanitize the environment by default