diff options
author | V3n3RiX <venerix@koprulu.sector> | 2024-03-03 05:42:21 +0000 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2024-03-03 05:42:21 +0000 |
commit | f1801aa7be2329c07c4c2bd7522e03522b34c437 (patch) | |
tree | 921f3b21629f755c7e3cd4490e3d459026b1b74e /sci-libs | |
parent | c8042d10e135808d5f2b48867bc291e00664b99b (diff) |
gentoo auto-resync : 03:03:2024 - 05:42:20
Diffstat (limited to 'sci-libs')
-rw-r--r-- | sci-libs/Manifest.gz | bin | 44781 -> 44779 bytes | |||
-rw-r--r-- | sci-libs/lapack/Manifest | 2 | ||||
-rw-r--r-- | sci-libs/lapack/files/lapack-3.12.0-correct-64bit-interface.patch | 38 | ||||
-rw-r--r-- | sci-libs/lapack/lapack-3.12.0-r1.ebuild | 115 |
4 files changed, 155 insertions, 0 deletions
diff --git a/sci-libs/Manifest.gz b/sci-libs/Manifest.gz Binary files differindex 7eff5c3b913b..50595a38b5bb 100644 --- a/sci-libs/Manifest.gz +++ b/sci-libs/Manifest.gz diff --git a/sci-libs/lapack/Manifest b/sci-libs/lapack/Manifest index 2aa798ff84cb..f90eb0b5169a 100644 --- a/sci-libs/lapack/Manifest +++ b/sci-libs/lapack/Manifest @@ -1,7 +1,9 @@ +AUX lapack-3.12.0-correct-64bit-interface.patch 1597 BLAKE2B 2ff922afcd0611734df218537d7729b38fe0088e198f8bed9e7dd1c68fe559c3515b5d4a532c846a3dfd3b0a7e59fe9fef8d88ab42b6dc567753029b84ab4a6d SHA512 911a0306ed059c224d523937ea945398141faee3a6fbcc86ce7e148a1b662483a510902b7e9110e70ff0b953c4ec47efa37a22049da797f43a6154ac0cc257a8 DIST lapack-3.10.1.tar.gz 7632257 BLAKE2B f2653239029ed9c136173fc2e54773a785ad3e469d581ca2b7f6a72697e6bb9d22879edaf8327ada510df259c08fe984202d14cb3860c0d2a711eb55a1cc11dd SHA512 0500bbbb48483208c0a35b74972ff0059c389da6032824a2079637266a99fa980882eedf7f1fc490219ee4ff27812ac8c6afe118e25f40a9c2387e7b997762fb DIST lapack-3.11.tar.gz 7723909 BLAKE2B b3f8ec8cd439d790ba5869b8b071fe924a4ac53328bce77d46032602b45353670966ed9223324a0780aabc2e95624f439e03f90a89586f96afbe1374c4261bc5 SHA512 d2f23c5f6ae14fb868312a25235459bd0c04f4b43b82a5ade01314776ade9a75dc518a457eb58595f29f64cb0bb86f1a12ce8beea3ec87ef9caf49493ce29fb3 DIST lapack-3.12.0.tar.gz 7933607 BLAKE2B dafb1f9a717f2cbc00a26f8cff2c7a1ebb720714fe6d7bd5fabb511a2f4af317165814340864c9d601e4e16c7762f643fbbafc058170ebcdc6529a9b4f2d70b6 SHA512 f8f3c733a0221be0b3f5618235408ac59cbd4e5f1c4eab5f509b831a6ec6a9ef14b8849aa6ea10810df1aff90186ca454d15e9438d1dd271c2449d42d3da9dda EBUILD lapack-3.10.1.ebuild 2984 BLAKE2B f290299c23d29e927d96cbb42b6f19fa5fa8a74bfcb40628220e0f080d60e9d94ecc0d7126acaf8753c9cbd94c5bd4ea55c986e3fef2f698a2d7a64757564201 SHA512 5f415f31998581ef18eaae12ad2bc59a023405327d0fb60aeb632c42ecd19ee9301020c0e4bfacafd72958ba65254dbdfe63d0f7c123e3848d2d7e8694c80823 EBUILD lapack-3.11.ebuild 3438 BLAKE2B 53233fc499ed64ea2894de24a98fe9a3f9f4be980457640b9f808dff92529d4658f649df3821d66293c5a49b3582d50eaa43e704327bdecacd91df39210adb3c SHA512 f12cbd959ccbfadbbceb5ce37a0237dc69f31f7e80a389ed17f9ec4ca76a60af49d51eb6bf9bd5d5d9e62678b2b7047378bd279e88fa54336aa0b46bd0124b8e +EBUILD lapack-3.12.0-r1.ebuild 3690 BLAKE2B f3e0cd5dbf6b1e0b75d957ba4ac8c0bd5a89061b8f763f2ea7e1d4a1d820fca7dbf10ebdce285edb01b7265855fa04ad720727392a298c721dbdbf2f39cac06a SHA512 a7440188f53b3d146b4668864d7516f3cde52f836d543fda18c971025859e62a13705810fa9bbef80659e7e3d7269532ea2852cffab2a8a892d8023f73ef7147 EBUILD lapack-3.12.0.ebuild 3547 BLAKE2B 4a5c295efd2d0bb7edc523bede66a9fb7d7e10d95183a3cbd22c17f84c6c72d167f6228f585e8ba37ea76875ebffeea240602b41b68c37d64a46c2dc649fb166 SHA512 da82c1a22d1aa446f89f059c4bb992dc9c549ee96fd805cfff41eec2e1a730e6eaea3c060aede4163a46ee648d2b38ebc85e21ae0c738f146e427249c4fd89f9 MISC metadata.xml 1583 BLAKE2B 8db26f3744a6ee5f88f7ad37e749843eb8b63cd11af4182dd9d6408a854a5b060a651abd5f2f2098252a38b68b34c464a99f9654be9e6cba8f444eff23e4e297 SHA512 d8e8eb140e1a05f297b9e6edcc9aeb48e958baa7741be2a693ea4fca1a6d3f66a60d72c4c61e2dac8b8efd6210daf10ea9350fdbcfbaf801ac6366d0025ad2ca diff --git a/sci-libs/lapack/files/lapack-3.12.0-correct-64bit-interface.patch b/sci-libs/lapack/files/lapack-3.12.0-correct-64bit-interface.patch new file mode 100644 index 000000000000..c9c9479f4522 --- /dev/null +++ b/sci-libs/lapack/files/lapack-3.12.0-correct-64bit-interface.patch @@ -0,0 +1,38 @@ +From 26db2da3eb84856d997e05caf9904a6b56eac1e8 Mon Sep 17 00:00:00 2001 +From: Simon Maertens <simon@slmaertens.dev> +Date: Wed, 29 Nov 2023 14:30:30 +0000 +Subject: [PATCH] Fixed Fortran compiler flags check for nagfor compiler and + usage in CBLAS target + +--- + CBLAS/CMakeLists.txt | 4 ++++ + CMAKE/CheckLAPACKCompilerFlags.cmake | 1 + + 2 files changed, 5 insertions(+) + +diff --git a/CBLAS/CMakeLists.txt b/CBLAS/CMakeLists.txt +index c276f7da3d..b01d795af9 100644 +--- a/CBLAS/CMakeLists.txt ++++ b/CBLAS/CMakeLists.txt +@@ -14,6 +14,10 @@ if(CMAKE_Fortran_COMPILER) + FortranCInterface_HEADER(${LAPACK_BINARY_DIR}/include/cblas_mangling.h + MACRO_NAMESPACE "F77_" + SYMBOL_NAMESPACE "F77_") ++ ++ # Check for any necessary platform specific compiler flags ++ include(CheckLAPACKCompilerFlags) ++ CheckLAPACKCompilerFlags() + endif() + if(NOT FortranCInterface_GLOBAL_FOUND OR NOT FortranCInterface_MODULE_FOUND) + message(WARNING "Reverting to pre-defined include/cblas_mangling.h") +diff --git a/CMAKE/CheckLAPACKCompilerFlags.cmake b/CMAKE/CheckLAPACKCompilerFlags.cmake +index ecb5009ae5..653b817583 100644 +--- a/CMAKE/CheckLAPACKCompilerFlags.cmake ++++ b/CMAKE/CheckLAPACKCompilerFlags.cmake +@@ -177,6 +177,7 @@ elseif( CMAKE_Fortran_COMPILER_ID STREQUAL "NAG" ) + endif() + + # Suppress compiler banner and summary ++ include(CheckFortranCompilerFlag) + check_fortran_compiler_flag("-quiet" _quiet) + if( _quiet AND NOT ("${CMAKE_Fortran_FLAGS}" MATCHES "[-/]quiet") ) + set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -quiet") diff --git a/sci-libs/lapack/lapack-3.12.0-r1.ebuild b/sci-libs/lapack/lapack-3.12.0-r1.ebuild new file mode 100644 index 000000000000..9ccdd64e8562 --- /dev/null +++ b/sci-libs/lapack/lapack-3.12.0-r1.ebuild @@ -0,0 +1,115 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +# Some additional tests are run if Python is found +PYTHON_COMPAT=( python3_{10..11} ) +inherit cmake fortran-2 python-any-r1 + +DESCRIPTION="BLAS, CBLAS, LAPACK, LAPACKE reference implementations" +HOMEPAGE="https://www.netlib.org/lapack/" +SRC_URI="https://github.com/Reference-LAPACK/lapack/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos" +# TODO: static-libs 64bit-index +IUSE="lapacke deprecated doc eselect-ldso test" +RESTRICT="!test? ( test )" + +RDEPEND=" + !app-eselect/eselect-cblas + virtual/fortran + eselect-ldso? ( + >=app-eselect/eselect-blas-0.2 + >=app-eselect/eselect-lapack-0.2 + ) + doc? ( app-doc/blas-docs ) +" +DEPEND="${RDEPEND}" +BDEPEND=" + virtual/pkgconfig + test? ( ${PYTHON_DEPS} ) +" + +PATCHES=( + # fix -Werror=lto-type-mismatch caused by a bug that breaks + # the 64-bit interface for cblas + # https://github.com/Reference-LAPACK/lapack/issues/990#issuecomment-1973258284 + # https://bugs.gentoo.org/878891 + "${FILESDIR}"/lapack-3.12.0-correct-64bit-interface.patch +) + +pkg_setup() { + fortran-2_pkg_setup + use test && python-any-r1_pkg_setup +} + +src_configure() { + local mycmakeargs=( + -DCBLAS=ON + -DLAPACKE=$(usex lapacke) + -DBUILD_DEPRECATED=$(usex deprecated) + -DBUILD_SHARED_LIBS=ON + -DBUILD_TESTING=$(usex test) + -DLAPACK_TESTING_USE_PYTHON=$(usex test) + # Breaks cross + -DTEST_FORTRAN_COMPILER=OFF + ) + + cmake_src_configure +} + +src_install() { + cmake_src_install + + use eselect-ldso || return + # Create private lib directory for eselect::blas (ld.so.conf) + dodir /usr/$(get_libdir)/blas/reference + dosym -r /usr/$(get_libdir)/libblas.so /usr/$(get_libdir)/blas/reference/libblas.so + dosym -r /usr/$(get_libdir)/libblas.so.3 /usr/$(get_libdir)/blas/reference/libblas.so.3 + dosym -r /usr/$(get_libdir)/libcblas.so /usr/$(get_libdir)/blas/reference/libcblas.so + dosym -r /usr/$(get_libdir)/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 -r /usr/$(get_libdir)/liblapack.so /usr/$(get_libdir)/lapack/reference/liblapack.so + dosym -r /usr/$(get_libdir)/liblapack.so.3 /usr/$(get_libdir)/lapack/reference/liblapack.so.3 +} + +pkg_postinst() { + use eselect-ldso || return + + local me=reference libdir=$(get_libdir) + # check eselect-blas + eselect blas add ${libdir} "${EPREFIX}"/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} "${EPREFIX}"/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() { + use eselect-ldso || return + + eselect blas validate + eselect lapack validate +} |