diff options
author | Mo Zhou <cdluminate@gmail.com> | 2019-07-11 02:53:07 +0000 |
---|---|---|
committer | Benda Xu <heroxbd@gentoo.org> | 2019-07-11 18:55:22 +0800 |
commit | c84cc07add2d8a5351d07e6797e8fd7c24e4af21 (patch) | |
tree | 2c498950deade6251c7786da0abeee2ab9a0e04c /sci-libs | |
parent | dev-util/cmake: Bump to version 3.15.0_rc4. Removed old. (diff) | |
download | gentoo-c84cc07add2d8a5351d07e6797e8fd7c24e4af21.tar.gz gentoo-c84cc07add2d8a5351d07e6797e8fd7c24e4af21.tar.bz2 gentoo-c84cc07add2d8a5351d07e6797e8fd7c24e4af21.zip |
sci-libs/openblas: add the missing postinst steps and maintainer.
Closes: https://github.com/gentoo/gentoo/pull/12422
Package-Manager: Portage-2.3.52, Repoman-2.3.12
Signed-off-by: Mo Zhou <cdluminate@gmail.com>
Signed-off-by: Benda Xu <heroxbd@gentoo.org>
Diffstat (limited to 'sci-libs')
-rw-r--r-- | sci-libs/openblas/metadata.xml | 4 | ||||
-rw-r--r-- | sci-libs/openblas/openblas-0.3.5.ebuild | 40 |
2 files changed, 34 insertions, 10 deletions
diff --git a/sci-libs/openblas/metadata.xml b/sci-libs/openblas/metadata.xml index a5e019212f0d..987eb126d9c1 100644 --- a/sci-libs/openblas/metadata.xml +++ b/sci-libs/openblas/metadata.xml @@ -5,6 +5,10 @@ <email>sci@gentoo.org</email> <name>Gentoo Science Project</name> </maintainer> + <maintainer type="person"> + <email>lumin@debian.org</email> + <name>Mo Zhou</name> + </maintainer> <longdescription lang="en"> OpenBLAS is an optimized BLAS library based on GotoBLAS2 1.13 BSD version. </longdescription> diff --git a/sci-libs/openblas/openblas-0.3.5.ebuild b/sci-libs/openblas/openblas-0.3.5.ebuild index b41803760ae9..ba14ee30b531 100644 --- a/sci-libs/openblas/openblas-0.3.5.ebuild +++ b/sci-libs/openblas/openblas-0.3.5.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2019 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=7 @@ -14,11 +14,11 @@ IUSE="dynamic openmp pthread serial static-libs eselect-ldso" REQUIRED_USE="?? ( openmp pthread serial )" RDEPEND=" ->=app-eselect/eselect-blas-0.2 ->=app-eselect/eselect-lapack-0.2 +eselect-ldso? ( >=app-eselect/eselect-blas-0.2 + !app-eselect/eselect-cblas + >=app-eselect/eselect-lapack-0.2 ) " -DEPEND="${RDEPEND} - virtual/pkgconfig" +DEPEND="virtual/pkgconfig" PATCHES=( "${FILESDIR}/shared-blas-lapack.patch" ) @@ -69,11 +69,31 @@ src_install () { } pkg_postinst () { - if use eselect-ldso; then - eselect blas add $(get_libdir) \ - "${EROOT}"/usr/$(get_libdir)/blas/openblas openblas - eselect lapack add $(get_libdir) \ - "${EROOT}"/usr/$(get_libdir)/lapack/openblas openblas + use eselect-ldso || return + local libdir=$(get_libdir) me="openblas" + + # check blas + eselect blas add ${libdir} "${EROOT}"/usr/${libdir}/blas/${me} ${me} + local current_blas=$(eselect blas show ${libdir} | cut -d' ' -f2) + if [[ ${current_blas} == "${me}" || -z ${current_blas} ]]; then + eselect blas set ${libdir} ${me} + elog "Current eselect: BLAS/CBLAS ($libdir) -> [${current_blas}]." + else + elog "Current eselect: BLAS/CBLAS ($libdir) -> [${current_blas}]." + elog "To use blas [${me}] implementation, you have to issue (as root):" + elog "\t eselect blas set ${libdir} ${me}" + fi + + # check lapack + eselect lapack add ${libdir} "${EROOT}"/usr/${libdir}/lapack/${me} ${me} + local current_lapack=$(eselect lapack show ${libdir} | cut -d' ' -f2) + if [[ ${current_lapack} == "${me}" || -z ${current_lapack} ]]; then + eselect lapack set ${libdir} ${me} + elog "Current eselect: LAPACK ($libdir) -> [${current_lapack}]." + else + elog "Current eselect: LAPACK ($libdir) -> [${current_lapack}]." + elog "To use lapack [${me}] implementation, you have to issue (as root):" + elog "\t eselect lapack set ${libdir} ${me}" fi } |