This commit was manufactured by cvs2svn to create tag
[Samba.git] / source / script / installbin.sh
blob22771ce5a075f2c6b89e3fababfe84633a12c1e4
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; 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 mv $BINDIR/$p2 $BINDIR/$p2.old
31 cp $p $BINDIR/
32 chmod $INSTALLPERMS $BINDIR/$p2
33 done
36 cat << EOF
37 ======================================================================
38 The binaries are installed. You may restore the old binaries (if there
39 were any) using the command "make revert". You may uninstall the binaries
40 using the command "make uninstallbin" or "make uninstall" to uninstall
41 binaries, man pages and shell scripts.
42 ======================================================================
43 EOF
45 exit 0