Table of Contents
FreeBSD Packages
Ports and Packages
A few notes regarding ports (source installs) and packages (binary installs):
- The versions may be different from each other (PHP 5.3.15 in ports, PHP 5.3.14 in packages)
- You can mix and match between the two (one source install, one binary), but it is not recommended
- FreeBSD by default will install packages that were built for the original release
- You must set
PACKAGESITE
environment variable yourself to get latest packages
Setup package repo
csh:
echo setenv PACKAGESITE ftp://ftp.freebsd.org/pub/FreeBSD/ports/i386/packages-9.0-stable/ >> ~/.cshrc source ~/.cshrc
bash:
echo PACKAGESITE=ftp://ftp.freebsd.org/pub/FreeBSD/ports/i386/packages-9.0-stable/ >> ~/.bashrc source ~/.bashrc
Install Base Packages
Now you're ready to install system packages. The first thing to do is install bsdadminscripts which will make managing packages
much simpler.
cd /usr/ports/sysutils/bsdadminscripts make clean install
The bsdadminsciripts package gets the package information directly from an FTP server, instead of relying on the data in ports. It also comes with a script pkg_upgrade which makes installation and upgrading much simpler.
Install some basics to get started:
pkg_upgrade -r `fetch -q -o - http://beandog.org/downloads/freebsd/packages/base` chsh -s /usr/local/bin/bash
Install Fixes
Upgrade FreeBSD to use devel/pkgconf instead of devel/pkg-config:
pkg_upgrade -r portmaster portmaster -o devel/pkgconf devel/pkg-config
Howto
List installed packages:
pkg_info
Download package list for parsing:
curl -s http://beandog.org/downloads/freebsd/packages/apache | cut -d "/" -f 2
Binaries
Install a package using the shortname, fex wget
. This will pull in all dependencies as well.
pkg_add -r wget