reran autoconf
[Samba.git] / source / script / installbin.sh
blob77bded6420f18f4cb3bfc98d06ed58453e8710b6
1 #!/bin/sh
3 INSTALLPERMS=$1
4 BASEDIR=$2
5 BINDIR=$3
6 LIBDIR=$4
7 VARDIR=$5
8 shift
9 shift
10 shift
11 shift
12 shift
14 for d in $BASEDIR $BINDIR $LIBDIR $VARDIR $BASEDIR/private; do
15 if [ ! -d $d ]; then
16 mkdir $d
17 if [ ! -d $d ]; then
18 echo Failed to make directory $d
19 exit 1
22 done
25 for p in $*; do
26 p2=`basename $p`
27 echo Installing $p as $BINDIR/$p2
28 if [ -f $BINDIR/$p2 ]; then
29 rm -f $BINDIR/$p2.old
30 mv $BINDIR/$p2 $BINDIR/$p2.old
32 cp $p $BINDIR/
33 chmod $INSTALLPERMS $BINDIR/$p2
35 # this is a special case, mount needs this in a specific location
36 if [ $p2 = smbmount ]; then
37 ln -sf $BINDIR/$p2 /sbin/mount.smbfs
39 done
42 cat << EOF
43 ======================================================================
44 The binaries are installed. You may restore the old binaries (if there
45 were any) using the command "make revert". You may uninstall the binaries
46 using the command "make uninstallbin" or "make uninstall" to uninstall
47 binaries, man pages and shell scripts.
48 ======================================================================
49 EOF
51 exit 0