Код: Выделить всё
use FreeBSD::Src;
#creates a new FreeBSD::Src object and build stuff in /tm[/obj and a kernel config
#named whatever.
my $src=FreeBSD::Src->new({obj=>"/tmp/obj", kernel=>"whatever"});
#builds and installs the kernel and world
$src->makeBuildKernel;
$src->makeInstallKernel;
$src->makeBuildWorld;
$src->makeInstallWorld;
