87b0ef1a8ab9849bc37c088bead7373e4f0dd5de
[kai/samba.git] / source3 / script / installcp.sh
1 #!/bin/sh
2 srcdir=$1
3 LIBDIR=$2
4 CODEPAGEDIR=$3
5 BINDIR=$4
6
7 shift
8 shift
9 shift
10 shift
11
12 echo Installing codepage files in $CODEPAGEDIR
13 for d in $LIBDIR $CODEPAGEDIR; do
14 if [ ! -d $d ]; then
15 mkdir $d
16 if [ ! -d $d ]; then
17   echo Failed to make directory $d
18   exit 1
19 fi
20 fi
21 done
22
23 for p in $*; do
24  echo Creating codepage file $CODEPAGEDIR/codepage.$p
25  $BINDIR/make_smbcodepage c $p ${srcdir}/codepages/codepage_def.$p $CODEPAGEDIR/codepage.$p
26 done
27
28
29 cat << EOF
30 ======================================================================
31 The code pages have been installed. You may uninstall them using the
32 command "make uninstallcp" or make "uninstall" to uninstall binaries,
33 man pages, shell scripts and code pages.
34 ======================================================================
35 EOF
36
37 exit 0
38