diff options
-rw-r--r-- | sys-cluster/synapse/Manifest | 1 | ||||
-rw-r--r-- | sys-cluster/synapse/files/synapse-check-for-shared-mrnet.patch | 11 | ||||
-rw-r--r-- | sys-cluster/synapse/files/synapse-fix-example-installation.patch | 22 | ||||
-rw-r--r-- | sys-cluster/synapse/files/synapse-respect-destdir.patch | 15 | ||||
-rw-r--r-- | sys-cluster/synapse/metadata.xml | 17 | ||||
-rw-r--r-- | sys-cluster/synapse/synapse-2.0.1.ebuild | 43 |
6 files changed, 109 insertions, 0 deletions
diff --git a/sys-cluster/synapse/Manifest b/sys-cluster/synapse/Manifest new file mode 100644 index 000000000..7de754aed --- /dev/null +++ b/sys-cluster/synapse/Manifest @@ -0,0 +1 @@ +DIST synapse-2.0.1.tar.gz 268657 BLAKE2B 19491c1b6c4c60318093d994594b1ebb541a4b1ca1fb9128a2361b06b1a58921a0bc41f8e43abcb62f379c97db6603c62cf1622c7caf6d3f5ee1b84e0f80963d SHA512 c08762f065275232f419cca181acc0e40a913724e1182def9a810ed9b45c1e9f2ddd8dddf0a2623576ad527585b2ecb60842d9fc8f5f0f680c2b391ba4ee1dea diff --git a/sys-cluster/synapse/files/synapse-check-for-shared-mrnet.patch b/sys-cluster/synapse/files/synapse-check-for-shared-mrnet.patch new file mode 100644 index 000000000..c0413f60b --- /dev/null +++ b/sys-cluster/synapse/files/synapse-check-for-shared-mrnet.patch @@ -0,0 +1,11 @@ +--- a/config/macros.m4 ++++ b/config/macros.m4 +@@ -327,7 +327,7 @@ + dnl Check for libraries. + AC_MSG_CHECKING([for libmrnet and libxplat]) + +- if test -f ${MRNET_LIBSDIR}/libmrnet.a -a -f ${MRNET_LIBSDIR}/libxplat.a ; then ++ if test -f ${MRNET_LIBSDIR}/libmrnet.so -a -f ${MRNET_LIBSDIR}/libxplat.so ; then + MRNET_LIBS="-lmrnet -lxplat -lpthread -ldl" + MRNET_LIGHT_LIBS="-lmrnet_lightweight -lxplat_lightweight -lpthread -ldl" + AC_SUBST(MRNET_LIBS) diff --git a/sys-cluster/synapse/files/synapse-fix-example-installation.patch b/sys-cluster/synapse/files/synapse-fix-example-installation.patch new file mode 100644 index 000000000..f989b7394 --- /dev/null +++ b/sys-cluster/synapse/files/synapse-fix-example-installation.patch @@ -0,0 +1,22 @@ +--- a/test/Makefile.am ++++ b/test/Makefile.am +@@ -14,13 +14,9 @@ + test_BE_LDFLAGS = -L${top_srcdir}/src -lsynapse_backend -L@MRNET_LIBSDIR@ @MRNET_LIBS@ + + install-data-hook: +- mkdir -p ${prefix}/example +- cp ${test_FE_SOURCES} ${test_BE_SOURCES} ${prefix}/example +- cp Makefile-example ${prefix}/example/Makefile +- cp run-example ${prefix}/example/run.sh +- cp topology_1x4.txt ${prefix}/example +- chmod u+x ${prefix}/example/run.sh +- $(top_srcdir)/substitute $(SED) "@sub_SYNAPSE_HOME@" "${prefix}" ${prefix}/example/Makefile +- $(top_srcdir)/substitute $(SED) "@sub_SYNAPSE_HOME@" "${prefix}" ${prefix}/example/run.sh +- +- ++ mkdir -p ${DESTDIR}/${prefix}/libexec/synapse/example ++ cp ${noinst_PROGRAMS} ${DESTDIR}/${prefix}/libexec/synapse/example ++ cp run-example ${DESTDIR}/${prefix}/libexec/synapse/example/run.sh ++ cp topology_1x4.txt ${DESTDIR}/${prefix}/libexec/synapse/example ++ chmod u+x ${DESTDIR}/${prefix}/libexec/synapse/example/run.sh ++ $(top_srcdir)/substitute $(SED) "@sub_SYNAPSE_HOME@" "${prefix}" ${DESTDIR}/${prefix}/libexec/synapse/example/run.sh diff --git a/sys-cluster/synapse/files/synapse-respect-destdir.patch b/sys-cluster/synapse/files/synapse-respect-destdir.patch new file mode 100644 index 000000000..31496f62e --- /dev/null +++ b/sys-cluster/synapse/files/synapse-respect-destdir.patch @@ -0,0 +1,15 @@ +--- a/scripts/Makefile.am ++++ b/scripts/Makefile.am +@@ -37,9 +37,9 @@ + $(top_srcdir)/substitute $(SED) "@sub_MRNET_HOME@" "@MRNET_HOME@" $@ + + install-data-hook: +- chmod u+x ${bindir}/$(SYNAPSE_CONFIG) +- $(MKDIR_P) $(prefix)/etc +- cp $(SOURCEME_SH) $(prefix)/etc ++ chmod u+x ${DESTDIR}${bindir}/$(SYNAPSE_CONFIG) ++ $(MKDIR_P) ${DESTDIR}/etc ++ cp $(SOURCEME_SH) ${DESTDIR}/etc + + clean-local: + rm -f $(SYNAPSE_CONFIG) $(SOURCEME_SH) $(MRNRUN) diff --git a/sys-cluster/synapse/metadata.xml b/sys-cluster/synapse/metadata.xml new file mode 100644 index 000000000..d67e3064c --- /dev/null +++ b/sys-cluster/synapse/metadata.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>lssndrbarbieri@gmail.com</email> + <name>Alessandro Barbieri</name> + </maintainer> + <use> + <flag name="libi">Use libi as tree instantiation method instead of ssh</flag> + <flag name="threadsafe">Build threasafe version of lightweight MRNet and XPlat libraries</flag> + <flag name="slurm">Use slurm as libi tree instantiation method instead of ssh</flag> + </use> + <upstream> + <bugs-to>https://github.com/bsc-performance-tools/synapse/issues</bugs-to> + <remote-id type="github">bsc-performance-tools/synapse</remote-id> + </upstream> +</pkgmetadata> diff --git a/sys-cluster/synapse/synapse-2.0.1.ebuild b/sys-cluster/synapse/synapse-2.0.1.ebuild new file mode 100644 index 000000000..df1e7566c --- /dev/null +++ b/sys-cluster/synapse/synapse-2.0.1.ebuild @@ -0,0 +1,43 @@ +# Copyright 2019-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DESCRIPTION="synapse" +HOMEPAGE="https://github.com/bsc-performance-tools/synapse" +SRC_URI="https://github.com/bsc-performance-tools/synapse/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64" + +RDEPEND=" + dev-libs/boost:= + sys-cluster/mrnet +" +DEPEND="${RDEPEND}" + +PATCHES=( + "${FILESDIR}/${PN}-check-for-shared-mrnet.patch" + "${FILESDIR}/${PN}-respect-destdir.patch" + "${FILESDIR}/${PN}-fix-example-installation.patch" +) + +src_prepare() { + sed -e "s|\${prefix}/doc|\${DESTDIR}\${prefix}/share/${PF}/doc|g" -i doc/Makefile.am || die + default + ./bootstrap || die +} + +src_configure() { + local myconf=( + --with-mrnet="${EPREFIX}/usr" + ) + econf "${myconf[@]}" +} + +src_install() { + MAKEOPTS="-j1" DESTDIR="${D}" emake install + find "${ED}" -name '*.a' -delete || die + find "${ED}" -name '*.a' -delete || die +} |