8.5 Customizing the Environment

It is possible to export environment variables on a global, per-Jail, per-PortsTree, and/or per-Build basis. This is done by creating a file named GLOBAL, jail.{JAIL}, portstree.{PORTSTREE}, or build.{BUILD} respectively, and placing it in ${pb}/scripts/etc/env/.

For example, if you want a particular Build (e.g. “8.2-Perl56”) to use Perl 5.6.2 instead of Perl 5.8.x, create a file named build.8.2-Perl56 in ${pb}/scripts/etc/env/ that contains the following:

PERL_VER=5.6.2
PERL_VERSION=5.6.2

Likewise, if you want to enable debugging for a particular PortsTree (e.g. "FreeBSD-debug"), create the following portstree.FreeBSD-debug in ${pb}/scripts/etc/env/:

CFLAGS="-O -g -pipe"
STRIP=