File: migemo-el.emacsen-install

package info (click to toggle)
cmigemo 1:1.2+gh0.20140306-4
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 1,668 kB
  • ctags: 1,550
  • sloc: ansic: 2,617; lisp: 656; cs: 188; makefile: 174; sh: 172; cpp: 67; perl: 59; csh: 49
file content (39 lines) | stat: -rw-r--r-- 933 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#! /bin/sh
# /usr/lib/emacsen-common/packages/install/migemo-el

set -e
FLAVOR=$1
PACKAGE=migemo-el
case ${FLAVOR} in
    emacs|emacs23|emacs22|emacs21|emacs20|emacs19|mule2|xemacs*)
        exit 0
        ;;
    *)
        SITEFLAG="--no-site-file"
        ;;
esac
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}
ELCSTAMP=$ELCDIR/compile-stamp
if [ -f "$ELCSTAMP" ]; then
    echo "install/${PACKAGE}: already byte-compiled for $FLAVOR, skipped"
    exit 0
fi
echo "install/${PACKAGE}: Handling install for emacsen flavor ${FLAVOR}"
if [ ! -d "$ELCDIR" ]; then
    install -m 755 -d ${ELCDIR}
fi
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
touch "$ELCSTAMP"
exit 0