PREIN
/bin/sh
if [ $1 -gt 1 ]; then
# Upgrade => deregister old extension
unopkg remove --shared `grep -s identifier /usr/lib/openoffice.org/extensions/pdfimport.oxt/description.xml | cut -d '"' -f 2` > /dev/null 2>&1 || :
fi
PREUN
/bin/sh
if [ $1 -eq 0 ]; then
# not upgrading => deregister
unopkg remove --shared `grep -s identifier /usr/lib/openoffice.org/extensions/pdfimport.oxt/description.xml | cut -d '"' -f 2` > /dev/null 2>&1 || :
fi
POSTIN
/bin/sh
# register extension
unopkg add --shared --force --link /usr/lib/openoffice.org/extensions/pdfimport.oxt > /dev/null 2>&1 || :
POSTUN
/bin/sh
# clear disk cache
unopkg list --shared > /dev/null 2>&1 || :