You can install postgresql from the ports:
make install clean
The master user for the database on FreeBSD, in contrast to the master user on most Linux distributions, is called pgsql. Hence, you have to initialize the database using this user:
su - pgsql
initdb -D /usr/local/pgsql/data
postmaster -D /usr/local/pgsql/data
to finish the initialization. In order to start postgres on boot, you need to add
into your /etc/rc.conf.