#!/bin/bash


init 3
cd /tmp/
wget http://support.elpos.co.il/slepos/possp4.tgz 
tar -zpPxvf ./possp4.tgz 
sync
tar -zpPxvf /opt/appsrv/cfg/gtmpos.tgz
tar -zpPxvf /opt/appsrv/cfg/elpos.tgz
tar -zpPxvf /opt/appsrv/cfg/systar.tgz

#install ttf microsoft fonts 
tar -zpPxvf /opt/appsrv/cfg/ttffonts.tgz
/usr/sbin/fonts-config
##########

#tar -zpPxvf /pos/cfg/systar.tgz 
#tar -zpPxvf /pos/cfg/elpos.tgz
#tar -zpPxvf /pos/cfg/tz.tgz
## for msm shared lim mjsp
ln -s /lib64/libncurses.so.5 /lib64/libtinfo.so.5
ldconfig
##disable ipv6 
#echo "alias net-pf-10 off"  >> /etc/modprobe.conf.local
#echo "alias ipv6 off"  >> /etc/modprobe.conf.local
###
########## xdot can control and move windows on X ###########
rpm -ivh /opt/appsrv/cfg/rpm/xdotool-2.2012+git.20130201.65cb0b1-2.1.x86_64.rpm

#rpm -ivh /pos/cfg/rpm/cabextract*
#rpm -ivh /pos/cfg/rpm/fetchmsttfonts*
#sh /var/adm/update-scripts/fetchmsttfonts-11.0-2.3-1

chkconfig -s SuSEfirewall2_setup off
chkconfig -s SuSEfirewall2_init off
chkconfig -s alsasound off
chkconfig -s auditd off
chkconfig -s bluez-coldplug off
chkconfig -s cups off
chkconfig -s network-remotefs off
chkconfig -s nfs off
chkconfig -s  postfix off
chkconfig -s smbfs off

#chkconfig -s tomcat6 on 
chkconfig -s msmserver on 

#
#	rpm -ivh /opt/appsrv/cfg/rpm/kernel-3.0.101EETI_170316_63_default-1.x86_64.rpm
	rpm -ivh /opt/appsrv/cfg/rpm/kernel-3.19.8ELPOS_63_default-1.x86_64.rpm
	tar -zpPxvf /opt/appsrv/cfg/wintec.tgz 
	/usr/sbin/grub-install
if  /usr/sbin/lsusb|grep "D-WAV" > /dev/null ;then

        tar -zpPxvf /opt/appsrv/cfg/touchkit.tgz 
elif /usr/sbin/lsusb |grep 222a > /dev/null;then
	tar -zpPxvf /opt/appsrv/cfg/ILITEK_TOUCH.tgz
	rpm -ivh /opt/appsrv/cfg/rpm/xinput_calibrator-1361041250-20.2-x86_64.rpm
	 
else
	tar -zpPxvf /opt/appsrv/cfg/elotch.tgz 
fi


