public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] proj/sci:master commit in: sci-physics/cuttools/, sci-physics/cuttools/files/
@ 2024-11-20 18:35 Alexander Puck Neuwirth
  0 siblings, 0 replies; only message in thread
From: Alexander Puck Neuwirth @ 2024-11-20 18:35 UTC (permalink / raw
  To: gentoo-commits

commit:     21a1af59132fc3ad1037b627e698b04645bbe8cd
Author:     Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik <DOT> de>
AuthorDate: Wed Nov 20 18:31:39 2024 +0000
Commit:     Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik <DOT> de>
CommitDate: Wed Nov 20 18:33:13 2024 +0000
URL:        https://gitweb.gentoo.org/proj/sci.git/commit/?id=21a1af59

sci-physics/cuttools: Unbundle deps

Signed-off-by: Alexander Puck Neuwirth <alexander <AT> neuwirth-informatik.de>

 sci-physics/cuttools/cuttools-1.9.3-r1.ebuild      | 57 ++++++++++++++++++++++
 .../cuttools/files/cuttools-1.9.3-unbundle.patch   | 13 +++++
 2 files changed, 70 insertions(+)

diff --git a/sci-physics/cuttools/cuttools-1.9.3-r1.ebuild b/sci-physics/cuttools/cuttools-1.9.3-r1.ebuild
new file mode 100644
index 000000000..e2bd4df9d
--- /dev/null
+++ b/sci-physics/cuttools/cuttools-1.9.3-r1.ebuild
@@ -0,0 +1,57 @@
+# 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-libs/mpfun90
+	sci-physics/qcdloop
+	sci-physics/oneloop[dpkind,qpkind16,-qpkind,-tlevel]
+"
+RDEPEND="${DEPEND}"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-1.9.3-unbundle.patch"
+)
+
+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} ${LDFLAGS} -shared *.o -Wl,-soname,libcuttools.so  -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}
+}

diff --git a/sci-physics/cuttools/files/cuttools-1.9.3-unbundle.patch b/sci-physics/cuttools/files/cuttools-1.9.3-unbundle.patch
new file mode 100644
index 000000000..e1fa1a9ea
--- /dev/null
+++ b/sci-physics/cuttools/files/cuttools-1.9.3-unbundle.patch
@@ -0,0 +1,13 @@
+--- a/makefile	2024-11-20 15:50:21.960336440 +0100
++++ b/makefile	2024-11-20 15:50:51.503676969 +0100
+@@ -51,10 +51,7 @@
+ 
+ $(BLD)/version.h: 
+ 	-mkdir -p $(BLD)
+-	cp  -p ./src/avh/* $(BLD)/ 
+ 	cp  -p ./src/cts/* $(BLD)/ 
+-	cp  -p ./src/mpfun90/* $(BLD)/ 
+-	cp  -p ./src/qcdloop/* $(BLD)/ 
+ 	cp  -p ./src/makefile $(BLD)/ 
+ 
+ tar:


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2024-11-20 18:35 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-20 18:35 [gentoo-commits] proj/sci:master commit in: sci-physics/cuttools/, sci-physics/cuttools/files/ Alexander Puck Neuwirth

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox