summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /app-i18n/canna/canna-3.7_p3-r1.ebuild
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'app-i18n/canna/canna-3.7_p3-r1.ebuild')
-rw-r--r--app-i18n/canna/canna-3.7_p3-r1.ebuild144
1 files changed, 144 insertions, 0 deletions
diff --git a/app-i18n/canna/canna-3.7_p3-r1.ebuild b/app-i18n/canna/canna-3.7_p3-r1.ebuild
new file mode 100644
index 000000000000..3855a8522d7f
--- /dev/null
+++ b/app-i18n/canna/canna-3.7_p3-r1.ebuild
@@ -0,0 +1,144 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+inherit cannadic eutils multilib
+
+MY_P="Canna${PV//./}"
+MY_P="${MY_P/_/}"
+
+DESCRIPTION="A client-server based Kana-Kanji conversion system"
+HOMEPAGE="http://canna.sourceforge.jp/"
+SRC_URI="mirror://sourceforge.jp/canna/9565/${MY_P}.tar.bz2"
+
+LICENSE="MIT GPL-2"
+SLOT="0"
+KEYWORDS="alpha amd64 hppa ia64 ppc ppc64 sparc x86"
+IUSE=""
+
+DEPEND=">=sys-apps/sed-4
+ x11-misc/gccmakedep
+ x11-misc/imake"
+RDEPEND=""
+
+S="${WORKDIR}/${MY_P}"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+
+ find . -name '*.man' -o -name '*.jmn' | xargs sed -i.bak -e 's/1M/8/g' || die
+ sed -e "s%@cannapkgver@%${PF}%" \
+ "${FILESDIR}"/${PN}-3.7-gentoo.diff.in > "${T}"/${PF}-gentoo.diff || die
+ epatch "${T}"/${PF}-gentoo.diff
+
+ # bug #248723
+ epatch "${FILESDIR}"/${P}-strip.patch
+
+ # Multilib-strict fix for amd64
+ sed -i -e "s:\(DefLibCannaDir.*\)/lib:\1/$(get_libdir):g" Canna.conf* || die
+ # fix deprecated sort syntax
+ sed -e 's:^\(sortcmd=\".* -s\).*$:\1 -k 1,1\":' \
+ -i cmd/mkbindic/mkbindic.cpp || die
+
+ cd "${S}"/dic/phono
+ epatch "${FILESDIR}"/${PN}-kpdef-gentoo.diff
+
+}
+
+src_compile() {
+ xmkmf || die
+
+ #make libCannaDir=../lib/canna canna || die
+ # bug #279706
+ emake -j1 CDEBUGFLAGS="${CFLAGS}" canna || die
+
+ #if use doc ; then
+ # einfo "Compiling DVI, PS (and PDF) document"
+ # cd doc/man/guide/tex
+ # xmkmf || die
+ # emake -j1 JLATEXCMD=platex \
+ # DVI2PSCMD="dvips -f" \
+ # canna.dvi canna.ps || die
+ # if has_version 'app-text/dvipdfmx' && \
+ # ( has_version 'app-text/acroread' \
+ # || has_version 'app-text/xpdf-japanese' ); then
+ # emake -j1 JLATEXCMD=platex \
+ # DVI2PSCMD="dvips -f" \
+ # canna.pdf || die
+ # fi
+ #fi
+}
+
+src_install() {
+ emake DESTDIR="${D}" install || die
+ emake DESTDIR="${D}" install.man || die
+
+ # install default.canna (removed from Canna36p4)
+ insinto /usr/share/canna
+ newins misc/initfiles/verbose.canna default.canna
+
+ # cannakill should link to /usr/bin/catdic
+ dosym ../bin/catdic /usr/sbin/cannakill
+
+ dodir /usr/share/man/man8 /usr/share/man/ja/man8
+ for man in cannaserver cannakill ; do
+ for mandir in "${D}"/usr/share/man "${D}"/usr/share/man/ja ; do
+ mv ${mandir}/man1/${man}.1 ${mandir}/man8/${man}.8
+ done
+ done
+
+ dodoc CHANGES.jp ChangeLog INSTALL* README* WHATIS*
+
+ #if use doc ; then
+ # insinto /usr/share/doc/${PF}
+ # doins doc/man/guide/tex/canna.{dvi,ps,pdf}
+ #fi
+
+ newinitd "${FILESDIR}"/${P}.initd canna || die
+ newconfd "${FILESDIR}"/${P}.confd canna || die
+ insinto /etc/ ; newins "${FILESDIR}"/canna.hosts hosts.canna || die
+ keepdir /var/log/canna/ || die
+
+ # for backward compatibility
+ dosbin "${FILESDIR}"/update-canna-dics_dir
+
+ insinto /var/lib/canna/dic/dics.d/
+ newins "${D}"/var/lib/canna/dic/canna/dics.dir 00canna.dics.dir
+
+ # fix permission for user dictionary
+ keepdir /var/lib/canna/dic/{user,group}
+ fowners root:bin /var/lib/canna/dic/{user,group}
+ fperms 775 /var/lib/canna/dic/{user,group}
+}
+
+pkg_postinst() {
+ update-cannadic-dir
+ elog
+ elog "Canna dictionary format has been changed."
+ elog "You should rebuild app-dict/canna-* after emerge."
+ elog
+}
+
+pkg_prerm() {
+ if [ -S /tmp/.iroha_unix/IROHA ] ; then
+ # make sure cannaserver get stopped because otherwise
+ # we cannot stop it with /etc/init.d after emerge -C canna
+ einfo
+ einfo "Stopping Canna for safe unmerge"
+ einfo
+ /etc/init.d/canna stop
+ touch "${T}"/canna.cookie
+ fi
+}
+
+pkg_postrm() {
+ if [ -f /usr/sbin/cannaserver -a -e "${T}"/canna.cookie ] ; then
+ #update-cannadic-dir
+ einfo
+ einfo "Restarting Canna"
+ einfo
+ /etc/init.d/canna start
+ rm -f "${T}"/canna.cookie
+ fi
+}