/[gentoo-x86]/app-i18n/nkf/nkf-2.0.7-r1.ebuild
Gentoo

Contents of /app-i18n/nkf/nkf-2.0.7-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations) (download)
Mon Jun 6 23:30:49 2011 UTC (8 years, 8 months ago) by matsuu
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +1 -1 lines
FILE REMOVED
Fixed USE="-python" issue, bug #311215. Removed old revisions.

(Portage version: 2.1.9.50/cvs/Linux x86_64)

1 # Copyright 1999-2011 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/app-i18n/nkf/nkf-2.0.7-r1.ebuild,v 1.2 2011/01/08 19:35:49 arfrever Exp $
4
5 EAPI="3"
6
7 inherit toolchain-funcs eutils perl-module distutils
8
9 MY_P="nkf${PV//./}"
10 DESCRIPTION="Network Kanji code conversion Filter with UTF-8/16 support"
11 HOMEPAGE="http://sourceforge.jp/projects/nkf/"
12 SRC_URI="mirror://sourceforge.jp/nkf/20770/${MY_P}.tar.gz
13 python? ( http://city.plala.jp/download/nkf/NKF_python.tgz )"
14
15 LICENSE="as-is"
16 SLOT="0"
17 KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86"
18 IUSE="perl python linguas_ja"
19
20 S="${WORKDIR}/${MY_P}"
21
22 src_prepare() {
23 sed -i -e '/-o nkf/s:$(CFLAGS):$(CFLAGS) $(LDFLAGS):' Makefile || die
24
25 if use python; then
26 unpack NKF_python.tgz
27 # bug #248725
28 sed -i -e "s/-s/${CFLAGS}/" NKF.python/setup.py || die
29 fi
30 }
31
32 src_compile() {
33 emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" nkf || die
34 if use perl; then
35 cd "${S}/NKF.mod"
36 perl-module_src_compile
37 fi
38 if use python; then
39 cd "${S}/NKF.python"
40 distutils_src_compile
41 fi
42 }
43
44 src_test() {
45 emake test || die
46 if use perl; then
47 cd "${S}/NKF.mod"
48 perl-module_src_test
49 fi
50 }
51
52 src_install() {
53 dobin nkf || die
54 doman nkf.1
55 if use linguas_ja; then
56 ./nkf -e nkf.1j > nkf.1
57 doman -i18n=ja nkf.1
58 fi
59 dodoc nkf.doc
60 if use perl; then
61 cd "${S}/NKF.mod"
62 perl-module_src_install
63 fi
64 if use python; then
65 cd "${S}/NKF.python"
66 distutils_src_install
67 fi
68 }
69
70 pkg_postinst() {
71 use python && distutils_pkg_postinst
72 }
73
74 pkg_postrm() {
75 use python && distutils_pkg_postrm
76 }

  ViewVC Help
Powered by ViewVC 1.1.20