Import Upstream version 1.8.5
[hcoop/debian/openafs.git] / src / packaging / HP-UX / scripts / openafs.configure
1 #!/bin/sh
2
3 echo "NOTE: Executing configure script."
4 #######
5 #
6 # (c) Copyright Hewlett-Packard Company 1994
7 #
8 ########
9
10 set -a
11 UTILS="/usr/lbin/sw/control_utils"
12 if [[ ! -f ${UTILS} ]]
13 then
14 echo "ERROR: Cannot find ${UTILS}"
15 exit 1
16 fi
17 . ${UTILS}
18
19 ############################################################################
20 # Set the global PATH to include OPENAFS software
21 ROOT=/usr/afs/
22 mod_pathfile -a P ${ROOT}bin
23
24 if [[ $? = 2 ]]
25 then
26 echo " /etc/PATH already contains the OPENAFS component."
27 else
28 echo "NOTE: Processes may need to be restarted to inherit"
29 echo " ${ROOT}/bin in their PATH."
30 fi
31
32 if [[ -f /usr/newconfig/sbin/init.d/afs ]]; then
33
34 # Copy from the original to /sbin/init.d
35
36 cp /usr/newconfig/sbin/init.d/afs /sbin/init.d
37 chmog 555 bin bin /sbin/init.d/afs
38
39 # Insert the sym links for startup and shutdown
40 # Assume possible upgrade! if the link is there, don't relink
41 #
42 if [[ ! -h /sbin/rc2.d/K800afs ]]; then
43 ln -s /sbin/init.d/afs /sbin/rc2.d/K800afs
44 fi
45 if [[ ! -h /sbin/rc2.d/S460afs ]]; then
46 ln -s /sbin/init.d/afs /sbin/rc2.d/S460afs
47 fi
48
49 fi