You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
67 lines
1.5 KiB
67 lines
1.5 KiB
3 years ago
|
# Copyright 2004-2021 Gentoo Authors
|
||
7 years ago
|
# Distributed under the terms of the GNU General Public License v2
|
||
|
|
||
6 years ago
|
EAPI="7"
|
||
7 years ago
|
|
||
5 years ago
|
inherit autotools
|
||
|
|
||
7 years ago
|
if [[ "${PV}" == "9999" ]]; then
|
||
5 years ago
|
# inherit autotools git-r3
|
||
|
inherit git-r3
|
||
7 years ago
|
|
||
|
EGIT_REPO_URI="https://github.com/chewing/libchewing"
|
||
|
fi
|
||
|
|
||
|
DESCRIPTION="Intelligent phonetic (Zhuyin/Bopomofo) input method library"
|
||
|
HOMEPAGE="http://chewing.im/ https://github.com/chewing/libchewing"
|
||
|
if [[ "${PV}" == "9999" ]]; then
|
||
4 years ago
|
SRC_URI="https://dev.gentoo.org/~juippis/distfiles/tmp/libchewing-0.5.1-autoconf-archive-2019.01.06.patch"
|
||
7 years ago
|
else
|
||
4 years ago
|
SRC_URI="https://github.com/chewing/${PN}/releases/download/v${PV}/${P}.tar.bz2
|
||
|
https://dev.gentoo.org/~juippis/distfiles/tmp/libchewing-0.5.1-autoconf-archive-2019.01.06.patch"
|
||
7 years ago
|
fi
|
||
|
|
||
|
LICENSE="LGPL-2.1"
|
||
|
SLOT="0/3"
|
||
7 years ago
|
KEYWORDS="amd64 ~arm ~arm64 ppc ppc64 x86"
|
||
7 years ago
|
IUSE="static-libs test"
|
||
6 years ago
|
RESTRICT="!test? ( test )"
|
||
7 years ago
|
|
||
5 years ago
|
# BDEPEND="test? ( virtual/pkgconfig )"
|
||
|
BDEPEND="virtual/pkgconfig"
|
||
7 years ago
|
RDEPEND="dev-db/sqlite:3"
|
||
|
DEPEND="${RDEPEND}
|
||
3 years ago
|
test? ( sys-libs/ncurses[unicode(+)] )"
|
||
7 years ago
|
|
||
5 years ago
|
PATCHES=(
|
||
4 years ago
|
"${DISTDIR}/${PN}-0.5.1-autoconf-archive-2019.01.06.patch"
|
||
5 years ago
|
)
|
||
|
|
||
7 years ago
|
src_prepare() {
|
||
|
default
|
||
5 years ago
|
eautoreconf
|
||
7 years ago
|
|
||
5 years ago
|
# if [[ "${PV}" == "9999" ]]; then
|
||
|
# eautoreconf
|
||
|
# fi
|
||
7 years ago
|
}
|
||
|
|
||
7 years ago
|
src_configure() {
|
||
7 years ago
|
# libchewing.a is required for building of tests.
|
||
7 years ago
|
econf \
|
||
7 years ago
|
--with-sqlite3 \
|
||
|
$(if use static-libs || use test; then echo --enable-static; else echo --disable-static; fi)
|
||
7 years ago
|
}
|
||
|
|
||
|
src_test() {
|
||
|
emake -j1 check
|
||
|
}
|
||
|
|
||
|
src_install() {
|
||
|
default
|
||
5 years ago
|
find "${D}" -name "*.la" -type f -delete || die
|
||
|
if ! use static-libs; then
|
||
|
find "${D}" -name "*.a" -type f -delete || die
|
||
|
fi
|
||
7 years ago
|
}
|