aboutsummaryrefslogtreecommitdiff
blob: 672bb852cf8f3df3fb617dc361a83174c1b005c5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$

EAPI=5

AUTOTOOLS_IN_SOURCE_BUILD=1
inherit autotools-utils flag-o-matic

DESCRIPTION="Object-oriented Scientific Computing Library"
HOMEPAGE="http://o2scl.sourceforge.net/"
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"

LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
IUSE="debug doc examples hdf5 static-libs"

RDEPEND="
	dev-libs/boost:0=
	sci-libs/gsl:0=
	hdf5? ( sci-libs/hdf5:0= )"
DEPEND="${RDEPEND}"

src_configure() {
	use debug || append-cppflags -DO2SCL_NO_RANGE_CHECK
	local myeconfargs=(
		$(use_enable hdf5 hdf)
		$(use_enable hdf5 partlib)
		$(use_enable hdf5 eoslib)
	)
	autotools-utils_src_configure
}

src_test() {
	autotools-utils_src_test o2scl-test
}

src_install() {
	autotools-utils_src_install
	rm -r "${ED}"/usr/doc || die
	use doc && dohtml -r doc/o2scl/html/*
	if use examples; then
		insinto /usr/share/doc/${PF}
		doins -r examples
	fi
}