source: projects/specs/trunk/h/howm/howm-install.sh @ 2432

Revision 2432, 1.1 KB checked in by munepi, 11 years ago (diff)

updated howm-vl.spec: supported vine-default

  • Property svn:executable set to *
Line 
1#!/bin/sh
2
3FLAVOR=$1
4PACKAGE="howm"
5
6if [ "X${FLAVOR}" = "X" ]; then
7    echo Need argument to determin FLAVOR of emacs;
8    exit 1
9fi
10
11if [ "X${PACKAGE}" = "X" ]; then
12    echo Internal error: need package name;
13    exit 1;
14fi
15
16ELDIR=${EPREFIX}/usr/share/emacs/site-lisp/${PACKAGE}
17ELCDIR=${EPREFIX}/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
18
19STARTDIR=/etc/${FLAVOR}/site-start.d
20STARTFILE="${PACKAGE}-init.el"
21
22SITELISP=/usr/share/${FLAVOR}/site-lisp
23
24COMPILE="-batch -q -f batch-byte-compile"
25
26case "${FLAVOR}" in
27    emacs)
28        ;;
29
30    *)
31        echo -n "install/${PACKAGE}: Byte-compiling for ${FLAVOR} ... "
32
33        rm -rf ${ELCDIR}
34        install -m 755 -d ${ELCDIR}
35        cp ${ELDIR}/*.el ${ELCDIR}
36
37        (
38            cd ${ELCDIR}
39            ${FLAVOR} ${COMPILE} *.el > ${ELCDIR}/CompilationLog 2>&1
40            rm *.el ${PACKAGE}-init.elc vine-default-${PACKAGE}.elc
41            install -p -m644 ${ELDIR}/vine-default-${PACKAGE}.el ${ELCDIR}
42        )
43
44        gzip -9 ${ELCDIR}/CompilationLog
45
46        if [ ! -d ${STARTDIR} ]; then
47            install -m 755 -d ${STARTDIR}
48        fi
49
50        ln -sf ${ELDIR}/${STARTFILE} ${STARTDIR}/50${STARTFILE};
51
52        echo " done."
53        ;;
54esac
55
56exit 0;
Note: See TracBrowser for help on using the repository browser.