summaryrefslogtreecommitdiff
path: root/sci-libs/m4rie
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2025-01-22 06:42:31 +0000
committerV3n3RiX <venerix@koprulu.sector>2025-01-22 06:42:31 +0000
commit564687d289b862b8b079569a45a2d39d7b8c3585 (patch)
tree9ec555a8f8005c24f9d8198ba4941cc6f002a413 /sci-libs/m4rie
parent30c47f3c341cb37e4808aaa3842b679d0ca420e8 (diff)
gentoo auto-resync : 22:01:2025 - 06:42:31
Diffstat (limited to 'sci-libs/m4rie')
-rw-r--r--sci-libs/m4rie/Manifest3
-rw-r--r--sci-libs/m4rie/files/m4rie-20250103-pkgconfig-r1.patch40
-rw-r--r--sci-libs/m4rie/m4rie-20250103-r1.ebuild41
3 files changed, 84 insertions, 0 deletions
diff --git a/sci-libs/m4rie/Manifest b/sci-libs/m4rie/Manifest
index 512ebbbde6e1..2f4e0f04add5 100644
--- a/sci-libs/m4rie/Manifest
+++ b/sci-libs/m4rie/Manifest
@@ -1,4 +1,7 @@
AUX m4rie-20200115-link-libm.patch 654 BLAKE2B af7ff7b56c14078817b6a12a8184c81e1547a0c75b682d7398a040645be7e392ce3f923be56110bbf282f0ed729aa5ea2fadb23d6815aa96370d99ba29f7b2b6 SHA512 6d85c998f0f2f85c9f3cb77861318eab31b38bcb88ff3133fc3bbef0492fcb412e832d92f5d76c63aa3c979cd21e55164a2a53bc08c67da6f22bd1d27d08e883
+AUX m4rie-20250103-pkgconfig-r1.patch 1438 BLAKE2B a52cccee4862232e810b671db49f7f8ac3c8635e5e455a89dabd320314b5796cc6c2c78f35563d3e93527750ba980fa50b2c71a79dd91ca865944696f8a3c0b7 SHA512 62880c1b956e98b638538543e329a3a30d8e7b634305033497786fb30c28c49ed7c1e0710be9aca14666ca68dbd887a096be7d26ededb564860498b0b342c4af
DIST m4rie-20200115.tar.gz 500702 BLAKE2B d8b1506ef9902def6577851a97dd6f7da986dce39b3250f9f9b66f9caf8f811568b7975165fb75b6b8ab3c9faf65d890f7c2254725224266f1250a0bcf18a464 SHA512 22c990cf06de9ac790f82f48e498b2bfc87fdf6834257f4e4a4c44e2446b4226438d21692d654008b58df36d8da746bba04dcf1a3d50e34ccf8c678efd5b642b
+DIST release-20250103.tar.gz 167745 BLAKE2B b4f76e51ef9561ce7fc10c0fc0f50c8ebff1c65c9e4c51d0f120db48a9b4b4417057c2bb919b6a4d1ba23f68179c59e2a5d97063063654723f210a5d10d0e5ce SHA512 8fd80fa265d234101ee56f464a59ce5aaf0f3c600e70ee9495ec490d06b758e0073a084474ad72d79d8ade5ac4421c53ed6b12cbaaaeda96287d94137c8c61b1
EBUILD m4rie-20200115-r1.ebuild 935 BLAKE2B 5161268c8b5a0afd48a3f3c93fcf3094abdfead19c2ed043dd4ea1879ee149937ab009875ef5ed4bd16935141d9300824767a699c551464dbc51cefa718a50f7 SHA512 b0e42e030ccf6ac85ee90e5caae476d0a2112e7a82f2e66f15eed3f2bff9c3694bbe135c20a8f51bd4b7f60cd05364c6d9211597f3fb03945a882c93a0527426
+EBUILD m4rie-20250103-r1.ebuild 927 BLAKE2B 6a514951b76556e7a5c9efede32f12403b24866415211af89448001c084460bd87c43d064c412eca619685d967b3b59b9b01c18da743e5efccbbfa108124ef8f SHA512 2c73f7f4b9037a65f718cc41ad1a64729c67eecb4067b5aa122a9a146b9e3e3a0735163865edefbf3943bff74949f7efe1aaf88211fe34cc7a43a13d138ff946
MISC metadata.xml 985 BLAKE2B 0b5601161f57de941bf8cff616bc4c92260587517200e0f44a1501d56a938eb2e0727d61659bc2eda2dc42bf376fc8a40db4c7edde32c65c5d2d2d3c7ca82828 SHA512 6e9b2e0467d85aa9a1d18b185ccb7798e4a0cd75c86d70ff6facb644d7bb8657d9e195b38577fd874fe08accd576f231bcdc4b988a9478ab27cd5893d6fb3c51
diff --git a/sci-libs/m4rie/files/m4rie-20250103-pkgconfig-r1.patch b/sci-libs/m4rie/files/m4rie-20250103-pkgconfig-r1.patch
new file mode 100644
index 000000000000..191a90c982fc
--- /dev/null
+++ b/sci-libs/m4rie/files/m4rie-20250103-pkgconfig-r1.patch
@@ -0,0 +1,40 @@
+From e399e88566a0a96ec8d0ee010052a987c5d83e0f Mon Sep 17 00:00:00 2001
+From: Michael Orlitzky <michael@orlitzky.com>
+Date: Mon, 20 Jan 2025 22:55:08 -0500
+Subject: [PATCH] m4rie.pc.in: improve compiler/linker flag handling
+
+ 1. List m4ri in Requires. This will automatically add -lm4ri during
+ linking.
+
+ 2. Move $OPENMP_CFLAGS to Libs.private. Consumers of m4rie do not
+ need to enable OpenMP at compile time to avoid problems, only at
+ link time, and only when statically linking. In particular we want
+ to _avoid_ enabling OpenMP by "accident" in a larger project that
+ makes use of m4rie.
+
+ 3. Drop $M4RI_CFLAGS. There's just... no reason to add these here.
+ In theory if M4RI had some important -D flags, they would go here,
+ but at the moment it's just adding a bunch of -msse and -fopenmp
+ stuff that we do not necessarily want to use when compiling
+ consumers of m4rie.
+---
+ m4rie.pc.in | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/m4rie.pc.in b/m4rie.pc.in
+index e716441..57436ef 100644
+--- a/m4rie.pc.in
++++ b/m4rie.pc.in
+@@ -6,5 +6,7 @@ includedir=@includedir@
+ Name: M4RIE
+ Description: Dense linear algebra over GF(2^e).
+ Version: @PACKAGE_VERSION@
+-Libs: -L${libdir} -lm4rie -lm4ri -lm
+-Cflags: -I${includedir} @M4RI_CFLAGS@ @OPENMP_CFLAGS@
++Requires: m4ri >= 20240729
++Libs: -L${libdir} -lm4rie -lm
++Libs.private: @OPENMP_CFLAGS@
++Cflags: -I${includedir}
+--
+2.45.2
+
diff --git a/sci-libs/m4rie/m4rie-20250103-r1.ebuild b/sci-libs/m4rie/m4rie-20250103-r1.ebuild
new file mode 100644
index 000000000000..2751bfeee7d5
--- /dev/null
+++ b/sci-libs/m4rie/m4rie-20250103-r1.ebuild
@@ -0,0 +1,41 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools
+
+DESCRIPTION="Fast dense matrix arithmetic over GF(2^e) for 2 <= e <= 16"
+HOMEPAGE="https://github.com/malb/m4rie"
+SRC_URI="https://github.com/malb/${PN}/archive/refs/tags/release-${PV}.tar.gz"
+
+S="${WORKDIR}/${PN}-release-${PV}"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~riscv ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos"
+IUSE="debug"
+
+DEPEND=">=sci-libs/m4ri-20240729"
+RDEPEND="${DEPEND}"
+
+PATCHES=( "${FILESDIR}/${P}-pkgconfig-r1.patch" )
+
+src_prepare() {
+ default
+ eautoreconf
+}
+
+src_configure() {
+ # m4rie doesn't actually have any openmp code. The configure flag
+ # stems from a mistaken belief that it needs to be there to use the
+ # openmp code in m4ri.
+ econf \
+ --disable-openmp \
+ $(use_enable debug)
+}
+
+src_install() {
+ default
+ find "${ED}" -name '*.la' -delete || die
+}