#!/bin/sh -e
# /usr/lib/emacsen-common/packages/remove/emacspeak-ss

FLAVOR=$1
PACKAGE=emacspeak-ss

if [ ${FLAVOR} = emacs ]; then exit 0; fi

echo remove/${PACKAGE}: purging speech servers for ${FLAVOR}

ELCDIR=/usr/share/${FLAVOR}/site-lisp/emacspeak
SERVERS="doubletalk accent braillenspeak apollo ciber pchablado"
BLURBS="accent-ss.blurb apollo-ss.blurb braille-lite-ss.blurb braillenspeak-ss.blurb ciber232.blurb ciber232plus.blurb dtlt-ss.blurb dtpc-ss.blurb hablado.blurb lite-ss.blurb tns-ss.blurb"

if [ -d ${ELCDIR}/servers ]; then
    cd ${ELCDIR}/servers; rm -f ${SERVERS}
fi
if [ -d ${ELCDIR}/blurbs ]; then
    cd ${ELCDIR}/blurbs; rm -f ${BLURBS}
fi

exit 0
