rd-mode-install.sh 831 B

123456789101112131415161718192021222324252627282930313233343536
  1. #! /bin/sh -e
  2. # /usr/lib/emacsen-common/packages/install/rd-mode
  3. FLAVOR=$1
  4. PACKAGE=rd-mode
  5. FLAGS="${SITEFLAG} -q -batch -f batch-byte-compile"
  6. ELDIR="/usr/share/emacs/site-lisp/${PACKAGE}"
  7. ELCDIR="/usr/share/${FLAVOR}/site-lisp/${PACKAGE}"
  8. STARTDIR=/etc/${FLAVOR}/site-start.d
  9. STARTFILE="${PACKAGE}-init.el"
  10. SOURCES="rd-mode.el"
  11. case "${FLAVOR}" in
  12. emacs)
  13. ;;
  14. *)
  15. echo -n "install/${PACKAGE}: Byte-compiling for ${FLAVOR} ..."
  16. install -m 755 -d ${ELCDIR}
  17. cd ${ELDIR}
  18. cp ${SOURCES} ${ELCDIR}
  19. cp vine-default-${PACKAGE}.el ${ELCDIR}
  20. FILES="${SOURCES}"
  21. cd ${ELCDIR}
  22. ${FLAVOR} ${FLAGS} ${FILES} > ${ELCDIR}/CompilationLog 2>&1
  23. rm -f ${SOURCES}
  24. gzip -9 ${ELCDIR}/CompilationLog
  25. ln -sf ${ELDIR}/${STARTFILE} ${STARTDIR}/95${STARTFILE};
  26. echo " done."
  27. ;;
  28. esac
  29. exit 0 ;