Home______________________________________________________________________
Installer Note:
The svn command uses the tcp port 3690. It’s a mandatory requirement that your firewall rules allow the tcp port 3690 bi-directional access to the public Internet. Otherwise you will never be able to use svn to manage your ports collection.The svn command "IE; subversion" and the "pkgng" system is not delivered in the base FBSD system. You have to issue commands to install them. The base system does contain a small bootstrap program to download and install the "pkgng" application. After logging in as user "root", issue this command.
pkg
It issues a message "Reply Y to continue", to disable this, issue this commend
echo "ASSUME_ALWAYS_YES : yes" > /usr/local/etc/pkg.conf
To install the svn command subversion software issue this command
pkg install subversion
svn checkout svn://svn.freebsd.org/ports/head /usr/ports
or
portsnap fetch && portsnap extract
As the host administrator you have the option to choose what method you want to use to manage the software applications you want running on your host. You can choose the "port method" or the "package method". If you choose the "package method" there may be certain ports that for whatever reason they have to be compiled using the "port method". There is no mandatory requirement to populate your host's hard drive with port config files for the complete ports collection just to compile a few ports. All you really need is the port config files for the few ports you want to install minus their dependents.
Before a port will compile the /usr/ports filesystem needs to be populated with the basic things necessary for the "make" command to work. The following svn commands will populate the correct items.
Then execute the portsnap commands
portsnap fetch && portsnap extract
Now your ready to populate the /usr/ports filesystem with the make files for the port you need to compile. This can be done using svn or portsnap, staying with our apache22 example;
svn checkout svn://svn.freebsd.org/ports/head/www/apache22 /usr/ports/www/apache22
orportsnap extract www/apache22
Now your ready to to compile the apache22 port
cd /usr/ports/www/apache22 # change into directory
pkg install apache22 # install package and all dependents
pkg delete apache22 # delete apache package leaving behind dependents
make install clean # show config screen and compile the port
This last command will read the apache22 port config files; present you with a configuration option screen where you select the options you want, then download the apache22 distribution source file, compile and install it; and finish up by posting them as installed into the ports/package install history database. During this process you will see massive messages roll off your screen. There is no log to review later if there is a problem installing.
What I do to create a log of the install process; is start the script program to capture everything displayed to the console screen to a file for later review before issuing the ‘make install’ command. You do that like this:
script /root/apache22.install.rpt # you can name the file anything you want
exit # exit to stop script recording.
There are five package commands; two are specific to the package applications and the remaining apply to both the installed ports and installed packages. I am not going into details about the commands, because the man pages are pretty clear and easy to understand. Where xx is the port/package name.
pkg install xx # Fetch package from remote server and install it,
pkg_create xx # Create package out of port you have installed
pkg info xx # Create list of installed ports and packaged on your
# system from the installed software history database.
pkg delete xx # Delete installed port or package. Uses the name
# from the pkg info list display.
The 'man make' info is not the correct place to look for the 'make
sub-commands' for installing ports. Instead use the 'man ports' page instead. It's
very important that you understand that for the make command to be successful,
all the config files for all the dependencies and all their dependencies have to be
on your system’s hard drive in the correct directory tree layout. If you missed
downloading one of the sub-dependency's config files then the parent port does not
know it's missing and you will get compile errors for something missing.
You must cd into the directory of the port you want to install before
executing any of the following commands.
make install # Normal way to install port
make install clean # Remove the expanded source code,
# including the
dependencies at completion
make install distclean # Remove expanded source code &
# distribution files, including the
#
dependencies at completion
make all-depends-list # List all dependent ports
make fetch # This will fetch the distribution file
make fetch-recursive # This will fetch all the distribution
# files of the port and for all its
# dependencies.
make checksum-recursive # This will fetch all the distribution
# files of the port and for all its
# dependencies and checksums them.
This FreeBSD Install Guide is an public domain HOW-TO. This content may be reproduced, in any form or by any means, and used by all without permission in writing from the author.