* [gentoo-commits] repo/proj/guru:dev commit in: sys-cluster/scr/files/, sys-cluster/scr/
@ 2021-10-30 19:37 Alessandro Barbieri
0 siblings, 0 replies; only message in thread
From: Alessandro Barbieri @ 2021-10-30 19:37 UTC (permalink / raw
To: gentoo-commits
commit: f65def21208a1ffd2ab8ddd1781d139e33dd9b4c
Author: Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
AuthorDate: Sat Oct 30 19:00:11 2021 +0000
Commit: Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
CommitDate: Sat Oct 30 19:37:44 2021 +0000
URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=f65def21
sys-cluster/scr: add 3.0_pre2, drop 3.0_pre1
Signed-off-by: Alessandro Barbieri <lssndrbarbieri <AT> gmail.com>
sys-cluster/scr/Manifest | 2 +-
sys-cluster/scr/files/scr-3.0_pre2-no-static.patch | 76 ++++++++++++++++++++++
.../files/scr-3.0_pre2-shared-libscr_base.patch | 70 ++++++++++++++++++++
sys-cluster/scr/metadata.xml | 1 -
.../{scr-3.0_pre1.ebuild => scr-3.0_pre2.ebuild} | 26 ++++----
5 files changed, 159 insertions(+), 16 deletions(-)
diff --git a/sys-cluster/scr/Manifest b/sys-cluster/scr/Manifest
index a69a9230c..0ab6de12b 100644
--- a/sys-cluster/scr/Manifest
+++ b/sys-cluster/scr/Manifest
@@ -1 +1 @@
-DIST scr-3.0_pre1.tar.gz 1629041 BLAKE2B c7922e208964b8456c65393c0f9b17530b3eb66ceab38bc682b1fb78b29f77f2d3a6c51c9c8380720c88606a8da3b34f9a088ed80198f3c4f2bfe6906faac6ef SHA512 3bf290a41cb8abbd7e08ab02580f1e4dd73758946fe0ba7bd861a5099f8396e382dc8b80a0a33b0d45ee929efa069bd7a6381e9ca6f11d9049e113ac9aec6793
+DIST scr-3.0_pre2.tar.gz 1231943 BLAKE2B a4d8e779edc4b48a5b13a0cff851496068076a8ae901f3c3d3ad2344708a0abc6b69ce71bd7313286a91844a87930e6fa5c097d1c5b15ebbc12247ba293f843f SHA512 7b90b14cfbb6fa3020b6c3c3a7f5568963374d9fe7ad0b6962632f776c3699d6c38fa04800736d423350190542896ca9240033dca1e820f7f698c336518c891a
diff --git a/sys-cluster/scr/files/scr-3.0_pre2-no-static.patch b/sys-cluster/scr/files/scr-3.0_pre2-no-static.patch
new file mode 100644
index 000000000..2d63ebae8
--- /dev/null
+++ b/sys-cluster/scr/files/scr-3.0_pre2-no-static.patch
@@ -0,0 +1,76 @@
+--- a/src/CMakeLists.txt
++++ b/src/CMakeLists.txt
+@@ -83,16 +83,6 @@
+ INSTALL(TARGETS scr DESTINATION ${CMAKE_INSTALL_LIBDIR})
+ ENDIF()
+
+-ADD_LIBRARY(scr-static STATIC $<TARGET_OBJECTS:scr_o>)
+-IF(SCR_LINK_STATIC)
+- SET_TARGET_PROPERTIES(scr-static PROPERTIES LINK_SEARCH_START_STATIC 1)
+- SET_TARGET_PROPERTIES(scr-static PROPERTIES LINK_SEARCH_END_STATIC 1)
+-ENDIF(SCR_LINK_STATIC)
+-TARGET_LINK_LIBRARIES(scr-static ${SCR_EXTERNAL_LIBS})
+-
+-SET_TARGET_PROPERTIES(scr-static PROPERTIES OUTPUT_NAME scr CLEAN_DIRECT_OUTPUT 1)
+-INSTALL(TARGETS scr-static DESTINATION ${CMAKE_INSTALL_LIBDIR})
+-
+ # Non-MPI library for CLI
+ ADD_LIBRARY(cliscr_noMPI_o OBJECT ${cliscr_noMPI_srcs})
+
+@@ -103,16 +93,6 @@
+ INSTALL(TARGETS scr_base DESTINATION ${CMAKE_INSTALL_LIBDIR})
+ ENDIF(BUILD_SHARED_LIBS)
+
+-ADD_LIBRARY(scr_base-static STATIC $<TARGET_OBJECTS:cliscr_noMPI_o>)
+-IF(SCR_LINK_STATIC)
+- SET_TARGET_PROPERTIES(scr_base-static PROPERTIES LINK_SEARCH_START_STATIC 1)
+- SET_TARGET_PROPERTIES(scr_base-static PROPERTIES LINK_SEARCH_END_STATIC 1)
+-ENDIF(SCR_LINK_STATIC)
+-TARGET_LINK_LIBRARIES(scr_base-static ${SCR_EXTERNAL_SERIAL_LIBS})
+-
+-SET_TARGET_PROPERTIES(scr_base-static PROPERTIES OUTPUT_NAME scr_base CLEAN_DIRECT_OUTPUT 1)
+-INSTALL(TARGETS scr_base-static DESTINATION ${CMAKE_INSTALL_LIBDIR})
+-
+ # Fortran
+ IF(ENABLE_FORTRAN)
+ IF(BUILD_SHARED_LIBS)
+@@ -121,17 +101,6 @@
+ SET_TARGET_PROPERTIES(scrf PROPERTIES OUTPUT_NAME scrf CLEAN_DIRECT_OUTPUT 1)
+ INSTALL(TARGETS scrf DESTINATION ${CMAKE_INSTALL_LIBDIR})
+ ENDIF()
+-
+- ADD_LIBRARY(scrf-static STATIC scrf.c $<TARGET_OBJECTS:scr_o>)
+- IF(SCR_LINK_STATIC)
+- SET_TARGET_PROPERTIES(scrf-static PROPERTIES LINK_SEARCH_START_STATIC 1)
+- SET_TARGET_PROPERTIES(scrf-static PROPERTIES LINK_SEARCH_END_STATIC 1)
+- TARGET_LINK_LIBRARIES(scrf-static ${SCR_EXTERNAL_LIBS})
+- ENDIF(SCR_LINK_STATIC)
+- TARGET_LINK_LIBRARIES(scrf-static ${SCR_EXTERNAL_LIBS})
+-
+- SET_TARGET_PROPERTIES(scrf-static PROPERTIES OUTPUT_NAME scrf CLEAN_DIRECT_OUTPUT 1)
+- INSTALL(TARGETS scrf-static DESTINATION ${CMAKE_INSTALL_LIBDIR})
+ ENDIF(ENABLE_FORTRAN)
+
+ ###########
+@@ -164,21 +133,13 @@
+ # Build and install C binaries
+ FOREACH(bin IN ITEMS ${cliscr_c_bins})
+ ADD_EXECUTABLE(${bin} ${bin}.c)
+- IF(SCR_LINK_STATIC)
+- TARGET_LINK_LIBRARIES(${bin} scr_base-static)
+- ELSE(SCR_LINK_STATIC)
+ TARGET_LINK_LIBRARIES(${bin} scr_base)
+- ENDIF(SCR_LINK_STATIC)
+ INSTALL(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${bin} DESTINATION ${CMAKE_INSTALL_BINDIR})
+ ENDFOREACH(bin IN ITEMS ${cliscr_c_bins})
+
+ # Build and install CLI binaries that link full SCR library
+ FOREACH(bin IN ITEMS ${cliscr_scr_bins})
+ ADD_EXECUTABLE(${bin} ${bin}.c)
+- IF(SCR_LINK_STATIC)
+- TARGET_LINK_LIBRARIES(${bin} scr-static)
+- ELSE(SCR_LINK_STATIC)
+ TARGET_LINK_LIBRARIES(${bin} scr)
+- ENDIF(SCR_LINK_STATIC)
+ INSTALL(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${bin} DESTINATION ${CMAKE_INSTALL_BINDIR})
+ ENDFOREACH(bin IN ITEMS ${cliscr_scr_bins})
diff --git a/sys-cluster/scr/files/scr-3.0_pre2-shared-libscr_base.patch b/sys-cluster/scr/files/scr-3.0_pre2-shared-libscr_base.patch
new file mode 100644
index 000000000..4b8d71b70
--- /dev/null
+++ b/sys-cluster/scr/files/scr-3.0_pre2-shared-libscr_base.patch
@@ -0,0 +1,70 @@
+From 3cb02f312447731b5a949aca388d43b651b53a0d Mon Sep 17 00:00:00 2001
+From: Alessandro Barbieri <lssndrbarbieri@gmail.com>
+Date: Sat, 30 Oct 2021 20:28:49 +0200
+Subject: [PATCH 1/2] build libscr_base.so
+
+--- a/src/CMakeLists.txt
++++ b/src/CMakeLists.txt
+@@ -94,8 +94,24 @@ SET_TARGET_PROPERTIES(scr-static PROPERTIES OUTPUT_NAME scr CLEAN_DIRECT_OUTPUT
+ INSTALL(TARGETS scr-static DESTINATION ${CMAKE_INSTALL_LIBDIR})
+
+ # Non-MPI library for CLI
+-ADD_LIBRARY(scr_base STATIC ${cliscr_noMPI_srcs})
+-TARGET_LINK_LIBRARIES(scr_base ${SCR_EXTERNAL_SERIAL_LIBS})
++ADD_LIBRARY(cliscr_noMPI_o OBJECT ${cliscr_noMPI_srcs})
++
++IF(BUILD_SHARED_LIBS)
++ ADD_LIBRARY(scr_base SHARED $<TARGET_OBJECTS:cliscr_noMPI_o>)
++ TARGET_LINK_LIBRARIES(scr_base ${SCR_EXTERNAL_SERIAL_LIBS})
++ SET_TARGET_PROPERTIES(scr_base PROPERTIES OUTPUT_NAME scr_base CLEAN_DIRECT_OUTPUT 1)
++ INSTALL(TARGETS scr_base DESTINATION ${CMAKE_INSTALL_LIBDIR})
++ENDIF(BUILD_SHARED_LIBS)
++
++ADD_LIBRARY(scr_base-static STATIC $<TARGET_OBJECTS:cliscr_noMPI_o>)
++IF(SCR_LINK_STATIC)
++ SET_TARGET_PROPERTIES(scr_base-static PROPERTIES LINK_SEARCH_START_STATIC 1)
++ SET_TARGET_PROPERTIES(scr_base-static PROPERTIES LINK_SEARCH_END_STATIC 1)
++ENDIF(SCR_LINK_STATIC)
++TARGET_LINK_LIBRARIES(scr_base-static ${SCR_EXTERNAL_SERIAL_LIBS})
++
++SET_TARGET_PROPERTIES(scr_base-static PROPERTIES OUTPUT_NAME scr_base CLEAN_DIRECT_OUTPUT 1)
++INSTALL(TARGETS scr_base-static DESTINATION ${CMAKE_INSTALL_LIBDIR})
+
+ # Fortran
+ IF(ENABLE_FORTRAN)
+@@ -147,9 +163,13 @@ LIST(APPEND cliscr_c_bins
+
+ # Build and install C binaries
+ FOREACH(bin IN ITEMS ${cliscr_c_bins})
+- ADD_EXECUTABLE(${bin} ${bin}.c)
+- TARGET_LINK_LIBRARIES(${bin} scr_base)
+- INSTALL(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${bin} DESTINATION ${CMAKE_INSTALL_BINDIR})
++ ADD_EXECUTABLE(${bin} ${bin}.c)
++ IF(SCR_LINK_STATIC)
++ TARGET_LINK_LIBRARIES(${bin} scr_base-static)
++ ELSE(SCR_LINK_STATIC)
++ TARGET_LINK_LIBRARIES(${bin} scr_base)
++ ENDIF(SCR_LINK_STATIC)
++ INSTALL(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${bin} DESTINATION ${CMAKE_INSTALL_BINDIR})
+ ENDFOREACH(bin IN ITEMS ${cliscr_c_bins})
+
+ # Build and install CLI binaries that link full SCR library
+
+From e3d50ca7cab309273f3195c71af14352059d83aa Mon Sep 17 00:00:00 2001
+From: Alessandro Barbieri <lssndrbarbieri@gmail.com>
+Date: Sat, 30 Oct 2021 20:55:07 +0200
+Subject: [PATCH 2/2] remove source files of cli binaries from library
+
+to avoid `multiple definition of main`
+--- a/src/CMakeLists.txt
++++ b/src/CMakeLists.txt
+@@ -32,9 +32,6 @@ LIST(APPEND cliscr_noMPI_srcs
+ scr_meta.c
+ scr_param.c
+ scr_util.c
+- scr_rebuild_xor.c
+- scr_rebuild_partner.c
+- scr_rebuild_rs.c
+ )
+
+ LIST(APPEND libscr_srcs
diff --git a/sys-cluster/scr/metadata.xml b/sys-cluster/scr/metadata.xml
index d5d5447f4..103921ed9 100644
--- a/sys-cluster/scr/metadata.xml
+++ b/sys-cluster/scr/metadata.xml
@@ -17,7 +17,6 @@ The Scalable Checkpoint / Restart (SCR) library enables MPI applications to util
<flag name="flock">use flock as a file locking type</flag>
<flag name="fortran">Enables Fortran support</flag>
<flag name="mysql">Enable use of mysql for logging SCR activities</flag>
- <flag name="pmix">use pmix as resource manager</flag>
<flag name="slurm">use slurm as resource manager</flag>
<flag name="syslog">Whether to enable syslog logging</flag>
<flag name="txt-log">Whether to enable text file logging</flag>
diff --git a/sys-cluster/scr/scr-3.0_pre1.ebuild b/sys-cluster/scr/scr-3.0_pre2.ebuild
similarity index 83%
rename from sys-cluster/scr/scr-3.0_pre1.ebuild
rename to sys-cluster/scr/scr-3.0_pre2.ebuild
index 08524304d..4812b3799 100644
--- a/sys-cluster/scr/scr-3.0_pre1.ebuild
+++ b/sys-cluster/scr/scr-3.0_pre2.ebuild
@@ -1,7 +1,7 @@
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI="7"
+EAPI=8
DOCS_BUILDER="sphinx"
DOCS_DIR="${S}/doc/rst"
@@ -22,14 +22,13 @@ S="${WORKDIR}/${PN}-${MYPV}"
LICENSE="BSD"
SLOT="0"
KEYWORDS="~amd64"
-IUSE="doc examples fcntl +flock +fortran mysql pmix slurm syslog test txt-log +yogrt"
+IUSE="doc examples fcntl +flock +fortran mysql slurm syslog test txt-log +yogrt"
-#cppr
RDEPEND="
${PYTHON_DEPS}
app-shells/pdsh
- sys-cluster/AXL
+ >=sys-cluster/AXL-0.5.0
sys-cluster/dtcmp
sys-cluster/er
sys-cluster/KVTree
@@ -40,16 +39,18 @@ RDEPEND="
virtual/mpi
mysql? ( dev-db/mysql-connector-c )
- pmix? ( sys-cluster/pmix )
slurm? ( sys-cluster/slurm )
yogrt? ( sys-cluster/libyogrt[slurm?] )
"
DEPEND="${RDEPEND}"
+PATCHES=(
+ "${FILESDIR}/${P}-shared-libscr_base.patch"
+ "${FILESDIR}/${P}-no-static.patch"
+)
REQUIRED_USE="
${PYTHON_REQUIRED_USE}
- ?? ( pmix slurm )
?? ( fcntl flock )
"
RESTRICT="!test? ( test )"
@@ -59,8 +60,6 @@ pkg_setup() {
}
src_configure() {
- local asyncapi="NONE" #INTEL_CPPR
-
local lock="NONE"
use fcntl && lock="FCNTL"
use flock && lock="FLOCK"
@@ -70,18 +69,17 @@ src_configure() {
use txt-log && log="1"
local resman="NONE"
- use pmix && resman="PMIX"
use slurm && resman="SLURM"
local mycmakeargs=(
-DBUILD_PDSH=OFF
- -DENABLE_INTEL_CPPR=OFF
- -DENABLE_ENABLE_CRAY_DW=OFF
+ -DBUILD_SHARED_LIBS=ON
+ -DENABLE_CRAY_DW=OFF
-DENABLE_IBM_BBAPI=OFF
-DENABLE_PDSH=ON
- -DSCR_ASYNC_API="${asyncapi}"
- -DSCR_FILE_LOCK="${lock}"
-DSCR_LINK_STATIC=OFF
+
+ -DSCR_FILE_LOCK="${lock}"
-DSCR_LOG_ENABLE="${log}"
-DSCR_RESOURCE_MANAGER="${resman}"
@@ -102,5 +100,5 @@ src_compile() {
src_install() {
cmake_src_install
- find "${ED}" -name '*.a' -delete || die
+# find "${ED}" -name '*.a' -delete || die
}
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2021-10-30 19:37 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-10-30 19:37 [gentoo-commits] repo/proj/guru:dev commit in: sys-cluster/scr/files/, sys-cluster/scr/ Alessandro Barbieri
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox