#!/bin/sh

. ./_blfsset.sh

APPNAME=TakaoFonts
VER=00303.01
TARGET=${APPNAME}_$VER
TARGET2=${APPNAME}-$VER
TARGETBALL=$DLD/$TARGET.tar.xz
TARGETDIR=$TARGET

echo $TARGET

. $WRK/_checkRequired.sh fontconfig
. $WRK/_checkOptions.sh  ""
. $WRK/_checkTarball.sh
. $WRK/_checkExit.sh "$1" || exit $?

cd $SRC
RemoveSrcDir
Extract

TimeStart

cd $TARGETDIR

install -d -m755 /usr/share/fonts/takao-gothic
install -d -m755 /usr/share/fonts/takao-mincho

Installing
porg -lp $TARGET2 "\
install -v -m644 Takao*Gothic.ttf /usr/share/fonts/takao-gothic" \
	1> $LOG/$TARGET.1_install.log 2>&1 || exit 1
 
porg -lp+ $TARGET2 "\
install -v -m644 Takao*Mincho.ttf /usr/share/fonts/takao-mincho" \
	1>> $LOG/$TARGET.1_install.log 2>&1 || exit 1

fc-cache -v /usr/share/fonts/takao-gothic \
	1>> $LOG/$TARGET.1_install.log 2>&1 || exit 1
fc-cache -v /usr/share/fonts/takao-mincho \
	1>> $LOG/$TARGET.1_install.log 2>&1 || exit 1

TimeEnd

cd ..
RemoveSrcDir
PorgingDone $TARGET2

