#!/bin/sh

PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/X11R6/bin
export PATH

if [ "$2" = "POST-INSTALL" ]; then
    echo "Running fc-cache to build fontconfig cache..."
    fc-cache -f -v
elif [ "$2" = "DEINSTALL" ]; then
    find /usr/X11R6/lib/X11/fonts/ -name fonts.cache-1 -delete
    find /usr/X11R6/lib/X11/fonts/ -name fonts.cache-1 -delete
fi
