Commit 1279f176 authored by Georges Khaznadar's avatar Georges Khaznadar

improved the emacsen install and remove files to prevent installation with xemacs

parent 85224e0e
......@@ -11,6 +11,9 @@ supercollider (1:3.10.0+repack-1) unstable; urgency=medium
* delete quilt patch 'supernova-i686-march-flag.patch', which defeats
the configuration step.
* modified the path to a documentation file for installation
* modified emacsen configuration files to fit the patterns found
with ELPA. This prevents the installation with xemacs and emacs <= 23.
Closes: #916858
-- Georges Khaznadar <georgesk@debian.org> Mon, 24 Dec 2018 16:31:59 +0100
......
......@@ -8,38 +8,51 @@
FLAVOR=$1
PACKAGE=SuperCollider
if [ ${FLAVOR} = emacs ]; then exit 0; fi
echo install/${PACKAGE}: Handling install for emacsen flavor ${FLAVOR}
#FLAVORTEST=`echo $FLAVOR | cut -c-6`
#if [ ${FLAVORTEST} = xemacs ] ; then
# SITEFLAG="-no-site-file"
#else
# SITEFLAG="--no-site-file"
#fi
FLAGS="${SITEFLAG} -q -batch -l path.el -f batch-byte-compile"
ELDIR=/usr/share/emacs/site-lisp/${PACKAGE}
ELCDIR=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
# Install-info-altdir does not actually exist.
# Maybe somebody will write it.
if test -x /usr/sbin/install-info-altdir; then
echo install/${PACKAGE}: install Info links for ${FLAVOR}
install-info-altdir --quiet --section "" "" --dirname=${FLAVOR} /usr/share/info/${PACKAGE}.info.gz
fi
install -m 755 -d ${ELCDIR}
cd ${ELDIR}
FILES=`echo *.el`
cp ${FILES} ${ELCDIR}
cd ${ELCDIR}
cat << EOF > path.el
case $FLAVOR in
emacs)
exit 0
;;
emacs2[0123]*)
echo install/${PACKAGE}: Skipping obsolete emacs ${FLAVOR}
exit 0
;;
xemacs*)
echo install/${PACKAGE}: Skipping unsupported emacs ${FLAVOR}
exit 0
;;
*)
echo install/${PACKAGE}: Handling install of emacsen flavor ${FLAVOR}
#FLAVORTEST=`echo $FLAVOR | cut -c-6`
#if [ ${FLAVORTEST} = xemacs ] ; then
# SITEFLAG="-no-site-file"
#else
# SITEFLAG="--no-site-file"
#fi
FLAGS="${SITEFLAG} -q -batch -l path.el -f batch-byte-compile"
ELDIR=/usr/share/emacs/site-lisp/${PACKAGE}
ELCDIR=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
# Install-info-altdir does not actually exist.
# Maybe somebody will write it.
if test -x /usr/sbin/install-info-altdir; then
echo install/${PACKAGE}: install Info links for ${FLAVOR}
install-info-altdir --quiet --section "" "" --dirname=${FLAVOR} /usr/share/info/${PACKAGE}.info.gz
fi
install -m 755 -d ${ELCDIR}
cd ${ELDIR}
FILES=`echo *.el`
cp ${FILES} ${ELCDIR}
cd ${ELCDIR}
cat << EOF > path.el
(setq load-path (cons "." load-path) byte-compile-warnings nil)
EOF
${FLAVOR} ${FLAGS} ${FILES}
rm -f *.el path.el
${FLAVOR} ${FLAGS} ${FILES}
rm -f *.el path.el
exit 0
esac
exit 0
......@@ -4,12 +4,25 @@
FLAVOR=$1
PACKAGE=SuperCollider
if [ ${FLAVOR} != emacs ]; then
if test -x /usr/sbin/install-info-altdir; then
echo remove/${PACKAGE}: removing Info links for ${FLAVOR}
install-info-altdir --quiet --remove --dirname=${FLAVOR} /usr/share/info/supercollider.info.gz
fi
echo remove/${PACKAGE}: purging byte-compiled files for ${FLAVOR}
rm -rf /usr/share/${FLAVOR}/site-lisp/${PACKAGE}
fi
case $FLAVOR in
emacs)
exit 0
;;
emacs2[0123]*)
echo remove/${PACKAGE}: Skipping obsolete emacs ${FLAVOUR}
exit 0
;;
xemacs*)
echo remove/${PACKAGE}: Skipping unsupported emacs ${FLAVOUR}
exit 0
;;
*)
if test -x /usr/sbin/install-info-altdir; then
echo remove/${PACKAGE}: removing Info links for ${FLAVOR}
install-info-altdir --quiet --remove --dirname=${FLAVOR} /usr/share/info/supercollider.info.gz
fi
echo remove/${PACKAGE}: purging byte-compiled files for ${FLAVOR}
rm -rf /usr/share/${FLAVOR}/site-lisp/${PACKAGE}
esac
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment