#
# bldkernel
#
# An InstallGuide for installing static AFS kernel libraries
# For SUN systems running SunOS 4.x
#

sub bldkernel {
my($arch);
&ErrorsAreFatal(1);
$arch = `/bin/uname -m`;
chop $arch;
&ErrorMsg("Couldn't get sun kernel architecture type with","/bin/uname -m") 
 unless ($arch =~ /sun/);
&ErrorsAreFatal(0);

if ($Configuration{"NFSEXTENSIONS"}) {
  &Copy("root.client/bin/libafs.a",  "/usr/sys/$arch/OBJ/libafs.o");  }
else {
  &Copy("root.client/bin/libafs.nonfs.a",  "/usr/sys/$arch/OBJ/libafs.o");  }
&VPrint("Running ranlib on library");
system("ranlib /usr/sys/$arch/OBJ/libafs.o");

&Copy("root.client/usr/vice/etc/afsd", "/usr/vice/etc");
&Chmod(0744, "/usr/vice/etc/afsd");
&Copy("bin/fs", "/usr/vice/etc/fs");
}
