--- namazu-2.0.17.ebuild 25 Aug 2007 15:28:30 -0000 1.2 +++ namazu-2.0.17.ebuild 4 Oct 2007 20:29:31 -0000 @@ -2,6 +2,8 @@ # Distributed under the terms of the GNU General Public License v2 # $Header: /var/cvsroot/gentoo-x86/app-text/namazu/namazu-2.0.17.ebuild,v 1.2 2007/08/25 15:28:30 hattya Exp $ +inherit elisp-common + IUSE="chasen cjk emacs kakasi nls tk" DESCRIPTION="Namazu is a full-text search engine" @@ -15,6 +17,7 @@ DEPEND=">=dev-perl/File-MMagic-1.20 chasen? ( app-text/chasen ) cjk? ( app-i18n/nkf ) + emacs? ( virtual/emacs ) kakasi? ( dev-perl/Text-Kakasi ) nls? ( sys-devel/gettext ) tk? ( @@ -22,6 +25,8 @@ www-client/lynx )" +SITEFILE=50${PN}-gentoo.el + src_unpack() { unpack ${A} @@ -46,6 +51,10 @@ || die emake || die + if use emacs; then + cd lisp + elisp-comp {namazu,gnus-nmz-1}.el || die "elisp-comp failed" + fi } src_install () { @@ -61,11 +70,20 @@ doins etc/*.png if use emacs; then + elisp-install ${PN} lisp/{namazu,gnus-nmz-1}.el{,c} \ + || die "elisp-install failed" + elisp-site-file-install "${FILESDIR}/${SITEFILE}" \ + || die "elisp-site-file-install failed" + docinto lisp dodoc lisp/ChangeLog* - - insinto /usr/share/${PN}/lisp - doins lisp/*.el fi } +pkg_postinst() { + use emacs && elisp-site-regen +} + +pkg_postrm() { + use emacs && elisp-site-regen +}