/[gentoo-x86]/eclass/cannadic.eclass
Gentoo

Diff of /eclass/cannadic.eclass

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.3 Revision 1.4
1# Copyright 1999-2003 Gentoo Technologies, Inc. 1# Copyright 1999-2003 Gentoo Technologies, Inc.
2# Distributed under the terms of the GNU General Public License v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/eclass/cannadic.eclass,v 1.3 2004/02/17 07:36:54 mr_bones_ Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/cannadic.eclass,v 1.4 2004/05/05 11:41:24 usata Exp $
4# 4#
5# Author: Mamoru KOMACHI <usata@gentoo.org> 5# Author: Mamoru KOMACHI <usata@gentoo.org>
6# 6#
7# The cannadic eclass is used for installation and setup of Canna 7# The cannadic eclass is used for installation and setup of Canna
8# compatible dictionaries within the Portage system. 8# compatible dictionaries within the Portage system.
18DESCRIPTION="Based on the $ECLASS eclass" 18DESCRIPTION="Based on the $ECLASS eclass"
19HOMEPAGE="http://canna.sourceforge.jp/" # you need to change this! 19HOMEPAGE="http://canna.sourceforge.jp/" # you need to change this!
20SRC_URI="mirror://gentoo/${P}.tar.gz" 20SRC_URI="mirror://gentoo/${P}.tar.gz"
21 21
22LICENSE="public-domain" 22LICENSE="public-domain"
23# I added all keywords form /usr/portage/profiles/keyword.desc atm since
24# cannadic source is basically plain text and will run on any platform
25KEYWORDS="~x86 ~ppc ~sparc ~alpha ~mips ~hpps ~amd64"
26SLOT="0" 23SLOT="0"
27 24
28S="${WORKDIR}" 25S="${WORKDIR}"
29 26
30DICSDIRFILE="$(echo ${FILESDIR}/*.dics.dir)" 27DICSDIRFILE="$(echo ${FILESDIR}/*.dics.dir)"
31CANNADICS="${CANNADICS}" # (optional) 28CANNADICS="${CANNADICS}" # (optional)
32DOCS="README*" 29DOCS="README*"
33 30
34# You don't need to modify these 31# You don't need to modify these
35#local cannadir dicsdir 32#local cannadir dicsdir
36cannadir="/var/lib/canna/dic/canna" 33cannadir="${ROOT}/var/lib/canna/dic/canna"
37dicsdir="/var/lib/canna/dic/dics.d" 34dicsdir="${ROOT}/var/lib/canna/dic/dics.d"
38 35
39# 36#
40# pkg_setup() : sets up cannadic dir 37# pkg_setup() : sets up cannadic dir
41pkg_setup() { 38pkg_setup() {
42 39
120pkg_postinst() { 117pkg_postinst() {
121 118
122 if [ -n "`use canna`" ] ; then 119 if [ -n "`use canna`" ] ; then
123 update-cannadic-dir 120 update-cannadic-dir
124 einfo 121 einfo
125 einfo "Please restart cannaserver to fit changes." 122 einfo "Please restart cannaserver to fit the changes."
126 einfo "and modify your config file (~/.canna) to enable dictionary." 123 einfo "You need to modify your config file (~/.canna) to enable dictionaries."
127 124
128 if [ -n "${CANNADICS}" ] ; then 125 if [ -n "${CANNADICS}" ] ; then
129 einfo "e.g) add $(for d in ${CANNADICS}; do 126 einfo "e.g) add $(for d in ${CANNADICS}; do
130 echo -n \"$d\"\ 127 echo -n \"$d\"\
131 done)to section use-dictionary()." 128 done)to section use-dictionary()."
132 einfo "For details, see documents under /usr/share/doc/${PF}" 129 einfo "For details, see documents under /usr/share/doc/${PF}"
133 fi 130 fi
134 131
132 ewarn "If you are upgrading from existing dictionary, you may need to recreate"
133 ewarn "user dictionary if you have one."
135 einfo 134 einfo
136 fi 135 fi
137} 136}
138 137
139# 138#

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.4

  ViewVC Help
Powered by ViewVC 1.1.20