INSTALL_DEST=/Library/Frameworks
INSTALL_BASE=/
+
if [ ${INSTALL_BASE} = / ]; then
- INSTALL_BIN=/usr/bin
-else
- INSTALL_BIN=${INSTALL_BASE}/bin
+ INSTALL_BASE=/usr
fi
+INSTALL_BIN=${INSTALL_BASE}/bin
+INSTALL_MAN1=${INSTALL_BASE}/share/man/man1
+INSTALL_HTML=${INSTALL_BASE}/share/doc
if [ ! -x ${INSTALL_DEST}/GHC.framework ]; then
echo "${INSTALL_DEST}/GHC.framework does not exit"
fi
echo "Removing symbolic links into GHC.framework"
-for thisfile in `ls ${INSTALL_BIN}`; do
- if ls -l ${INSTALL_BIN}/${thisfile} | grep -q GHC.framework/Versions; then
- rm -f ${INSTALL_BIN}/${thisfile}
+for thisfile in ${INSTALL_BIN}/*; do
+ if ls -l "${thisfile}" | grep -q GHC.framework/Versions; then
+ rm -f "${thisfile}"
+ fi
+done
+for thisfile in ${INSTALL_MAN1}/*; do
+ if ls -l "${thisfile}" | grep -q GHC.framework/Versions; then
+ rm -f "${thisfile}"
+ fi
+done
+for thisfile in ${INSTALL_HTML}/*; do
+ if ls -l "${thisfile}" | grep -q GHC.framework/Versions; then
+ rm -f "${thisfile}"
fi
done