# building environment



## mk (Jun 22, 2011)

Hi, I set these environment variables

```
PORTSDIR /home/user/tsite/ports/
PACKAGES /home/user/tsite/ports/packages/
PREFIX /home/user/tsite/local/
PORT_DBDIR /hone/user/tsite/db/ports/
```
I fetch ports with a modified copy of /etc/portsnap.conf, then perform installation of very simple and small programs - arping, portcheck, bandwidthd. 

While arping fails to install, what I observe is that it needs the root password to register installation, yet the db/ports directory is owned by the *user* not root. And when I type the root password, the installed port has an entry in /var/db/ports/[portname] instead of $PORT_DBDIR which is empty.

How to enforce the use of $PORT_DBDIR and not /var/db/ports of the host?

And yes, no jails.


----------



## SirDice (Jun 22, 2011)

The package needs to be registered in /var/db/pkg/.


----------



## mk (Jun 22, 2011)

I made the change, it starts writing in $PORT_DBDIR but it still asks for the root password for the creation of portname and portname/options.


----------



## Kitche (Jun 24, 2011)

Lookk up ports-mgmt/tinderbox it's what you want


----------

