Advertisement
Dj_Dexter

emesene-1.6.3-r1.ebuild

Nov 28th, 2011
148
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.81 KB | None | 0 0
  1. # Copyright 1999-2011 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. # $Header: /var/cvsroot/gentoo-x86/net-im/emesene/emesene-1.6.3.ebuild,v 1.9 2011/10/30 15:39:41 ssuominen Exp $
  4.  
  5. EAPI="2"
  6. PYTHON_DEPEND="2"
  7.  
  8. inherit python eutils
  9.  
  10. DESCRIPTION="Platform independent MSN Messenger client written in Python+GTK"
  11. HOMEPAGE="http://www.emesene.org"
  12. SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
  13.  
  14. LICENSE="GPL-2"
  15. SLOT="0"
  16. KEYWORDS="amd64 x86"
  17. IUSE="webcam"
  18.  
  19. RDEPEND="dev-python/pygtk:2
  20.     webcam? ( media-plugins/gst-plugins-meta[v4l]
  21.         dev-python/gst-python
  22.         media-libs/libmimic )"
  23.  
  24. pkg_setup() {
  25.     python_set_active_version 2
  26. }
  27.  
  28. src_prepare() {
  29.     rm GPL PSF LGPL || die "rm license files failed"
  30.  
  31.     if ! use webcam; then
  32.         rm -r libmimic || die "rm libmimic dir failed"
  33.     fi
  34.  
  35.     python_convert_shebangs -r 2 .
  36.         epatch "${FILESDIR}/wlm_emesene-1.6_contact.patch"
  37. }
  38.  
  39. src_compile() {
  40.     if use webcam ; then
  41.         $(PYTHON) ./setup.py build_ext -i || die "libmimic compile failed"
  42.     fi
  43. }
  44.  
  45. src_install() {
  46.     if use webcam; then
  47.         rm -r build || die "rm build failed"
  48.     fi
  49.  
  50.     insinto /usr/share/${PN}
  51.     doins -r * || die "doins failed"
  52.  
  53.     fperms a+x /usr/share/${PN}/${PN} || die "fperms failed"
  54.     dosym /usr/share/${PN}/${PN} /usr/bin/${PN} || die "dosym failed"
  55.  
  56.     doman misc/${PN}.1 || die "doman failed"
  57.  
  58.     doicon misc/*.{svg,png} || die "doicon failed"
  59.  
  60.     # install the desktop entry
  61.     domenu misc/${PN}.desktop || die "domenu failed"
  62. }
  63.  
  64. pkg_postinst() {
  65.     python_mod_optimize /usr/share/${PN}
  66.  
  67.     elog "If you want to use the spell-checking feature, you should emerge"
  68.     elog "dev-python/gtkspell-python"
  69.     elog
  70.     elog "If you want to use EncryptMessage plugin, you should emerge"
  71.     elog "dev-python/pexpect"
  72. }
  73.  
  74. pkg_postrm() {
  75.     python_mod_cleanup /usr/share/${PN}
  76. }
  77.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement