From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id C4B28138334 for ; Wed, 26 Jun 2019 03:12:04 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 880C5E0845; Wed, 26 Jun 2019 03:12:03 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 5F092E0845 for ; Wed, 26 Jun 2019 03:12:03 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id A76A53469EE for ; Wed, 26 Jun 2019 03:12:01 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id AB95B55B for ; Wed, 26 Jun 2019 03:11:59 +0000 (UTC) From: "Benda XU" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Benda XU" Message-ID: <1561518698.77adee6db459011c15b367044c0171f61be8b531.heroxbd@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: sci-libs/lapack/ X-VCS-Repository: repo/gentoo X-VCS-Files: sci-libs/lapack/Manifest sci-libs/lapack/lapack-3.8.0.ebuild sci-libs/lapack/metadata.xml X-VCS-Directories: sci-libs/lapack/ X-VCS-Committer: heroxbd X-VCS-Committer-Name: Benda XU X-VCS-Revision: 77adee6db459011c15b367044c0171f61be8b531 X-VCS-Branch: master Date: Wed, 26 Jun 2019 03:11:59 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: fc7e9d10-c638-45dc-8265-00918ab132f9 X-Archives-Hash: 62f50a1669b94db0cc8a8ac084c89f34 commit: 77adee6db459011c15b367044c0171f61be8b531 Author: Mo Zhou gmail com> AuthorDate: Wed Jun 26 02:24:04 2019 +0000 Commit: Benda XU gentoo org> CommitDate: Wed Jun 26 03:11:38 2019 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=77adee6d sci-libs/lapack: new ebuild for lapack that enables runtime switching. This ebuild replaces {blas,cblas,lapack,lapacke}-reference ebuild files. Closes: https://github.com/gentoo/gentoo/pull/12319 Signed-off-by: Mo Zhou gmail.com> Signed-off-by: Benda Xu gentoo.org> sci-libs/lapack/Manifest | 1 + sci-libs/lapack/lapack-3.8.0.ebuild | 88 +++++++++++++++++++++++++++++++++++++ sci-libs/lapack/metadata.xml | 28 ++++++++++++ 3 files changed, 117 insertions(+) diff --git a/sci-libs/lapack/Manifest b/sci-libs/lapack/Manifest new file mode 100644 index 00000000000..fe865c2bdc8 --- /dev/null +++ b/sci-libs/lapack/Manifest @@ -0,0 +1 @@ +DIST lapack-3.8.0.tar.gz 7426094 BLAKE2B 27cd75eea498250382b2df6f5d7dc95fdee8d37b1a0faba5296ca0145ec40a1165a4ecc727aa1647086be6783b50cf475f79cea0f30f541da789051db99b2f37 SHA512 17786cb7306fccdc9b4a242de7f64fc261ebe6a10b6ec55f519deb4cb673cb137e8742aa5698fd2dc52f1cd56d3bd116af3f593a01dcf6770c4dcc86c50b2a7f diff --git a/sci-libs/lapack/lapack-3.8.0.ebuild b/sci-libs/lapack/lapack-3.8.0.ebuild new file mode 100644 index 00000000000..df848e027d5 --- /dev/null +++ b/sci-libs/lapack/lapack-3.8.0.ebuild @@ -0,0 +1,88 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 +CMAKE_MAKEFILE_GENERATOR=emake +inherit cmake-utils + +DESCRIPTION="BLAS,CBLAS,LAPACK,LAPACKE reference implementations" +HOMEPAGE="http://www.netlib.org/lapack/" +SRC_URI="http://www.netlib.org/${PN}/${P}.tar.gz" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86" +IUSE="lapacke doc" +# TODO: static-libs 64bit-index + +RDEPEND=" + >=app-eselect/eselect-blas-0.2 + >=app-eselect/eselect-lapack-0.2 + !app-eselect/eselect-cblas + !sci-libs/blas-reference + !sci-libs/cblas-reference + !sci-libs/lapack-reference + !sci-libs/lapacke-reference + doc? ( app-doc/blas-docs ) + virtual/pkgconfig" +DEPEND="${RDEPEND} + virtual/fortran" + +src_configure() { + local mycmakeargs=( + -DCBLAS=ON + -DLAPACKE=$(usex lapacke) + -DCMAKE_INSTALL_PREFIX="${EPREFIX}"/usr + -DBUILD_SHARED_LIBS=ON + ) + cmake-utils_src_configure +} + +src_install () { + cmake-utils_src_install + + # Create private lib directory for eselect::blas (ld.so.conf) + dodir /usr/$(get_libdir)/blas/reference + dosym ../../libblas.so usr/$(get_libdir)/blas/reference/libblas.so + dosym ../../libblas.so.3 usr/$(get_libdir)/blas/reference/libblas.so.3 + dosym ../../libcblas.so usr/$(get_libdir)/blas/reference/libcblas.so + dosym ../../libcblas.so.3 usr/$(get_libdir)/blas/reference/libcblas.so.3 + + # Create private lib directory for eselect::lapack (ld.so.conf) + dodir /usr/$(get_libdir)/lapack/reference + dosym ../../liblapack.so usr/$(get_libdir)/lapack/reference/liblapack.so + dosym ../../liblapack.so.3 usr/$(get_libdir)/lapack/reference/liblapack.so.3 +} + +pkg_postinst () { + local me=reference libdir=$(get_libdir) + + # check eselect-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 ($libdir) -> [${current_blas}]." + else + elog "Current eselect: BLAS ($libdir) -> [${current_blas}]." + elog "To use blas [${me}] implementation, you have to issue (as root):" + elog "\t eselect blas set ${libdir} ${me}" + fi + + # check eselect-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 +} + +pkg_postrm () { + eselect blas validate + eselect lapack validate +} diff --git a/sci-libs/lapack/metadata.xml b/sci-libs/lapack/metadata.xml new file mode 100644 index 00000000000..7b291ef6bfd --- /dev/null +++ b/sci-libs/lapack/metadata.xml @@ -0,0 +1,28 @@ + + + + + sci@gentoo.org + Gentoo Science Project + + +The BLAS (Basic Linear Algebra Subprograms) are high quality "building +block" routines for performing basic vector and matrix operations. Level 1 +BLAS do vector-vector operations, Level 2 BLAS do matrix-vector operations, +and Level 3 BLAS do matrix-matrix operations. Because the BLAS are +efficient, portable, and widely available, they're commonly used in the +development of high quality linear algebra software, LAPACK for +example. This packages implements the reference FORTRAN 77 library, +the reference C library as a wrapper to the FORTRAN 77 BLAS library. + +LAPACK is a comprehensive library that does linear algebra +operations including matrix inversions, least squared solutions to +linear sets of equations, eigenvector analysis, singular value +decomposition, etc. It is a very comprehensive and reputable package +that has found extensive use in the scientific community. +This package installs the reference FORTRAN 77 implementation from Netlib. + + + Build LAPACKE + +