aboutsummaryrefslogtreecommitdiff
blob: 5f948f6bd3ad5e4ed260704908cb8389165aa95c (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
# $Header: $

EAPI=3
inherit autotools eutils fortran-2

DESCRIPTION="Library for reading and writing matlab files"
HOMEPAGE="http://sourceforge.net/projects/matio/"
SLOT="0"
LICENSE="LGPL-2.1"
KEYWORDS="~amd64 ~x86"
# disabling (until fix) doxygen doc generation
IUSE="examples fortran static-libs"
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
#DEPEND="doc? ( app-doc/doxygen virtual/latex-base )"
RDEPEND=""

src_prepare() {
	epatch "${FILESDIR}"/${P}-autotools.patch
	eautoreconf
}

src_configure() {
	econf \
		--docdir="${EPREFIX}/usr/share/doc/${PF}" \
		--enable-shared \
		--disable-test \
		$(use_enable fortran) \
		$(use_enable doc docs) \
		$(use_enable static-libs static)
}

src_install() {
	emake DESTDIR="${D}" install || die "emake install failed"
	dodoc README ChangeLog
	#if use doc; then
	#	insinto /usr/share/doc/${PF}
	#	doins -r doxygen/html || die
	#fi
	if use examples; then
		insinto /usr/share/doc/${PF}/examples
		doins test/test* || die
		insinto /usr/share/${PN}
		doins share/test* || die
	fi
}