Browse Source

migemo-0.40-4

git-svn-id: http://trac.vinelinux.org/repos/projects/specs@7186 ec354946-7b23-47d6-9f5a-488ba84defc7
iwaim 11 years ago
parent
commit
9090ed2126
4 changed files with 158 additions and 0 deletions
  1. 17 0
      m/migemo/migemo-init.el
  2. 78 0
      m/migemo/migemo-install.sh
  3. 38 0
      m/migemo/migemo-remove.sh
  4. 25 0
      m/migemo/vine-default-migemo.el

+ 17 - 0
m/migemo/migemo-init.el

@@ -0,0 +1,17 @@
+;;
+;; migemo-init.el
+;;
+;; 	for Vine Linux with emacsen-common
+;; 	IWAI, Masaharu <iwai@alib.jp>
+
+(defcustom vine-default-migemo t
+  "A boolean for vine-default-migemo"
+  :type 'boolean)
+
+(add-hook 'vine-default-setup-hook
+	  (lambda()
+	    (when vine-default-migemo
+	      (message "Loading vine-migemo ...")
+	      (require 'vine-default-migemo))))
+
+;;; end of file

+ 78 - 0
m/migemo/migemo-install.sh

@@ -0,0 +1,78 @@
+#! /bin/sh -e
+#  /usr/lib/emacsen-common/packages/install/foo
+# [ This particular script hasn't been tested, so be careful. ]
+
+set -e
+
+FLAVOR=$1
+PACKAGE="migemo"
+
+if [ "X${FLAVOR}" = "X" ]; then
+    echo Need argument to determin FLAVOR of emacs;
+    exit 1
+fi
+
+if [ "X${PACKAGE}" = "X" ]; then
+    echo Internal error: need package name;
+    exit 1;
+fi
+
+ELDIR=/usr/share/emacs/site-lisp/${PACKAGE}
+ELCDIR=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
+
+STARTDIR=/etc/${FLAVOR}/site-start.d
+STARTFILE="${PACKAGE}-init.el";
+
+SITELISP=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
+
+EFLAGS="-batch -q"
+COMPILE="-batch -q -f batch-byte-compile"
+
+case "${FLAVOR}" in
+	emacs|emacs19)
+	;;
+	*)
+
+	echo -n "install/${PACKAGE}: Byte-compiling for ${FLAVOR} ..."
+#	if [ "${FLAVOR}" = "mule2" ]; then
+#		if [ ! -d /usr/share/emacs/site-lisp/clime ]; then
+#		echo " exited."
+#		echo "W: Please install \`clime' package for mule2." ;
+#		exit 0;
+#		fi
+#	else
+#		if [ ! -d /usr/share/emacs/site-lisp/flim ]; then
+#		echo " exited."
+#		echo "W: Please install \`flim' package for ${FLAVOR}." ;
+#		exit 0;
+#		fi
+#	fi
+
+	rm -rf ${ELCDIR}
+    install -m 755 -d ${ELCDIR}
+
+    # Byte compile
+    (cd ${ELDIR}
+#	make EMACS=${FLAVOR} .el.elc >  ${ELCDIR}/CompilationLog 2>&1
+### stop running aclocal: 0.40-0vl6
+        touch aclocal.m4 Makefile.in configure
+        ./configure --srcdir=. --with-emacs=${FLAVOR} \
+        --with-lispdir=/usr/share/${FLAVOR}/site-lisp/${PACKAGE} \
+                              >> ${ELCDIR}/CompilationLog 2>&1
+	make install-lispLISP >> ${ELCDIR}/CompilationLog 2>&1
+	make clean-lisp       >> ${ELCDIR}/CompilationLog 2>&1
+	rm -f aclocal.m4 config.cache config.log
+	rm -f ${ELCDIR}/*.el
+    )
+
+	gzip -9 ${ELCDIR}/CompilationLog
+
+	install -p -m644 ${ELDIR}/vine-default-${PACKAGE}.el ${ELCDIR}
+	install -p -m644 ${ELDIR}/${STARTFILE} ${STARTDIR}/90${STARTFILE}
+
+	echo " done."
+	;;
+esac
+
+exit 0;
+

+ 38 - 0
m/migemo/migemo-remove.sh

@@ -0,0 +1,38 @@
+#!/bin/sh
+# /usr/lib/emacsen-common/packages/remove/foo
+# [ This particular script hasn't been tested either, so be careful. ]
+set -e
+
+FLAVOR=$1
+PACKAGE="migemo"
+
+if [ "X${FLAVOR}" = "X" ]; then
+    echo Need argument to determin FLAVOR of emacs;
+    exit 1
+fi
+
+if [ "X${PACKAGE}" = "X" ]; then
+    echo Internal error: need package name;
+    exit 1;
+fi
+
+ELDIR=/usr/share/emacs/site-lisp/${PACKAGE}
+ELCDIR=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
+STARTDIR=/etc/${FLAVOR}/site-start.d
+STARTFILE="${PACKAGE}-init.el";
+
+SITELISP=/usr/share/${FLAVOR}/site-lisp
+
+case "${FLAVOR}" in
+	emacs|emacs19)
+	;;
+	*)
+	echo -n "remove/${PACKAGE}: Handling removal of emacsen flavor ${FLAVOR} ..."
+	rm -rf ${ELCDIR}
+	rm -f ${STARTDIR}/90${STARTFILE}*
+	echo " done."
+	;;
+    *)
+esac
+
+exit 0;

+ 25 - 0
m/migemo/vine-default-migemo.el

@@ -0,0 +1,25 @@
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;  -*- coding: utf-8-unix -*-
+;;  FSF Emacs 23 用 Vine Linux Migemo 設定
+;;    IWAI, Masaharu <iwai@alib.jp>
+;;	$Id$
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; Migemo の設定
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+;; Migemoのロード
+(load "migemo")
+
+;; Emacs 側でのキャッシュを有効にする
+;(setq migemo-use-pattern-alist t)
+;(setq migemo-use-frequent-pattern-alist t)
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+(provide 'vine-default-migemo)
+
+;; Local Variables:
+;; mode: emacs-lisp
+;; End: