/[gentoo-x86]/sci-libs/blas-reference/blas-reference-20070226-r1.ebuild
Gentoo

Contents of /sci-libs/blas-reference/blas-reference-20070226-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.10 - (show annotations) (download)
Thu Oct 18 21:19:19 2012 UTC (7 years, 9 months ago) by jlec
Branch: MAIN
CVS Tags: HEAD
Changes since 1.9: +1 -1 lines
FILE REMOVED
sci-libs/blas-reference: Remove virtual/fortran and always call fortran-2_pkg_setup as intend by the updated fortran-2.eclass

(Portage version: 2.2.0_alpha141/cvs/Linux x86_64, signed Manifest commit with key 8009D6F070EB7916)

1 # Copyright 1999-2011 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sci-libs/blas-reference/blas-reference-20070226-r1.ebuild,v 1.9 2011/06/21 15:41:52 jlec Exp $
4
5 EAPI=3
6
7 inherit eutils fortran-2 autotools multilib flag-o-matic toolchain-funcs
8
9 LAPACKPV="3.1.1"
10 LAPACKPN="lapack-lite"
11
12 DESCRIPTION="Basic Linear Algebra Subprograms F77 reference implementations"
13 HOMEPAGE="http://www.netlib.org/blas/"
14 SRC_URI="http://www.netlib.org/lapack/${LAPACKPN}-${LAPACKPV}.tgz"
15
16 LICENSE="BSD"
17 SLOT="0"
18 KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos"
19 IUSE="doc"
20
21 DEPEND="
22 virtual/fortran
23 app-admin/eselect-blas"
24 RDEPEND="${DEPEND}
25 doc? ( app-doc/blas-docs )"
26
27 S="${WORKDIR}/${LAPACKPN}-${LAPACKPV}"
28
29 src_prepare() {
30 ESELECT_PROF=reference
31 epatch "${FILESDIR}"/${P}-autotool.patch
32 eautoreconf
33
34 cp "${FILESDIR}"/eselect.blas.reference "${T}"/
35 sed -i -e "s:/usr:${EPREFIX}/usr:" "${T}"/eselect.blas.reference || die
36 if [[ ${CHOST} == *-darwin* ]] ; then
37 sed -i -e 's/\.so\([\.0-9]\+\)\?/\1.dylib/g' \
38 "${T}"/eselect.blas.reference || die
39 fi
40 }
41
42 src_configure() {
43 econf \
44 --libdir="${EPREFIX}"/usr/$(get_libdir)/blas/reference
45 }
46
47 src_compile() {
48 emake LDFLAGS="${LDFLAGS}" || die "emake failed"
49 }
50
51 src_install() {
52 emake DESTDIR="${D}" install || die "emake install failed"
53 eselect blas add $(get_libdir) "${T}"/eselect.blas.reference ${ESELECT_PROF}
54 }
55
56 pkg_postinst() {
57 local p=blas
58 local current_lib=$(eselect ${p} show | cut -d' ' -f2)
59 if [[ ${current_lib} == ${ESELECT_PROF} || -z ${current_lib} ]]; then
60 # work around eselect bug #189942
61 local configfile="${EROOT}"/etc/env.d/${p}/$(get_libdir)/config
62 [[ -e ${configfile} ]] && rm -f ${configfile}
63 eselect ${p} set ${ESELECT_PROF}
64 elog "${p} has been eselected to ${ESELECT_PROF}"
65 else
66 elog "Current eselected ${p} is ${current_lib}"
67 elog "To use ${p} ${ESELECT_PROF} implementation, you have to issue (as root):"
68 elog "\t eselect ${p} set ${ESELECT_PROF}"
69 fi
70 }

  ViewVC Help
Powered by ViewVC 1.1.20