sunpinyin-2.0.4_pre20130108-r1.ebuild 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. # Copyright 1999-2016 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=5
  4. PYTHON_COMPAT=( python2_7 )
  5. inherit eutils multilib python-any-r1 scons-utils toolchain-funcs
  6. DESCRIPTION="A Statistical Language Model based Chinese input method library"
  7. HOMEPAGE="https://github.com/sunpinyin/sunpinyin"
  8. SRC_URI="https://dev.gentoo.org/~yngwin/distfiles/${P}.tar.xz"
  9. LICENSE="LGPL-2.1 CDDL"
  10. SLOT="0/1"
  11. KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
  12. IUSE=""
  13. RDEPEND="dev-db/sqlite:3"
  14. DEPEND="${RDEPEND}
  15. ${PYTHON_DEPS}
  16. dev-util/intltool
  17. sys-devel/gettext
  18. virtual/pkgconfig"
  19. PDEPEND="app-i18n/sunpinyin-data"
  20. src_prepare() {
  21. epatch "${FILESDIR}"/${PN}-2.0.4-pod2man.patch
  22. epatch "${FILESDIR}"/${P}-gcc6-use-float.patch
  23. epatch_user
  24. }
  25. src_configure() {
  26. tc-export CXX
  27. myesconsargs=(
  28. --prefix="${EPREFIX}"/usr
  29. --libdir="${EPREFIX}"/usr/$(get_libdir)
  30. )
  31. }
  32. src_compile() {
  33. escons
  34. }
  35. src_install() {
  36. escons --install-sandbox="${D}" install
  37. rm -rf "${D}"/usr/share/doc/${PN} || die
  38. dodoc doc/{README,SLM-inst.mk,SLM-train.mk}
  39. }