From e6473e8c6184161e9fbe6a71ae5070487438e4a8 Mon Sep 17 00:00:00 2001 From: Andrey Grozin Date: Fri, 9 Nov 2018 23:11:36 +0700 Subject: sci-libs/arprec: bump to 2.2.19 Signed-off-by: Andrey Grozin Package-Manager: Portage-2.3.41, Repoman-2.3.9 --- sci-libs/arprec/arprec-2.2.19.ebuild | 84 ++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 sci-libs/arprec/arprec-2.2.19.ebuild (limited to 'sci-libs/arprec/arprec-2.2.19.ebuild') diff --git a/sci-libs/arprec/arprec-2.2.19.ebuild b/sci-libs/arprec/arprec-2.2.19.ebuild new file mode 100644 index 000000000000..4fe88b289cba --- /dev/null +++ b/sci-libs/arprec/arprec-2.2.19.ebuild @@ -0,0 +1,84 @@ +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +FORTRAN_NEEDED=fortran +FORTRAN_STANDARD=90 + +inherit autotools fortran-2 + +DESCRIPTION="Arbitrary precision float arithmetics and functions" +HOMEPAGE="http://crd-legacy.lbl.gov/~dhbailey/mpdist/" +SRC_URI="http://crd.lbl.gov/~dhbailey/mpdist/${P}.tar.gz" + +SLOT="0" +LICENSE="BSD" +KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux" +IUSE="cpu_flags_x86_fma3 cpu_flags_x86_fma4 doc fortran qd static-libs" + +DEPEND="qd? ( sci-libs/qd[fortran=] )" +RDEPEND="${DEPEND}" + +PATCHES=( + "${FILESDIR}"/${P}-gold.patch +) + +S="${WORKDIR}/${PN}" + +src_prepare() { + default + eautoreconf +} + +src_configure() { + econf \ + --enable-shared \ + $(use_enable static-libs static) \ + $(use_enable cpu_flags_x86_fma$(usex cpu_flags_x86_fma3 3 4) fma) \ + $(use_enable fortran) \ + $(use_enable qd) +} + +src_compile() { + default + + if use fortran; then + emake toolkit + cd toolkit || die + ./mathinit || die "mathinit failed" + fi +} + +src_install() { + default + + if use fortran; then + cd toolkit || die + + exeinto /usr/libexec/${PN} + doexe mathtool + + exeinto /usr/libexec/${PN}/.libs + doexe .libs/mathtool + + insinto /usr/libexec/${PN} + doins *.dat + + cat > mathtool.exe <<- _EOF_ || die + #!/usr/bin/env sh + cd "${EPREFIX}/usr/libexec/${PN}" && exec ./mathtool + _EOF_ + + newbin mathtool.exe mathtool + newdoc README README.mathtool + fi + + if ! use doc; then + rm "${ED%/}"/usr/share/doc/${PF}/*.pdf || die + fi + + if ! use static-libs; then + find "${D}" -name '*.la' -delete || die + fi +} -- cgit v1.2.3-65-gdbad