[gentoo-commits] repo/gentoo:master commit in: sci-libs/fflas-ffpack/files/, sci-libs/fflas-ffpack/

2024-02-10 Thread Michael Orlitzky
commit: 69d2e9c1efa10a04560362d2f079ce366841588c
Author: Michael Orlitzky  gentoo  org>
AuthorDate: Sat Feb 10 17:12:47 2024 +
Commit: Michael Orlitzky  gentoo  org>
CommitDate: Sat Feb 10 22:36:29 2024 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=69d2e9c1

sci-libs/fflas-ffpack: add 2.5.0

Signed-off-by: Michael Orlitzky  gentoo.org>

 sci-libs/fflas-ffpack/Manifest |  1 +
 sci-libs/fflas-ffpack/fflas-ffpack-2.5.0.ebuild| 55 
 .../files/fflas-ffpack-2.5.0-blaslapack.patch  | 75 ++
 3 files changed, 131 insertions(+)

diff --git a/sci-libs/fflas-ffpack/Manifest b/sci-libs/fflas-ffpack/Manifest
index d10a12abc35b..da511b79674d 100644
--- a/sci-libs/fflas-ffpack/Manifest
+++ b/sci-libs/fflas-ffpack/Manifest
@@ -1 +1,2 @@
 DIST fflas-ffpack-2.4.3.tar.gz 1059033 BLAKE2B 
e416429bb426a81cf9c25d54c83380ff9a9d658c711da06e6359d968843d4d9d26cf8389379f9ad4a5cbcee93e0afc9fe0497bb7a8f190e0c72c0b1f7b67de18
 SHA512 
c7620ba5a92e4114a581a6bea32267f9d5a9f0eb7e23fc0a7a97ce4b8124bb7b29f89ff2ad6ad270d97c76489625b57a354e581905b74ee57b35f4ca3e196a44
+DIST fflas-ffpack-2.5.0.tar.gz 1098354 BLAKE2B 
34b0cd218e83a71c6540b1768c8231246a0dc360eb7e2353a923b5870d228e702291de14b0dc3e7c5055727fbd62e2bc1bd1d2ac432dd99df978a1edb513bfc0
 SHA512 
6753022f27d354160f5eb436c713002f61d24e9a942f2463e36bf324b19ec096f34dd9cacb8529ba566f245f88fa303dcfb448a40d0c39d340f7c337cd1788a4

diff --git a/sci-libs/fflas-ffpack/fflas-ffpack-2.5.0.ebuild 
b/sci-libs/fflas-ffpack/fflas-ffpack-2.5.0.ebuild
new file mode 100644
index ..dda1212a776f
--- /dev/null
+++ b/sci-libs/fflas-ffpack/fflas-ffpack-2.5.0.ebuild
@@ -0,0 +1,55 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools toolchain-funcs
+
+DESCRIPTION="Library for dense linear algebra over word-size finite fields"
+HOMEPAGE="https://linbox-team.github.io/fflas-ffpack/;
+SRC_URI="https://github.com/linbox-team/${PN}/releases/download/v${PV}/${P}.tar.gz;
+
+LICENSE="LGPL-2.1+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos"
+IUSE="openmp"
+
+# Our autotools patch hacks in PKG_CHECK_MODULES calls.
+BDEPEND="virtual/pkgconfig"
+DEPEND="virtual/cblas
+   virtual/blas
+   virtual/lapack
+   dev-libs/gmp[cxx(+)]
+   =sci-libs/givaro-4.2*"
+RDEPEND="${DEPEND}"
+
+PATCHES=(
+   "${FILESDIR}/${PN}-2.5.0-blaslapack.patch"
+   "${FILESDIR}/${PN}-2.4.3-no-test-echelon.patch"
+)
+
+pkg_pretend() {
+   [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
+}
+
+pkg_setup() {
+   [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
+}
+
+src_prepare() {
+   default
+   eautoreconf
+}
+
+src_configure() {
+   tc-export PKG_CONFIG
+
+   econf \
+   --enable-precompilation \
+   $(use_enable openmp)
+}
+
+src_install() {
+   default
+   find "${ED}" -type f -name '*.la' -delete || die
+}

diff --git a/sci-libs/fflas-ffpack/files/fflas-ffpack-2.5.0-blaslapack.patch 
b/sci-libs/fflas-ffpack/files/fflas-ffpack-2.5.0-blaslapack.patch
new file mode 100644
index ..609aa034438d
--- /dev/null
+++ b/sci-libs/fflas-ffpack/files/fflas-ffpack-2.5.0-blaslapack.patch
@@ -0,0 +1,75 @@
+From 8e350d3f47a1785eb4eea83dee43c596d6399459 Mon Sep 17 00:00:00 2001
+From: Michael Orlitzky 
+Date: Sat, 10 Feb 2024 07:30:37 -0500
+Subject: [PATCH] configure.ac,fflas-ffpack-config.in: use pkg-config to check
+ for blas
+
+Patching configure.ac for this is ugly, but in this case it is
+actually the simplest way to get sane behavior out of the blas/lapack
+check.
+---
+ configure.ac   | 29 ++---
+ fflas-ffpack-config.in |  4 ++--
+ 2 files changed, 20 insertions(+), 13 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 5390bcf..2f5fc46 100644
+--- a/configure.ac
 b/configure.ac
+@@ -133,17 +133,24 @@ FF_CHECK_GIVARO_USABILITY()
+ 
+ AS_ECHO([---])
+ 
+-BLAS_FOUND=false
+-
+-FF_CHECK_BLAS_CFLAGS
+-FF_CHECK_BLAS_LIBS
+-FF_CHECK_MKL
+-FF_CHECK_USER_BLAS
+-FF_CHECK_USER_LAPACK
+-
+-FF_OPENBLAS_NUM_THREADS
+-
+-# FF_CHECK_CUDA
++PKG_PROG_PKG_CONFIG
++
++PKG_CHECK_MODULES([BLAS], [cblas blas],[
++AC_DEFINE(HAVE_BLAS,1,[Define if BLAS is installed])
++AC_DEFINE(HAVE_CBLAS,1,[Define if C interface to BLAS is installed])
++HAVE_BLAS=yes
++BLAS_PATH=""
++CBLAS_LIBS="${BLAS_LIBS}"
++AC_SUBST(BLAS_LIBS)
++AC_SUBST(CBLAS_LIBS)
++AC_SUBST(BLAS_CFLAGS)
++AC_SUBST(BLAS_PATH)])
++
++PKG_CHECK_MODULES([LAPACK], [lapack],[
++AC_DEFINE(HAVE_LAPACK,1,[Define if LAPACK is installed])
++AC_SUBST(LAPACK_LIBS)])
++
++AM_CONDITIONAL(FFLASFFPACK_HAVE_LAPACK,  test "x$HAVE_LAPACK" == "x1")
+ 
+ AS_ECHO([---])
+ 
+diff --git a/fflas-ffpack-config.in b/fflas-ffpack-config.in

[gentoo-commits] repo/gentoo:master commit in: sci-libs/fflas-ffpack/files/, sci-libs/fflas-ffpack/

2021-08-16 Thread Michael Orlitzky
commit: 3e527a3041fd7e63f822b813a00201eccf235ea0
Author: Michael Orlitzky  gentoo  org>
AuthorDate: Tue Aug 17 01:23:42 2021 +
Commit: Michael Orlitzky  gentoo  org>
CommitDate: Tue Aug 17 02:05:58 2021 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3e527a30

sci-libs/fflas-ffpack: add a patch to disable test-fgesv.

This test is flaky; disable it with a patch for now.

Closes: https://bugs.gentoo.org/807100
Package-Manager: Portage-3.0.20, Repoman-3.0.3
Signed-off-by: Michael Orlitzky  gentoo.org>

 sci-libs/fflas-ffpack/fflas-ffpack-2.4.3-r2.ebuild |  3 +-
 .../files/fflas-ffpack-2.4.3-no-test-fgesv.patch   | 37 ++
 2 files changed, 39 insertions(+), 1 deletion(-)

diff --git a/sci-libs/fflas-ffpack/fflas-ffpack-2.4.3-r2.ebuild 
b/sci-libs/fflas-ffpack/fflas-ffpack-2.4.3-r2.ebuild
index b97b581707a..d13e3c0f530 100644
--- a/sci-libs/fflas-ffpack/fflas-ffpack-2.4.3-r2.ebuild
+++ b/sci-libs/fflas-ffpack/fflas-ffpack-2.4.3-r2.ebuild
@@ -25,10 +25,11 @@ RDEPEND="${DEPEND}"
 
 # The no-test-echelon patch works around a test failure that may
 # eventually be fixed upstream. Gentoo bug 725446 and upstream
-# Github issue 282.
+# Github issue 282. Same for test-fgesv (bug 807100).
 PATCHES=(
"${FILESDIR}/${PN}-2.3.2-blaslapack.patch"
"${FILESDIR}/${P}-no-test-echelon.patch"
+   "${FILESDIR}/${P}-no-test-fgesv.patch"
"${FILESDIR}/${P}-fix-internal-linking.patch"
"${FILESDIR}/${P}-no-fabi-version.patch"
 )

diff --git a/sci-libs/fflas-ffpack/files/fflas-ffpack-2.4.3-no-test-fgesv.patch 
b/sci-libs/fflas-ffpack/files/fflas-ffpack-2.4.3-no-test-fgesv.patch
new file mode 100644
index 000..a995c051856
--- /dev/null
+++ b/sci-libs/fflas-ffpack/files/fflas-ffpack-2.4.3-no-test-fgesv.patch
@@ -0,0 +1,37 @@
+From 3f7a5f601e73491ac7c39cc848fa98fe6224978c Mon Sep 17 00:00:00 2001
+From: Michael Orlitzky 
+Date: Mon, 16 Aug 2021 21:19:39 -0400
+Subject: [PATCH 1/1] tests/Makefile.am: disable test-fgesv.
+
+This test can fail on Gentoo, and has been reported upstream. In the
+meantime, having it fail on end users is no good, so we disable it.
+
+Gentoo-bug: https://bugs.gentoo.org/807100
+Upstream-bug: https://github.com/linbox-team/fflas-ffpack/issues/341
+---
+ tests/Makefile.am | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/tests/Makefile.am b/tests/Makefile.am
+index 62e92bc..83cf71f 100755
+--- a/tests/Makefile.am
 b/tests/Makefile.am
+@@ -63,7 +63,6 @@ BASIC_TESTS =   \
+   test-io  \
+   test-maxdelayeddim \
+   test-solve \
+-  test-fgesv \
+   test-simd \
+   test-fgemv \
+   test-nullspace \
+@@ -143,7 +142,6 @@ test_ftrtri_SOURCES= test-ftrtri.C
+ #  test_fullranksubmatrix_SOURCES = test-fullranksubmatrix.C
+ #  test_invert_SOURCES= test-invert.C
+ #  test_krylov_elim_SOURCES   = test-krylov-elim.C
+-test_fgesv_SOURCES = test-fgesv.C
+ #  test_frobenius_SOURCES = test-frobenius.C
+ test_nullspace_SOURCES = test-nullspace.C
+ test_fdot_SOURCES = test-fdot.C
+-- 
+2.31.1
+



[gentoo-commits] repo/gentoo:master commit in: sci-libs/fflas-ffpack/files/, sci-libs/fflas-ffpack/

2020-04-03 Thread Michael Orlitzky
commit: 8db3670e7902795f2ae61d64b1930a946e5b2efc
Author: Michael Orlitzky  gentoo  org>
AuthorDate: Wed Apr  1 23:59:53 2020 +
Commit: Michael Orlitzky  gentoo  org>
CommitDate: Fri Apr  3 16:03:48 2020 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8db3670e

sci-libs/fflas-ffpack: new package for finite-field linear algebra.

This is a straightforward import of the latest fflas-ffpack-2.4.3.ebuild
that François Bissey has been maintaining in the sage-on-gentoo overlay,
with only a few minor changes:

  * I added a "+" to the LICENSE to match the upstream LGPL-2.1+.

  * I switched the openmp check to use tc-check-openmp() conditionally
on the MERGE_TYPE variable.

  * Added BDEPEND="virtual/pkgconfig" since we patch in a call to
PKG_CHECK_MODULES.

I also removed a warning about build failures with USE=openmp. From what
I can tell, this stems from an older report (upstream Github issue 48)
using gcc-4.9.x that was never fully debugged. If the problems persist,
we can revisit that report, or just mask the flag.

Closes: https://bugs.gentoo.org/show_bug.cgi?id=715678
Package-Manager: Portage-2.3.89, Repoman-2.3.20
Signed-off-by: Michael Orlitzky  gentoo.org>

 sci-libs/fflas-ffpack/Manifest |  1 +
 sci-libs/fflas-ffpack/fflas-ffpack-2.4.3.ebuild| 62 +++
 .../files/fflas-ffpack-2.3.2-blaslapack.patch  | 90 ++
 sci-libs/fflas-ffpack/metadata.xml | 37 +
 4 files changed, 190 insertions(+)

diff --git a/sci-libs/fflas-ffpack/Manifest b/sci-libs/fflas-ffpack/Manifest
new file mode 100644
index 000..d10a12abc35
--- /dev/null
+++ b/sci-libs/fflas-ffpack/Manifest
@@ -0,0 +1 @@
+DIST fflas-ffpack-2.4.3.tar.gz 1059033 BLAKE2B 
e416429bb426a81cf9c25d54c83380ff9a9d658c711da06e6359d968843d4d9d26cf8389379f9ad4a5cbcee93e0afc9fe0497bb7a8f190e0c72c0b1f7b67de18
 SHA512 
c7620ba5a92e4114a581a6bea32267f9d5a9f0eb7e23fc0a7a97ce4b8124bb7b29f89ff2ad6ad270d97c76489625b57a354e581905b74ee57b35f4ca3e196a44

diff --git a/sci-libs/fflas-ffpack/fflas-ffpack-2.4.3.ebuild 
b/sci-libs/fflas-ffpack/fflas-ffpack-2.4.3.ebuild
new file mode 100644
index 000..4115dc61ace
--- /dev/null
+++ b/sci-libs/fflas-ffpack/fflas-ffpack-2.4.3.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools toolchain-funcs
+
+DESCRIPTION="Library for dense linear algebra over word-size finite fields"
+HOMEPAGE="https://linbox-team.github.io/fflas-ffpack/;
+SRC_URI="https://github.com/linbox-team/${PN}/releases/download/${PV}/${P}.tar.gz;
+
+LICENSE="LGPL-2.1+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
+IUSE="static-libs openmp cpu_flags_x86_fma3 cpu_flags_x86_fma4 
cpu_flags_x86_sse3 cpu_flags_x86_ssse3 cpu_flags_x86_sse4_1 
cpu_flags_x86_sse4_2 cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_x86_avx512f 
cpu_flags_x86_avx512dq cpu_flags_x86_avx512vl"
+
+# Our autotools patch hacks in PKG_CHECK_MODULES calls.
+BDEPEND="virtual/pkgconfig"
+DEPEND="virtual/cblas
+   virtual/blas
+   virtual/lapack
+   dev-libs/gmp[cxx]
+   =sci-libs/givaro-4.1*"
+RDEPEND="${DEPEND}"
+
+PATCHES=( "${FILESDIR}/${PN}-2.3.2-blaslapack.patch" )
+
+pkg_pretend() {
+   [[ "${MERGE_TYPE}" != "binary" ]] && use openmp && tc-check-openmp
+}
+
+pkg_setup(){
+   tc-export PKG_CONFIG
+}
+
+src_prepare(){
+   default
+   eautoreconf
+}
+
+src_configure() {
+   econf \
+   --enable-precompilation \
+   $(use_enable openmp) \
+   $(use_enable cpu_flags_x86_fma3 fma) \
+   $(use_enable cpu_flags_x86_fma4 fma4) \
+   $(use_enable cpu_flags_x86_sse3 sse3) \
+   $(use_enable cpu_flags_x86_ssse3 ssse3) \
+   $(use_enable cpu_flags_x86_sse4_1 sse41) \
+   $(use_enable cpu_flags_x86_sse4_2 sse42) \
+   $(use_enable cpu_flags_x86_avx avx) \
+   $(use_enable cpu_flags_x86_avx2 avx2) \
+   $(use_enable cpu_flags_x86_avx512f avx512f) \
+   $(use_enable cpu_flags_x86_avx512dq avx512dq) \
+   $(use_enable cpu_flags_x86_avx512vl avx512vl) \
+   $(use_enable static-libs static)
+}
+
+src_install(){
+   default
+   find "${ED}" -name '*.la' -delete || die
+}

diff --git a/sci-libs/fflas-ffpack/files/fflas-ffpack-2.3.2-blaslapack.patch 
b/sci-libs/fflas-ffpack/files/fflas-ffpack-2.3.2-blaslapack.patch
new file mode 100644
index 000..3154a261819
--- /dev/null
+++ b/sci-libs/fflas-ffpack/files/fflas-ffpack-2.3.2-blaslapack.patch
@@ -0,0 +1,90 @@
+diff --git a/configure.ac b/configure.ac
+index 5b46b18..5e0264a 100644
+--- a/configure.ac
 b/configure.ac
+@@ -248,49 +248,24 @@ dnl echo 
'**
+ dnl exit 1
+ dnl ])
+ 
+-BLAS_FOUND=false
+-