scim-1.4.16.ebuild 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. # Copyright 1999-2016 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=6
  4. inherit eutils flag-o-matic multilib gnome2-utils autotools
  5. DESCRIPTION="Smart Common Input Method (SCIM) is an Input Method (IM) development platform"
  6. HOMEPAGE="https://sourceforge.net/projects/scim"
  7. SRC_URI="mirror://sourceforge/scim/${P}.tar.gz"
  8. LICENSE="GPL-2"
  9. SLOT="0"
  10. KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
  11. IUSE="doc gtk3"
  12. RDEPEND="x11-libs/libX11
  13. dev-libs/glib:2
  14. gtk3? ( x11-libs/gtk+:3 )
  15. !gtk3? ( x11-libs/gtk+:2 )
  16. >=dev-libs/atk-1
  17. >=x11-libs/pango-1"
  18. DEPEND="${RDEPEND}
  19. doc? ( app-doc/doxygen
  20. >=app-text/docbook-xsl-stylesheets-1.73.1 )
  21. dev-lang/perl
  22. virtual/pkgconfig
  23. >=dev-util/intltool-0.33
  24. sys-devel/libtool"
  25. DOCS=(
  26. README
  27. AUTHORS
  28. ChangeLog
  29. docs/developers
  30. docs/scim.cfg
  31. )
  32. src_prepare() {
  33. default
  34. eautoreconf
  35. }
  36. src_configure() {
  37. # bug #83625
  38. filter-flags -fvisibility-inlines-hidden -fvisibility=hidden
  39. econf $(use_with doc doxygen) \
  40. --enable-ld-version-script \
  41. $(usex gtk3 --with-gtk-version={3,2})
  42. }
  43. src_compile() {
  44. default
  45. use doc && emake docs
  46. }
  47. src_install() {
  48. use doc && HTML_DOCS=( "${S}/docs/html/" )
  49. default
  50. sed -e "s:@EPREFIX@:${EPREFIX}:" "${FILESDIR}/xinput-${PN}" > "${T}/${PN}.conf" || die
  51. insinto /etc/X11/xinit/xinput.d
  52. doins "${T}/${PN}.conf"
  53. }
  54. pkg_postinst() {
  55. elog
  56. elog "To use SCIM with both GTK and XIM, you should use the following"
  57. elog "in your user startup scripts such as .gnomerc or .xinitrc:"
  58. elog
  59. elog "LANG='your_language' scim -d"
  60. elog "export XMODIFIERS=@im=SCIM"
  61. elog "export GTK_IM_MODULE=\"scim\""
  62. elog "export QT_IM_MODULE=\"scim\""
  63. elog
  64. elog "where 'your_language' can be zh_CN, zh_TW, ja_JP.eucJP or any other"
  65. elog "UTF-8 locale such as en_US.UTF-8 or ja_JP.UTF-8"
  66. elog
  67. elog "To use Chinese input methods:"
  68. elog " # emerge app-i18n/scim-tables app-i18n/scim-pinyin"
  69. elog "To use Korean input methods:"
  70. elog " # emerge app-i18n/scim-hangul"
  71. elog "To use Japanese input methods:"
  72. elog " # emerge app-i18n/scim-anthy"
  73. elog "To use various input methods (more than 30 languages):"
  74. elog " # emerge app-i18n/scim-m17n"
  75. elog
  76. elog "Please modify ${EPREFIX}/etc/scim/global and add your UTF-8 locale to"
  77. elog "/SupportedUnicodeLocales entry."
  78. elog
  79. ewarn
  80. ewarn "If you upgraded from scim-1.2.x or scim-1.0.x, you should remerge all SCIM modules."
  81. ewarn
  82. gnome2_query_immodules_gtk2
  83. }
  84. pkg_postrm() {
  85. gnome2_query_immodules_gtk2
  86. }