summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Maier <tamiko@gentoo.org>2024-07-04 11:29:59 -0500
committerMatthias Maier <tamiko@gentoo.org>2024-07-04 11:33:20 -0500
commit13c64693603ce9596168286b3bd51340b3e423fd (patch)
tree0da87139338345455f14e5cf35c8ebd7105a98d2 /sci-libs/scalapack
parentsys-power/upower: drop 0.99.20, 1.90.2 (diff)
downloadgentoo-13c64693603ce9596168286b3bd51340b3e423fd.tar.gz
gentoo-13c64693603ce9596168286b3bd51340b3e423fd.tar.bz2
gentoo-13c64693603ce9596168286b3bd51340b3e423fd.zip
sci-libs/scalapack: add 2.2.0_p20240704
Signed-off-by: Matthias Maier <tamiko@gentoo.org>
Diffstat (limited to 'sci-libs/scalapack')
-rw-r--r--sci-libs/scalapack/Manifest1
-rw-r--r--sci-libs/scalapack/scalapack-2.2.0_p20240704.ebuild83
2 files changed, 84 insertions, 0 deletions
diff --git a/sci-libs/scalapack/Manifest b/sci-libs/scalapack/Manifest
index 7d24374ac476..0f85a555538f 100644
--- a/sci-libs/scalapack/Manifest
+++ b/sci-libs/scalapack/Manifest
@@ -1,2 +1,3 @@
DIST scalapack-2.1.0-gcc10.patch 231026 BLAKE2B dacecca8307cd2bf7a20e6453fb17bc1f5a3f2926b6d8f3b89f7f8d34993368574804f0427f228de4525f2b2d73105de561588ba5a4d2fb609d5ed035f51ddc9 SHA512 a11057599639c167e907f8e4d45204174fd326e2ffb9e2d05533db23d8e2dd8cfc1d37f06d5502baa3d5714092fbf4638cf4d9fea84ca9d4fb150e21cc57861e
DIST scalapack-2.1.0.tgz 5307441 BLAKE2B 4aea055fc3e437bce7108d1555e93c50109bcfe84354903fd711509eedbe686349fda4030e2fa70faf1a9e7e3255e46e48c32b96a2916af6812b8aebceb750c2 SHA512 0e77fb535ebcc28e2d97499ef4bd5161f76ca0ba4a3e308c26ce5071cfc4be4f3814262f3fb38f378ce0b5b31c0913432fea00a1e9e3f7717b853d1182bdf5b4
+DIST scalapack-2.2.0_p20240704.tar.gz 4776451 BLAKE2B 927f6af5196c350cb48bdc0e2a6af40e8212045150b976367852926decabafa13dd5a9b680ad4aa1fce051b5fe3987ee9c034042ffdbba7fde4175847313f96b SHA512 ddd37cd4291f00fbdd9c27d23849238d2f32807b0fba86301cb73a6463f1b4feaf97a5c492ab6ac1c01139f0d1d7d06af898ec90366e5812b6524538812a53ea
diff --git a/sci-libs/scalapack/scalapack-2.2.0_p20240704.ebuild b/sci-libs/scalapack/scalapack-2.2.0_p20240704.ebuild
new file mode 100644
index 000000000000..ce98c63fc31a
--- /dev/null
+++ b/sci-libs/scalapack/scalapack-2.2.0_p20240704.ebuild
@@ -0,0 +1,83 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake flag-o-matic fortran-2 toolchain-funcs
+
+# 2024/07/04 master branch containing 45 commits on top of 2.2.0
+COMMIT_HASH="0234af94c6578c53ac4c19f2925eb6e5c4ad6f0f"
+
+DESCRIPTION="Subset of LAPACK routines redesigned for heterogenous (MPI) computing"
+HOMEPAGE="https://www.netlib.org/scalapack/"
+SRC_URI="https://github.com/Reference-ScaLAPACK/${PN}//archive/${COMMIT_HASH}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}/${PN}-${COMMIT_HASH}"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~riscv ~x86 ~amd64-linux ~x86-linux"
+IUSE="static-libs test"
+RESTRICT="!test? ( test )"
+
+BDEPEND="virtual/pkgconfig"
+RDEPEND="
+ virtual/lapack
+ virtual/mpi[fortran]
+"
+DEPEND="${RDEPEND}"
+
+PATCHES=( )
+
+src_prepare() {
+ cmake_src_prepare
+
+ if use static-libs; then
+ mkdir "${WORKDIR}/${PN}_static" || die
+ fi
+ # mpi does not have a pc file
+ sed -i -e 's/mpi//' scalapack.pc.in || die
+}
+
+src_configure() {
+ # -Werror=strict-aliasing
+ # https://bugs.gentoo.org/862924
+ # https://github.com/Reference-ScaLAPACK/scalapack/issues/95
+ #
+ # Do not trust it for LTO either.
+ append-flags -fno-strict-aliasing
+ filter-lto
+
+ scalapack_configure() {
+ local mycmakeargs=(
+ -DUSE_OPTIMIZED_LAPACK_BLAS=ON
+ -DBLAS_LIBRARIES="$($(tc-getPKG_CONFIG) --libs blas)"
+ -DLAPACK_LIBRARIES="$($(tc-getPKG_CONFIG) --libs lapack)"
+ -DBUILD_TESTING=$(usex test)
+ $@
+ )
+ cmake_src_configure
+ }
+
+ scalapack_configure -DBUILD_SHARED_LIBS=ON -DBUILD_STATIC_LIBS=OFF
+ use static-libs && \
+ CMAKE_BUILD_DIR="${WORKDIR}/${PN}_static" scalapack_configure \
+ -DBUILD_SHARED_LIBS=OFF -DBUILD_STATIC_LIBS=ON
+}
+
+src_compile() {
+ cmake_src_compile
+ use static-libs && \
+ CMAKE_BUILD_DIR="${WORKDIR}/${PN}_static" cmake_src_compile
+}
+
+src_install() {
+ cmake_src_install
+ use static-libs && \
+ CMAKE_BUILD_DIR="${WORKDIR}/${PN}_static" cmake_src_install
+
+ insinto /usr/include/blacs
+ doins BLACS/SRC/*.h
+
+ insinto /usr/include/scalapack
+ doins PBLAS/SRC/*.h
+}