--- /dev/null
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+DESCRIPTION="Fast dense matrix arithmetic over GF(2^e) for 2 <= e <= 16"
+HOMEPAGE="https://bitbucket.org/malb/m4rie/"
+SRC_URI="https://bitbucket.org/malb/${PN}/downloads/${P}.tar.gz"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
+IUSE="debug static-libs"
+
+DEPEND=">=sci-libs/m4ri-20140914"
+RDEPEND="${DEPEND}"
+
+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) \
+ $(use_enable static-libs static)
+}
+
+src_install(){
+ default
+ find "${ED}" -name '*.la' -delete || die
+}
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>mjo@gentoo.org</email>
+ </maintainer>
+ <!--
+ mjo: François maintained this package in the sage-on-gentoo overlay
+ long before I moved it into ::gentoo. You don't need an ACK from me
+ to merge his changes.
+ -->
+ <maintainer type="person">
+ <email>frp.bissey@gmail.com</email>
+ <name>François Bissey</name>
+ </maintainer>
+ <maintainer type="project">
+ <email>proxy-maint@gentoo.org</email>
+ <name>Proxy Maintainers</name>
+ </maintainer>
+
+ <longdescription>
+ M4RIE is a library for fast arithmetic with dense matrices over
+ GF(2^e) for "e" between 2 and 16, inclusive. The name stems from
+ the fact that it relies heavily on M4RI.
+ </longdescription>
+
+ <upstream>
+ <remote-id type="bitbucket">malb/m4rie</remote-id>
+ </upstream>
+</pkgmetadata>