1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/debian/emacsen-install.ex Sat Mar 01 15:21:12 2014 +0100
1.3 @@ -0,0 +1,47 @@
1.4 +#! /bin/sh -e
1.5 +# /usr/lib/emacsen-common/packages/install/libcalendaring
1.6 +
1.7 +# Written by Jim Van Zandt <jrv@debian.org>, borrowing heavily
1.8 +# from the install scripts for gettext by Santiago Vila
1.9 +# <sanvila@ctv.es> and octave by Dirk Eddelbuettel <edd@debian.org>.
1.10 +
1.11 +FLAVOR=$1
1.12 +PACKAGE=libcalendaring
1.13 +
1.14 +if [ ${FLAVOR} = emacs ]; then exit 0; fi
1.15 +
1.16 +echo install/${PACKAGE}: Handling install for emacsen flavor ${FLAVOR}
1.17 +
1.18 +#FLAVORTEST=`echo $FLAVOR | cut -c-6`
1.19 +#if [ ${FLAVORTEST} = xemacs ] ; then
1.20 +# SITEFLAG="-no-site-file"
1.21 +#else
1.22 +# SITEFLAG="--no-site-file"
1.23 +#fi
1.24 +FLAGS="${SITEFLAG} -q -batch -l path.el -f batch-byte-compile"
1.25 +
1.26 +ELDIR=/usr/share/emacs/site-lisp/${PACKAGE}
1.27 +ELCDIR=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
1.28 +ELRELDIR=../../../emacs/site-lisp/${PACKAGE}
1.29 +
1.30 +# Install-info-altdir does not actually exist.
1.31 +# Maybe somebody will write it.
1.32 +if test -x /usr/sbin/install-info-altdir; then
1.33 + echo install/${PACKAGE}: install Info links for ${FLAVOR}
1.34 + install-info-altdir --quiet --section "" "" --dirname=${FLAVOR} /usr/share/info/${PACKAGE}.info.gz
1.35 +fi
1.36 +
1.37 +install -m 755 -d ${ELCDIR}
1.38 +cd ${ELDIR}
1.39 +FILES=`echo *.el`
1.40 +cd ${ELCDIR}
1.41 +ln -sf ${ELRELDIR}/*.el .
1.42 +
1.43 +cat << EOF > path.el
1.44 +(debian-pkg-add-load-path-item ".")
1.45 +(setq byte-compile-warnings nil)
1.46 +EOF
1.47 +${FLAVOR} ${FLAGS} ${FILES}
1.48 +rm -f path.el
1.49 +
1.50 +exit 0