# Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: /var/cvsroot/gentoo-x86/media-libs/openexr/openexr-1.2.2-r2.ebuild,v 1.7 2006/07/09 21:19:40 pylon Exp $ inherit eutils libtool autotools DESCRIPTION="ILM's HDR image file format libraries" SRC_URI="http://savannah.nongnu.org/download/openexr/${P}.tar.gz" HOMEPAGE="http://www.openexr.com" SLOT="0" LICENSE="as-is" KEYWORDS="~alpha ~amd64 hppa ~ia64 ~mips ppc ~ppc64 ~sparc ~x86 ~x86-fbsd" IUSE="doc examples fltk nvidia" RDEPEND="virtual/opengl" DEPEND="${RDEPEND} dev-util/pkgconfig fltk? ( >=x11-libs/fltk-1.1.0 nvidia? ( media-gfx/nvidia-cg-toolkit ) )" src_unpack() { if use fltk && ! built_with_use x11-libs/fltk opengl; then die "need opengl support in fltk" fi unpack ${A} # Replace the temporary directory used for tests sed -i -e 's:"/var/tmp/":'"${T}"':' "${S}/IlmImfTest/tmpDir.h" eautomake elibtoolize } src_compile() { econf \ $(use_enable examples imfexamples) \ $(use_with fltk fltk-config /usr/bin/fltk-config) emake || die "make failed" } src_install () { make DESTDIR="${D}" examplesdir="/usr/share/doc/${P}/examples" install || \ die "install failed" dodoc AUTHORS Changelog README* ChangeLog LICENSE NEWS newdoc exrdisplay/README README.exrdisplay use doc && dodoc doc/*pdf }