dev-qt/qttest: stable 5.14.2 for ppc, bug #719732
[gentoo.git] / app-i18n / xcin / xcin-2.5.3_pre3-r3.ebuild
1 # Copyright 1999-2019 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI="4"
5 inherit multilib eutils autotools libtool
6
7 MY_P=${PN}_2.5.2.99.pre2+cvs20030224
8
9 DESCRIPTION="Chinese X Input Method"
10 HOMEPAGE="http://cle.linux.org.tw/xcin/"
11 SRC_URI="mirror://debian/pool/main/x/${PN}/${MY_P}.orig.tar.gz
12         mirror://debian/pool/main/x/${PN}/${MY_P}-1.4.diff.gz"
13
14 LICENSE="XCIN GPL-2"
15 SLOT="0"
16 KEYWORDS="~amd64 ppc x86"
17 IUSE="debug nls unicode"
18
19 RDEPEND=">=sys-libs/db-4.5
20         >=app-i18n/libtabe-0.2.6
21         unicode? ( media-fonts/hkscs-ming
22                 media-fonts/arphicfonts )
23         app-i18n/libchewing
24         x11-libs/libX11"
25 DEPEND="${RDEPEND}
26         nls? ( sys-devel/gettext )"
27
28 S="${WORKDIR}/${MY_P/_/-}"
29
30 src_prepare() {
31         epatch \
32                 "${WORKDIR}"/${MY_P}-1.4.diff \
33                 "${FILESDIR}"/${P}-glibc-2.10.patch \
34                 "${FILESDIR}"/${P}-make.patch \
35                 "${FILESDIR}"/${P}-ldflags.patch
36         rm -f configure
37         cd script
38         elibtoolize
39         eautoreconf
40         mv configure ../
41 }
42
43 src_configure() {
44         econf \
45                 --disable-static \
46                 --with-xcin-rcdir="${EPREFIX}/etc" \
47                 --with-xcin-dir="${EPREFIX}/usr/$(get_libdir)/xcin25" \
48                 --with-db-lib="${EPREFIX}/usr/$(get_libdir)" \
49                 --with-tabe-inc="${EPREFIX}/usr/include/tabe" \
50                 --with-tabe-lib="${EPREFIX}/usr/$(get_libdir)" \
51                 $(use_enable debug)
52 }
53
54 src_compile() {
55         emake -j1
56 }
57
58 src_install() {
59         emake \
60                 prefix="${ED}/usr" \
61                 program_prefix="${D}" \
62                 install
63
64         find "${ED}" -name "*.la" -type f -delete || die
65
66         for docdir in doc doc/En doc/En/internal doc/history doc/internal doc/modules; do
67                 docinto ${docdir#doc/}
68                 for doc in $(find ${docdir} -maxdepth '1' -type 'f'); do
69                         if use unicode; then
70                                         iconv -f BIG5 -t UTF-8 --output=${doc}.UTF-8 ${doc}
71                                         mv ${doc}.UTF-8 ${doc}
72                         fi
73                         dodoc ${doc}
74                 done
75         done
76 }