dev-python/sphinxcontrib-devhelp: arm stable wrt bug #710524
[gentoo.git] / sci-libs / mc / mc-1.5.ebuild
1 # Copyright 1999-2017 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=5
5
6 AUTOTOOLS_AUTORECONF=true
7
8 inherit autotools-utils fortran-2 multilib
9
10 DESCRIPTION="2D/3D AFEM code for nonlinear geometric PDE"
11 HOMEPAGE="http://fetk.org/codes/mc/index.html"
12 SRC_URI="http://www.fetk.org/codes/download/${P}.tar.gz"
13
14 SLOT="0"
15 KEYWORDS="amd64 x86 ~amd64-linux ~x86-linux"
16 LICENSE="GPL-2"
17 IUSE="debug doc static-libs"
18
19 RDEPEND="
20         dev-libs/maloc
21         media-libs/sg
22         sci-libs/amd
23         sci-libs/gamer
24         sci-libs/punc
25         <sci-libs/superlu-5
26         sci-libs/umfpack
27         virtual/blas
28         virtual/lapack"
29 DEPEND="
30         ${RDEPEND}
31         doc? (
32                 media-gfx/graphviz
33                 app-doc/doxygen
34                 )"
35
36 S="${WORKDIR}"/${PN}
37
38 PATCHES=(
39         "${FILESDIR}"/1.4-superlu.patch
40         "${FILESDIR}"/1.4-overflow.patch
41         "${FILESDIR}"/1.4-multilib.patch
42         "${FILESDIR}"/1.4-doc.patch
43         "${FILESDIR}"/${P}-unbundle.patch
44         )
45
46 src_prepare() {
47         sed \
48                 -e 's:AMD_order:amd_order:g' \
49                 -e 's:UMFPACK_numeric:umfpack_di_numeric:g' \
50                 -e 's:buildg_:matvec_:g' \
51                 -i configure.ac || die
52         autotools-utils_src_prepare
53 }
54
55 src_configure() {
56         local fetk_include
57         local fetk_lib
58         local myeconfargs
59
60         use doc || myeconfargs+=( --with-doxygen= --with-dot= )
61
62         fetk_include="${EPREFIX}"/usr/include
63         fetk_lib="${EPREFIX}"/usr/$(get_libdir)
64         export FETK_INCLUDE="${fetk_include}"
65         export FETK_LIBRARY="${fetk_lib}"
66         export FETK_MPI_LIBRARY="${fetk_lib}"
67         export FETK_VF2C_LIBRARY="${fetk_lib}"
68         export FETK_BLAS_LIBRARY="${fetk_lib}"
69         export FETK_LAPACK_LIBRARY="${fetk_lib}"
70         export FETK_AMD_LIBRARY="${fetk_lib}"
71         export FETK_UMFPACK_LIBRARY="${fetk_lib}"
72         export FETK_SUPERLU_LIBRARY="${fetk_lib}"
73         export FETK_ARPACK_LIBRARY="${fetk_lib}"
74         export FETK_CGCODE_LIBRARY="${fetk_lib}"
75         export FETK_PMG_LIBRARY="${fetk_lib}"
76
77         myeconfargs+=(
78                 --docdir="${EPREFIX}"/usr/share/doc/${PF}
79                 $(use_enable debug vdebug)
80                 --disable-triplet
81                 --enable-shared
82         )
83         autotools-utils_src_configure
84 }