# Copyright 1999-2009 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ EAPI="2" inherit eutils gnome2 DESCRIPTION="H.323 and SIP VoIP softphone" HOMEPAGE="http://www.ekiga.org/" SLOT="0" LICENSE="GPL-2" KEYWORDS="~ppc" IUSE="avahi dbus debug doc eds gconf gnome +h323 ldap libnotify mmx nls +shm +sip static v4l xv" RDEPEND=">=dev-libs/glib-2.8.0:2 dev-libs/libsigc++:2 dev-libs/libxml2:2 =net-libs/ptlib-2.4*[debug=] =net-libs/opal-3.4*[debug=,h323?,sip?,wav] >=x11-libs/gtk+-2.12.0:2 sys-devel/gettext avahi? ( >=net-dns/avahi-0.6[dbus] ) dbus? ( >=sys-apps/dbus-0.36 >=dev-libs/dbus-glib-0.36 ) eds? ( >=gnome-extra/evolution-data-server-1.2 ) gconf? ( >=gnome-base/gconf-2.6.0:2 ) gnome? ( >=gnome-base/libgnome-2.14.0 >=gnome-base/libgnomeui-2.14.0 ) ldap? ( net-nds/openldap ) libnotify? ( x11-libs/libnotify ) shm? ( x11-libs/libXext ) xv? ( x11-libs/libXv )" DEPEND="${RDEPEND} >=sys-devel/make-3.81 >=dev-util/pkgconfig-0.20 >=dev-util/intltool-0.35 doc? ( app-text/scrollkeeper app-text/gnome-doc-utils ) v4l? ( sys-kernel/linux-headers )" DOCS="AUTHORS ChangeLog FAQ NEWS README TODO" # NOTES: # # make 3.80 is breaking installation phase, need make 3.81 at least # gettext is required for glib and intltool so not directly but painless to add # ekiga doesn't work with opal-3.5* and ptlib-2.5* pkg_setup() { # dbus-service: always enable if dbus is enabled, no reason to disable it # scrollkeeper: updates scrollkeeper database # schemas-install: install gconf schemas G2CONF="${G2CONF} --disable-dependency-tracking --enable-fast-install --disable-maintainer-mode --enable-libtool-lock $(use_enable avahi) $(use_enable dbus) $(use_enable dbus dbus_service) $(use_enable debug) $(use_enable doc gdu) $(use_enable doc scrollkeeper) $(use_enable eds) $(use_enable gconf) $(use_enable gconf schemas-install) $(use_enable gnome) $(use_enable ldap) $(use_enable libnotify notify) $(use_enable nls) $(use_enable static static-libs) $(use_enable xv)" } src_prepare() { # remove call to gconftool-2 --shutdown # upstream has been contacted, see bug 555976 in their bugtracker # TODO: ekiga team don't agree with this patch sed -i -e '/gconftool-2 --shutdown/d' Makefile.in \ || die "patching Makefile.in failed" # fix ekiga-helper dbus service .in file # has been fixed by upstream, see bug 555974 in their bug tracker # TODO: check for fix in new releases sed -i -e 's/@PACKAGE_NAME@/ekiga/'\ src/components/org.ekiga.Helper.service.in \ || die "patching src/components/org.ekiga.Helper.service.in failed" # fix compilation issues when PTRACING is disabled in ptlib # upstream has been contacted, see bug 575433 in their bugtracker epatch "${FILESDIR}"/${P}-ptracing.patch # mmx is automatically enabled for some arch, want it to be a user choice # upstream has been contacted, see bug 575831 in their bugtracker if use mmx; then sed -i -e "s/use_x86_asm=no/use_x86_asm=yes/" configure \ || die "patching configure failed" else sed -i -e "s/use_x86_asm=yes/use_x86_asm=no/" configure \ || die "patching configure failed" fi # SIP is automatically enabled with opal[sip], want it to be a user choice # upstream has been contacted, see bug 575832 in their bugtracker if ! use sip; then sed -i -e "s/SIP=\"yes\"/SIP=\"no\"/" configure \ || die "patching configure failed" sed -i -e \ "s:SIP=\`\$PKG_CONFIG --variable=OPAL_SIP opal\`:SIP=\"no\":" \ configure || die "patching configure failed" fi # H323 is automatically enabled with opal[h323], want it to be a user choice # upstream has been contacted, see bug 575833 in their bugtracker if ! use h323; then sed -i -e "s/H323=\"yes\"/H323=\"no\"/" configure \ || die "patching configure failed" sed -i -e \ "s:H323=\`\$PKG_CONFIG --variable=OPAL_H323 opal\`:H323=\"no\":" \ configure || die "patching configure failed" fi # SHM support from libXext is auto-enabled, want it to be a user choice # upstream has been contacted, see bug 575835 in their bugtracker if ! use shm; then sed -i -e "s/with_shm=\"yes\"/with_shm=\"no\"/" configure \ || die "patching configure failed" fi # V4L support is auto-enabled, want it to be a user choice # do not contact upstream because that's a hack # TODO: check if upstream has removed this hack if ! use v4l; then sed -i -e "s/V4L=\"enabled\"/V4L=\"disabled\"/" configure \ || die "patching configure failed" fi } pkg_postinst() { gnome2_pkg_postinst if ! use gnome; then ewarn "USE=-gnome is experimental, some weirdness with the UI and" ewarn "config keys should appear." fi }