aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sci-physics/cuttools/Manifest1
-rw-r--r--sci-physics/cuttools/cuttools-1.9.3.ebuild52
2 files changed, 53 insertions, 0 deletions
diff --git a/sci-physics/cuttools/Manifest b/sci-physics/cuttools/Manifest
index 590c6fd51..bd3e92f61 100644
--- a/sci-physics/cuttools/Manifest
+++ b/sci-physics/cuttools/Manifest
@@ -1 +1,2 @@
DIST cuttools_v1.8.2.tar.gz 962232 BLAKE2B aaec06cc892577c2e562e8ee07e9863dd42a8bbf878b4e2aee01d2bbf5bb27bb9e4f50ef3c3a66fe00e73cc527e23b0274f9c3df169779c5fb529c9ff5610cb0 SHA512 6f1af82caa2a86669271346fa4a4f1d13b39f1c1ee7562c5fc29f250276d59017722a55256358bd006819a442acd3198901b642039be9f6a78d3cf31fe0ca976
+DIST cuttools_v1.9.3.tar.gz 1007945 BLAKE2B 832643d9bda99cd920ad289c8edc0394ac335d75330a99a5f1b814d62957d54a7c42f0fc861f2cc9389a0c5d94ed2d67cec4698277f14dc5d3cb27ba8c65bc5f SHA512 6574f9928b3c131bdbf9343323d3a5a56e653c9ace37edd047a3e172aaf6ce4fab04eeb3013cc7eb448bd86937326d15f5effe5600a6a743b750a1eaccaa5db2
diff --git a/sci-physics/cuttools/cuttools-1.9.3.ebuild b/sci-physics/cuttools/cuttools-1.9.3.ebuild
new file mode 100644
index 000000000..03f84b63c
--- /dev/null
+++ b/sci-physics/cuttools/cuttools-1.9.3.ebuild
@@ -0,0 +1,52 @@
+# Copyright 2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit fortran-2 toolchain-funcs
+
+DESCRIPTION="Computing 1-loop amplitudes at the integrand level"
+HOMEPAGE="https://www.ugr.es/~pittau/CutTools/"
+SRC_URI="https://www.ugr.es/~pittau/CutTools/${PN}_v${PV}.tar.gz"
+S="${WORKDIR}"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64"
+
+IUSE="+dummy"
+DEPEND="
+ sci-physics/qcdloop
+ sci-physics/oneloop[dpkind,qpkind16,-qpkind,-tlevel]
+"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ default
+ sed -i 's/^ALL =.*$/ALL = $(CTS)/' src/makefile || die
+ if use dummy ; then
+ cp "${FILESDIR}"/mpnumdummy.f90 src/cts/mpnumdummy.f90 || die
+ fi
+ if use dummy ; then
+ sed -i 's/CTS =/CTS = mpnumdummy.o/' src/makefile || die
+ fi
+}
+
+src_compile() {
+ emake -j1 FFLAGS="${FFLAGS} -I${ESYSROOT}/usr/include -fPIC -std=legacy"
+ tc-export AR CXX
+ cd includects || die
+ ${AR} -x libcts.a || die
+ ${CXX} ${CXXFLAGS} -shared *.o -o lib${PN}.so || die
+}
+
+src_install() {
+ cd includects || die
+ dolib.so lib${PN}.so
+ cd .. || die
+ mv includects ${PN} || die
+ rm ${PN}/*.a || die
+ rm ${PN}/*.so || die
+ rm ${PN}/*.o || die
+ doheader -r ${PN}
+}