#!/bin/sh
#
# prerm script for the Debian GNU/Linux r-base-core package
# This version written by Dirk Eddelbuettel <edd@debian.org>   

set -e

#DEBHELPER#
    
case "$1" in
    remove|purge)
	# edd 03 Apr 2003  cf Section 10.1.2 of Debian Policy
	rmdir /usr/local/lib/R/site-library 2>/dev/null || true
	rmdir /usr/local/lib/R/ 2>/dev/null || true
    ;;
    upgrade|abort-upgrade|abort-remove|abort-deconfigure)
    ;;
    *)
	echo "prerm called with unknown argument \`$1'" >&2
    ;;
esac
