h323plus-1.25.0-r1.ebuild 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. # Copyright 1999-2014 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=5
  4. inherit eutils flag-o-matic multilib toolchain-funcs
  5. MY_P="${PN}-v${PV//./_}"
  6. DESCRIPTION="Open Source implementation of the ITU H.323 teleconferencing protocol, successor to OpenH323"
  7. HOMEPAGE="http://www.h323plus.org/"
  8. SRC_URI="mirror://sourceforge/${PN}/${PN}-v${PV//./_}.tar.gz"
  9. IUSE="aec debug +sound +video"
  10. SLOT="0/${PV}"
  11. LICENSE="MPL-1.1"
  12. KEYWORDS="~alpha ~amd64 ~arm ~ppc ~sparc ~x86"
  13. DEPEND=">=net-libs/ptlib-2.6.4:=[wav]
  14. aec? ( >=media-libs/speex-1.2_rc1 )
  15. sound? (
  16. media-sound/gsm
  17. dev-libs/ilbc-rfc3951
  18. )
  19. video? (
  20. media-libs/libtheora
  21. virtual/ffmpeg
  22. )"
  23. RDEPEND="${DEPEND}
  24. !net-libs/openh323"
  25. S="${WORKDIR}/${PN}"
  26. src_prepare() {
  27. epatch "${FILESDIR}"/${PN}-1.25.0-ptrace-param.patch
  28. epatch "${FILESDIR}"/${PN}-1.25.0-ptrace-debugoptionlist.patch
  29. epatch "${FILESDIR}"/${PN}-1.25.0-ptlib-2.10.10.patch
  30. }
  31. src_configure() {
  32. # TODO: support for h.263/h.264/sbc(bluetooth)/celt/spandsp
  33. #export OPENH323DIR=${S}
  34. econf \
  35. PTLIB_CONFIG="${EPREFIX}/usr/bin/ptlib-config" \
  36. $(use_enable video) \
  37. $(use_enable sound audio) \
  38. $(use_enable aec) \
  39. $(use_enable debug asntracing)
  40. # revision.h does not exist in ptlib(?)
  41. sed -i "/revision.h/d" include/openh323buildopts.h || die
  42. }
  43. src_compile() {
  44. emake \
  45. CC="$(tc-getCC)" \
  46. CXX="$(tc-getCXX)" \
  47. AR="$(tc-getAR)"
  48. # these should point to the right directories,
  49. # openh323.org apps and others need this
  50. sed -i -e "s:^OH323_LIBDIR = \$(OPENH323DIR).*:OH323_LIBDIR = /usr/$(get_libdir):" \
  51. openh323u.mak || die
  52. sed -i -e "s:^OH323_INCDIR = \$(OPENH323DIR).*:OH323_INCDIR = /usr/include/openh323:" \
  53. openh323u.mak || die
  54. # this is hardcoded now?
  55. sed -i -e "s:^\(OPENH323DIR[ \t]\+=\) "${S}":\1 /usr/share/openh323:" \
  56. openh323u.mak || die
  57. }