net-im/gajim-0.12.1: Initial add
[otih-overlay.git] / net-im / gajim / gajim-0.12.1.ebuild
blob3d1ec8b318bec918ce44cb6db604e1f2d160889d
1 # Copyright 1999-2009 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-im/gajim/gajim-0.11.4.ebuild,v 1.7 2009/03/07 19:57:16 gentoofan23 Exp $
5 EAPI="2"
6 inherit multilib python eutils
8 DESCRIPTION="Jabber client written in PyGTK"
9 HOMEPAGE="http://www.gajim.org/"
10 SRC_URI="http://www.gajim.org/downloads/${P}.tar.gz"
12 LICENSE="GPL-2"
13 SLOT="0"
14 KEYWORDS="alpha amd64 ~hppa ppc ppc64 sparc x86 ~x86-fbsd"
15 IUSE="avahi dbus gnome idle libnotify nls spell srv trayicon X xhtml"
17 DEPEND="|| (
18 ( <dev-lang/python-2.5 dev-python/pysqlite )
19 >=dev-lang/python-2.5[sqlite]
21 dev-python/pygtk
22 sys-devel/gettext
23 dev-util/intltool
24 dev-util/pkgconfig"
26 RDEPEND="gnome? ( dev-python/gnome-python-extras
27 dev-python/gnome-python-desktop
29 dbus? ( dev-python/dbus-python dev-libs/dbus-glib )
30 libnotify? ( x11-libs/libnotify )
31 xhtml? ( dev-python/docutils )
32 srv? ( net-dns/bind-tools )
33 idle? ( x11-libs/libXScrnSaver )
34 spell? ( app-text/gtkspell )
35 avahi? ( net-dns/avahi[dbus,gtk,python] )
36 dev-python/pyopenssl"
38 pkg_setup() {
39 if ! use dbus; then
40 if use libnotify; then
41 eerror "The dbus USE flag is required for libnotify support"
42 die "USE=\"dbus\" needed for libnotify support"
44 if use avahi; then
45 eerror "The dbus USE flag is required for avahi support"
46 die "USE=\"dbus\" needed for avahi support"
48 else
49 if has_version "<sys-apps/dbus-0.90" && ! built_with_use sys-apps/dbus python; then
50 eerror "Please rebuild dbus with USE=\"python\""
51 die "USE=\"python\" needed for dbus"
56 src_configure() {
57 local myconf
59 if ! use gnome; then
60 myconf="${myconf} $(use_enable trayicon)"
61 myconf="${myconf} $(use_enable idle)"
64 econf $(use_enable nls) \
65 $(use_enable spell gtkspell) \
66 $(use_enable dbus remote) \
67 $(use_with X x) \
68 --docdir="/usr/share/doc/${PF}" \
69 --prefix="/usr" \
70 --libdir="/usr/$(get_libdir)" \
71 ${myconf}
74 src_install() {
75 emake DESTDIR="${D}" install || die "emake install failed"
77 rm "${D}/usr/share/doc/${PF}/README.html"
78 dohtml README.html
81 pkg_postinst() {
82 python_mod_optimize /usr/share/gajim/
85 pkg_postrm() {
86 python_mod_cleanup /usr/share/gajim/