blob: a1b55e57a7aef07a6239917169565ed5443e0d84 (
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
48
49
50
51
52
|
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sci-libs/clapack/clapack-3.2.1-r2.ebuild,v 1.1 2010/04/25 09:40:16 jlec Exp $
EAPI="3"
inherit eutils multilib toolchain-funcs versionator
DESCRIPTION="f2c'ed version of LAPACK"
HOMEPAGE="http://www.netlib.org/clapack/"
SRC_URI="http://www.netlib.org/${PN}/${P}.tgz"
LICENSE="BSD"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""
RDEPEND=">=dev-libs/libf2c-20081126[static-libs]"
DEPEND="${RDEPEND}"
S="${WORKDIR}"/CLAPACK-${PV}
src_prepare() {
rm -rf F2CLIBS BLAS
epatch "${FILESDIR}"/${PV}-solib.patch
sed \
-e "s:^CC.*$:CC = $(tc-getCC):g" \
-e "s:^CFLAGS.*$:CFLAGS = ${CFLAGS} -fPIC:g" \
-e "s:^LOADER.*$:LOADER = $(tc-getCC):g" \
-e "s:^LOADOPTS.*$:LOADOPTS = ${LDFLAGS} -Wl,-soname,libclapack.so.$(get_version_component_range 1-2):g" \
-e "s:LAPACKLIB.*$:LAPACKLIB = libclapack.so.${PV}:g" \
make.inc.example > make.inc
sed \
-e 's:"f2c.h":<f2c.h>:g' \
-i SRC/*.c || die
}
src_compile() {
emake -C INSTALL F2CLIB="${EPREFIX}"/usr/$(get_libdir)/libf2c.a || die "compile failed"
emake -C SRC || die "compile failed"
}
src_install() {
insinto /usr/include/${PN}
doins INCLUDE/${PN}.h || die
dolib.so lib${PN}.so.${PV} || die
dosym lib${PN}.so.${PV} /usr/$(get_libdir)/lib${PN}.so.$(get_version_component_range 1-2) || die
dosym lib${PN}.so.${PV} /usr/$(get_libdir)/lib${PN}.so.$(get_major_version) || die
dosym lib${PN}.so.${PV} /usr/$(get_libdir)/lib${PN}.so || die
}
|