Debian Codegraph @

debian/emacsen-install

raw
1 #! /bin/sh -e
2 # /usr/lib/emacsen-common/packages/install/#PACKAGE#
3
4 # Written by Jim Van Zandt <[email protected]>, borrowing heavily
5 # from the install scripts for gettext by Santiago Vila
6 # <[email protected]> and octave by Dirk Eddelbuettel <[email protected]>.
7
8 FLAVOR=$1
9 PACKAGE="namazu"
10
11 if [ ${FLAVOR} = emacs ]; then exit 0; fi
12
13 echo install/${PACKAGE}: Handling install for emacsen flavor ${FLAVOR}
14
15 #FLAVORTEST=`echo $FLAVOR | cut -c-6`
16 #if [ ${FLAVORTEST} = xemacs ] ; then
17 # SITEFLAG="-no-site-file"
18 #else
19 # SITEFLAG="--no-site-file"
20 #fi
21 FLAGS="${SITEFLAG} -q -batch -l path.el -f batch-byte-compile"
22
23 ELDIR=/usr/share/emacs/site-lisp/${PACKAGE}
24 ELCDIR=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
25 ELRELDIR=../../../emacs/site-lisp/${PACKAGE}
26
27 # Install-info-altdir does not actually exist.
28 # Maybe somebody will write it.
29 if test -x /usr/sbin/install-info-altdir; then
30 echo install/${PACKAGE}: install Info links for ${FLAVOR}
31 install-info-altdir --quiet --section "" "" --dirname=${FLAVOR} /usr/share/info/${PACKAGE}.info.gz
32 fi
33
34 install -m 755 -d ${ELCDIR}
35 cd ${ELDIR}
36 FILES=`echo *.el`
37 cd ${ELCDIR}
38 ln -sf ${ELRELDIR}/*.el .
39
40 cat << EOF > path.el
41 (debian-pkg-add-load-path-item ".")
42 (setq byte-compile-warnings nil)
43 EOF
44 ${FLAVOR} ${FLAGS} ${FILES}
45 rm -f path.el
46
47 exit 0