Commit | Line | Data |
---|---|---|
805e021f CE |
1 | # Copyright 2000, International Business Machines Corporation and others. |
2 | # All Rights Reserved. | |
3 | # | |
4 | # This software has been released under the terms of the IBM Public | |
5 | # License. For details, see the LICENSE file in the top-level source | |
6 | # directory or online at http://www.openafs.org/dl/license10.html | |
7 | ||
8 | # An InstallGuide for dynamic kernel loaded libraries | |
9 | # For Sun systems running Solaris 5.x | |
10 | # | |
11 | ||
12 | sub modkernel { | |
13 | &ErrorsAreFatal(1); | |
14 | &CreateDir("/usr/vice/etc/modload"); | |
15 | &ErrorsAreFatal(0); | |
16 | ||
17 | if ($Configuration{"NFSEXTENSIONS"}) { | |
18 | &Copy("root.client/usr/vice/etc/modload/libafs.o","/kernel/fs/afs"); } | |
19 | else { | |
20 | &Copy("root.client/usr/vice/etc/modload/libafs.nonfs.o", | |
21 | "/kernel/fs/afs"); } | |
22 | ||
23 | &Copy("root.client/usr/vice/etc/modload/afs.rc", "/usr/vice/etc/modload"); | |
24 | &Copy("root.client/usr/vice/etc/afsd", "/usr/vice/etc"); | |
25 | &Chmod(0744, "/usr/vice/etc/afsd"); | |
26 | ||
27 | &Copy("bin/fs", "/usr/vice/etc/fs"); | |
28 | # add the afs line to /etc/name_to_sysnum | |
29 | &ErrorsAreFatal(1); | |
30 | $File="/etc/name_to_sysnum"; | |
31 | ||
32 | &Patch::Verbose if ($InstallVerbose); | |
33 | &Patch::FileOpen($File); | |
34 | ||
35 | $SearchString = <<"xxENDxx"; | |
36 | fstatvfs 104 | |
37 | nfs 106 | |
38 | xxENDxx | |
39 | ||
40 | $NewString = <<"xxENDxx"; | |
41 | fstatvfs 104 | |
42 | afs 105 | |
43 | nfs 106 | |
44 | xxENDxx | |
45 | ||
46 | if (!&Patch::Patch($File, [[0, "Replace", $SearchString, $NewString]])) { | |
47 | &ErrorMsg ("Did not succeed with patch", $File); | |
48 | } | |
49 | ||
50 | } |