]> Pileus Git - ~andy/sunrise/blob - dev-libs/openproducer/openproducer-1.1.0.ebuild
add missing die
[~andy/sunrise] / dev-libs / openproducer / openproducer-1.1.0.ebuild
1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: $
4
5 inherit eutils toolchain-funcs multilib fixheadtails
6
7 MY_PN="Producer"
8 OSG_V=1.2
9 DESCRIPTION="a cross-platform C++/OpenGL library that is focused on Camera control"
10 HOMEPAGE="http://openscenegraph.org/"
11 SRC_URI="http://www.openscenegraph.org/downloads/stable_releases/OpenSceneGraph-${OSG_V}/source/OSG_OP_OT-${OSG_V}.zip"
12
13 LICENSE="OSGPL"
14 SLOT="0"
15 KEYWORDS="~x86"
16 IUSE="doc examples"
17
18 RDEPEND="virtual/opengl
19         >=dev-libs/openthreads-1.4.3
20         x11-libs/libXmu
21         x11-libs/libX11"
22 DEPEND="${RDEPEND}
23         app-arch/unzip
24         doc? ( app-doc/doxygen )"
25
26 S="${WORKDIR}/OSG_OP_OT-${OSG_V}/${MY_PN}"
27
28 src_unpack() {
29         unpack ${A}
30         cd "${S}"
31         epatch "${FILESDIR}"/${P}-build.patch
32
33         ht_fix_all
34 }
35
36 src_compile() {
37         emake CXX="$(tc-getCXX)" || die "emake failed"
38
39         if use doc; then
40                 cd docs
41                 doxygen doxy.cfg
42         fi
43 }
44
45 src_install() {
46         emake INST_LOCATION="${D}"/usr install || die "emake install failed"
47
48         dosym /usr/$(get_libdir)/lib${MY_PN}.so{.${PV},}
49         dosym /usr/$(get_libdir)/lib${MY_PN}.so.{${PV},${PV%%.*}}
50
51         insinto /usr/$(get_libdir)/pkgconfig
52         doins Make/producer.pc
53
54         dodoc README.txt
55
56         use doc && dohtml -r doc/Doxygen/html/*
57
58         if use examples; then
59                 insinto /usr/share/doc/${PF}/examples
60                 doins -r doc/Tutorial/SourceCode/*
61         fi
62 }