#!/bin/sh
# $Id: rh9_msfonts.sh,v 1.1 2003-04-30 15:43:08 poonlap Exp $
if [ -z $TE_DIR ]; then
	TE_DIR=`pwd`
fi
source $TE_DIR/te.conf

if [ ! -f /usr/bin/rpmbuild ];then
	echo "Can not find rpmbuild command."
	echo "Please install rpm-build package from RedHat CD"
	exit -1
fi

cd $TE_DIR/downloads
if [ $tahoma_only == 1 ]; then
	cp $TE_DIR/files/msttcorefonts-1.3-4.spec $TE_DIR/downloads
else
	wget -nd http://unc.dl.sourceforge.net/sourceforge/corefonts/msttcorefonts-1.3-4.spec
fi
rpm -Uhv http://flow.dl.sourceforge.net/sourceforge/corefonts/cabextract-0.6-1.i386.rpm
cd /usr/src/redhat/SPECS
cp $TE_DIR/downloads/msttcorefonts-1.3-4.spec .
rpmbuild -bb msttcorefonts-1.3-4.spec
rpm -ihv /usr/src/redhat/RPMS/noarch/msttcorefonts-1.3-4.noarch.rpm
fc-cache -fv
cd $TE_DIR

