This chapter describes how to build AFS from source code.
Working on an AFS client machine, perform these steps to load the AFS source tree from the AFS Source Distribution.
Setting the -maxquota argument to 0 (zero) sets an unlimited quota on the volume, which enables you to copy all of the files into the volume without exceeding its quota. If you wish, you can set the volume's quota to a finite value after you complete the copying operation. At that point, use the vos examine command to determine how much space the volume is occupying. Then issue the fs setquota command to set a quota that is slightly larger.
# vos create <machine name> <partition name> src.afs -maxquota 0 # cd /afs/.cellname # mkdir afs # fs mkmount afs/src src.afs # vos release root.cell # fs checkvolumes
# cd /cdrom/src # cp -rp * /afs/.cellname/afs/src
The AFS distribution includes the washtool program for managing a hierarchy of software development projects. The program builds project trees for program editing, compilation, and installation.
# cd /afs/.cellname/afs
If creating a new volume:
# vos create <machine name> <partition name> sysname -maxquota 0 # fs mkmount sysname sysname
If not creating a new volume:
# mkdir sysname
# cd sysname # mkdir dest # mkdir dest/bin # mkdir obj
# cd /afs/.cellname/afs # ln -s @sys/dest dest # ln -s @sys/obj obj # ln -s . PARENT # ln -s src/Makefile Makefile
The following is an example directory listing for the /afs/.cellname/afs directory after completing the preceding steps. It includes two example system types.
lrwxr-xr-x admin 12 Jun 18 11:26 Makefile->src/Makefile lrwxr-xr-x admin 1 Jun 18 11:26 PARENT -> . lrwxr-xr-x admin 9 Jun 18 11:25 dest -> @sys/dest lrwxr-xr-x admin 8 Jun 18 11:25 obj -> @sys/obj drwxrwxrwx admin 4096 Jun 18 11:24 rcs drwxrwxrwx admin 2048 Jun 18 11:27 rs_aix42 drwxrwxrwx admin 2048 Jun 18 11:10 src drwxrwxrwx admin 2048 Jun 18 11:27 sun4x_56
# cd /afs/.cellname/afs/sysname # ln -s full_path_of_alternate_directory dest
If there is a volume that houses the AFS binaries for each system type (as recommended), the conventional location for the washtool binary is the /afs/cellname/sysname/usr/afsws/bin directory. Use the following instruction to copy it.
# cd /afs/cellname/sysname/usr/afsws/bin # cp washtool /afs/.cellname/afs/sysname/dest/bin
Otherwise, mount the (binary) AFS CD-ROM for this system type on the local /cdrom directory, and copy the washtool binary directly from it.
# cd /cdrom/sysname/bin # cp washtool /afs/.cellname/afs/sysname/dest/bin
If the washtool binary is not in the conventional directory (/afs/cellname/afs/sysname/dest/bin), set the WASHTOOL variable to the alternate full pathname of the binary.
# cd /afs/.cellname/afs # make SYS_NAME=sysname [WASHTOOL=alternate_washtool_directory] install