public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/proj/guru:dev commit in: sys-cluster/sionlib/, sys-cluster/sionlib/files/
@ 2021-04-25  1:01 Alessandro Barbieri
  0 siblings, 0 replies; 4+ messages in thread
From: Alessandro Barbieri @ 2021-04-25  1:01 UTC (permalink / raw
  To: gentoo-commits

commit:     8b1d3fec410cc64f8815b76dd8d413777eb19d65
Author:     Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
AuthorDate: Sun Apr 25 01:01:06 2021 +0000
Commit:     Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
CommitDate: Sun Apr 25 01:01:06 2021 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=8b1d3fec

sys-cluster/sionlib: new package

Package-Manager: Portage-3.0.18, Repoman-3.0.3
Signed-off-by: Alessandro Barbieri <lssndrbarbieri <AT> gmail.com>

 sys-cluster/sionlib/Manifest                  |   1 +
 sys-cluster/sionlib/files/respect-flags.patch | 134 ++++++++++++++++++++++++++
 sys-cluster/sionlib/metadata.xml              |  34 +++++++
 sys-cluster/sionlib/sionlib-1.7.6.ebuild      | 104 ++++++++++++++++++++
 4 files changed, 273 insertions(+)

diff --git a/sys-cluster/sionlib/Manifest b/sys-cluster/sionlib/Manifest
new file mode 100644
index 000000000..9046f5a2b
--- /dev/null
+++ b/sys-cluster/sionlib/Manifest
@@ -0,0 +1 @@
+DIST sionlib-1.7.6.tar.gz 486418 BLAKE2B 885eb2012ec6da031f5ae8b093ee4f3e5bbe31c9b24a11576f2ad01b32ddd8a85051565034f0e6c756af51409fb89f9c79f80b35c8337f2dc7912cb9e54d909b SHA512 afdd8520f489bc940edc51ffa636a25cad778de07bfbb21d2bd2ab767e57b16044990d85ef44d2e6482a376196f5c6a2a6f1a71556dd987f8094dd396a971d1c

diff --git a/sys-cluster/sionlib/files/respect-flags.patch b/sys-cluster/sionlib/files/respect-flags.patch
new file mode 100644
index 000000000..9ff5bd384
--- /dev/null
+++ b/sys-cluster/sionlib/files/respect-flags.patch
@@ -0,0 +1,134 @@
+diff '--color=auto' -ru a/config/determine-cc.sh b/config/determine-cc.sh
+--- a/config/determine-cc.sh	2021-04-25 01:09:35.175990108 +0200
++++ b/config/determine-cc.sh	2021-04-25 01:10:02.876433713 +0200
+@@ -1,7 +1,6 @@
+ #!/bin/sh
+ # determine what compiler is behind "cc" (and presumably "CC" and "ftn") wrapper
+ 
+-CC=`which cc 2>/dev/null`
+ COMP=
+ if [ -z "$CC" ]; then
+   echo "No 'cc' located!"
+diff '--color=auto' -ru a/config/select-compiler.sh b/config/select-compiler.sh
+--- a/config/select-compiler.sh	2021-04-25 01:09:35.175990108 +0200
++++ b/config/select-compiler.sh	2021-04-25 01:10:26.882817842 +0200
+@@ -9,7 +9,7 @@
+ CPS=""
+ COMP=""
+ 
+-GNU=`which gcc 2> /dev/null`
++GNU="${CC}"
+ if [ -n "${GNU}" ]
+ then
+   NCPS=`expr ${NCPS} + 1`
+diff '--color=auto' -ru a/config/select-mpi.sh b/config/select-mpi.sh
+--- a/config/select-mpi.sh	2021-04-25 01:09:35.175990108 +0200
++++ b/config/select-mpi.sh	2021-04-25 01:12:41.269962840 +0200
+@@ -76,7 +76,6 @@
+   if [ -z "${MPIS}" ]; then MPIS="${MPI}"; else MPIS="${MPIS}|${MPI}"; fi
+ fi
+ 
+-MPICC=`which mpicc 2> /dev/null`
+ if [ -n "${MPICC}" ]
+ then
+   FMPI=""
+@@ -86,7 +85,7 @@
+   MPIROOTDIR1=`dirname ${MBINDIR}`
+ 
+   echo "#include <mpi.h>" > conftest.c
+-  mpicc -E conftest.c | grep '/mpi.h"' | head -1 > mpiconf.txt
++  "${MPICC}" -E conftest.c | grep '/mpi.h"' | head -1 > mpiconf.txt
+   MINCDIR=`cat mpiconf.txt | sed -e 's#^.* "##' -e 's#/mpi.h".*##'`
+   if [ -n "${MINCDIR}" ]
+   then
+diff '--color=auto' -ru a/mf/Makefile.defs.linux-gomp b/mf/Makefile.defs.linux-gomp
+--- a/mf/Makefile.defs.linux-gomp	2021-04-25 01:09:35.119989211 +0200
++++ b/mf/Makefile.defs.linux-gomp	2021-04-25 01:52:32.378951608 +0200
+@@ -23,24 +23,19 @@
+ #------------------------------------------------------------------------------
+ # SIONlib General Settings
+ #------------------------------------------------------------------------------
+-OPTFLAGS = -g -O0 -Wall
++CFLAGS   += -std=c99 $(PFLAG) $(OPTFLAGS) -fPIC
+ 
+-CC       = gcc
+-CFLAGS   = -std=c99 $(PFLAG) $(OPTFLAGS) -fPIC
++CXXFLAGS += $(PFLAG) $(OPTFLAGS) -fPIC
+ 
+-CXX      = g++
+-CXXFLAGS = $(PFLAG) $(OPTFLAGS) -O3
+-
+-F77      = gfortran
+-FFLAGS   = $(PFLAG) $(OPTFLAGS)
++FFLAGS   += $(PFLAG) $(OPTFLAGS) -fPIC
+ 
+ F90      = $(F77)
+-F90FLAGS = $(PFLAG) $(OPTFLAGS) -ffree-form
++F90FLAGS += $(PFLAG) $(OPTFLAGS) -ffree-form -fPIC $(FCFLAGS)
+ 
+ FPP      =
+ FDOPT    = -D
+ 
+-LDFLAGS  = $(PFLAG) $(OPTFLAGS) $(HINTSLIB)
++LDFLAGS  += $(PFLAG) $(OPTFLAGS) $(HINTSLIB)
+ UTILLIB  =
+ FOBASE   = pomp_fwrapper_base.o
+ 
+@@ -101,10 +96,6 @@
+ #------------------------------------------------------------------------------
+ 
+ MPIENABLE = 1
+-MPICC     = mpicc
+-MPICXX    = mpicxx
+-MPIF77    = mpif77
+-MPIF90    = mpif90
+ MPILIB    = -lmpich
+ PMPILIB   = -lpmpich
+ #PMPILIB   = # MPICH2
+@@ -139,8 +130,7 @@
+ #------------------------------------------------------------------------------
+ 
+ SZLIB          = szlib
+-SZLIB_OPTFLAGS = -O3
+-SZLIB_CFLAGS   = -I$(TOPDIR)/utils/szlib -DELG_COMPRESSED -DCUBE_COMPRESSED
++SZLIB_CFLAGS   = -I$(TOPDIR)/utils/szlib -DELG_COMPRESSED -DCUBE_COMPRESSED $(CFLAGS)
+ SZLIB_LIBPATH  = -L$(TOPDIR)/utils/szlib
+ SZLIB_LIB      = -lsc.z
+ 
+diff '--color=auto' -ru a/src/fortraninterface/Makefile b/src/fortraninterface/Makefile
+--- a/src/fortraninterface/Makefile	2021-04-25 01:09:35.141989563 +0200
++++ b/src/fortraninterface/Makefile	2021-04-25 01:23:48.055976593 +0200
+@@ -109,7 +110,7 @@
+ 	$(CPP) $(F90FLAGS) $(F90FLAGS_CPP) -P -E -I ../lib sion_f90.F90 > sion_f90.f90
+ sion_f90.mod : sion_f90.o
+ sion_f90.o : sion_f90.f90 sion_f77.h $(SION_HDRS)
+-	$(F90) -c sion_f90.f90
++	$(F90) $(F90FLAGS) -c sion_f90.f90
+ 
+ sion_f90_omp.o: sion_f90.o
+ sion_f90_mpi.o: sion_f90.o
+@@ -121,21 +122,21 @@
+ 	$(CPP) $(F90FLAGS) $(F90FLAGS_CPP) $(F90MPIFLAGS) -P -E -I ../lib sion_f90_mpi.F90 > sion_f90_mpi.f90
+ sion_f90_mpi.mod : sion_f90_mpi.o
+ sion_f90_mpi.o : sion_f90_mpi.f90 sion_f90.mod $(SION_HDRS)
+-	$(MPIF90) -c sion_f90_mpi.f90
++	$(MPIF90) $(F90FLAGS) $(F90MPIFLAGS) -c sion_f90_mpi.f90
+ 
+ # F90 Interface (OMP)
+ sion_f90_omp.f90: sion_f90_omp.F90
+ 	$(CPP) $(F90OMPFLAGS) $(F90FLAGS) $(F90FLAGS_CPP) -P -E -I ../lib sion_f90_omp.F90 > sion_f90_omp.f90
+ sion_f90_omp.mod : sion_f90_omp.o 
+ sion_f90_omp.o : sion_f90_omp.f90 sion_f90.mod $(SION_HDRS)
+-	$(OMPF90) -c sion_f90_omp.f90
++	$(OMPF90) $(F90FLAGS) $(F90OMPFLAGS) -c sion_f90_omp.f90
+ 
+ # F90 Interface (OMPI)
+ sion_f90_ompi.f90: sion_f90_ompi.F90 $(SION_HDRS)
+ 	$(CPP) $(F90MPIFLAGS) $(F90OMPFLAGS) $(F90FLAGS) $(F90FLAGS_CPP) -P -E -I ../lib sion_f90_ompi.F90 > sion_f90_ompi.f90
+ sion_f90_ompi.mod : sion_f90_ompi.o
+ sion_f90_ompi.o : sion_f90_ompi.f90 $(SION_HDRS)
+-	$(MPIF90) -c sion_f90_ompi.f90
++	$(MPIF90) $(F90FLAGS) $(F90MPIFLAGS) -c sion_f90_ompi.f90
+ 
+ 
+ 

diff --git a/sys-cluster/sionlib/metadata.xml b/sys-cluster/sionlib/metadata.xml
new file mode 100644
index 000000000..2c7649717
--- /dev/null
+++ b/sys-cluster/sionlib/metadata.xml
@@ -0,0 +1,34 @@
+<?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>
+	<longdescription>
+SIONlib is a library for writing and reading data from several thousands of parallel tasks into/from one or a small number of physical files. Only the open and close functions are collective while file access can be performed independently.
+
+SIONlib can be used as a replacement for standard I/O APIs (e.g. POSIX) that are used to access distinct files from every parallel process. SIONlib will bundle the data into one or few files in a coordinated fashion in order to sidestep sequentialising mechanism in the file system. At the same time, the task-per-file picture is maintained for the application, every process has access to its logical file only. File access is performed using SIONlib equivalents to standard C-I/O functionality (fwrite becomes sion_write, fseek becomes sion_seek, etc.) which have similar semantics as their C counterparts.
+
+Internally, the physical files are sub-divided into sequences of blocks, which themselves contain one chunk of data belonging to every logical file. In case the amount to be written to a file is known up front, it can optionally be specified when opening the file and the sequence of blocks collapses into a single block with one chunk per task containing all of its data. If a chunk size cannot be specified ahead of time, a sensible default is chosen and reads and writes that cross chunk boundaries are handled transparently by SIONlib.
+
+SIONlib also uses information about the block size of the underlying file system, because access to the same block from different tasks often leads to contention.
+
+Both, the estimated chunk size and file system block size are used to align individual chunks with file system blocks. Ensuring contention-free access to file system blocks enables efficient parallel writing and reading.
+
+SIONlib provides two different interfaces: one for parallel access (with implementations for different parallel programming technologies such as MPI, OpenMP and hybrid MPI+OpenMP) and one for sequential access which is also used internally by the SIONlib utilities.
+	</longdescription>
+	<use>
+		<!--<flag name="cuda">enable CUDA aware interface</flag>-->
+		<flag name="cxx">Disable C++ support</flag>
+		<flag name="debug">enable SIONlib debug</flag>
+		<flag name="fortran">Enable Fortran support</flag>
+		<flag name="mpi">enable mpi</flag>
+		<flag name="python">enable python support</flag>
+		<flag name="ompi">enable hybrid openmp mpi</flag>
+		<flag name="openmp">enable openmp</flag>
+		<flag name="parutils">Enable compilation of parutils (used for benchmarking)</flag>
+		<flag name="pthreads">configure SIONlib to use pthreads for locking</flag>
+		<!--<flag name="sionfwd">enable I/O forwarding with SIONfwd</flag>-->
+	</use>
+</pkgmetadata>

diff --git a/sys-cluster/sionlib/sionlib-1.7.6.ebuild b/sys-cluster/sionlib/sionlib-1.7.6.ebuild
new file mode 100644
index 000000000..e1959dcc2
--- /dev/null
+++ b/sys-cluster/sionlib/sionlib-1.7.6.ebuild
@@ -0,0 +1,104 @@
+# Copyright 2019-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+FORTRAN_NEEDED="fortran"
+PYTHON_COMPAT=( pypy3 python3_{7,8,9} )
+inherit flag-o-matic fortran-2 python-any-r1 toolchain-funcs
+
+DESCRIPTION="Scalable I/O library for parallel access to task-local files"
+HOMEPAGE="https://www.fz-juelich.de/ias/jsc/EN/Expertise/Support/Software/SIONlib/_node.html"
+SRC_URI="http://apps.fz-juelich.de/jsc/sionlib/download.php?version=${PV} -> ${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="+cxx debug doc +fortran +mpi +ompi +openmp +parutils +pthreads python"
+#TODO: cuda sionfwd msa
+#--enable-sionfwd=/path/to/sionfwd
+#--msa=(hostname-regex|deep-est-sdv)]	MSA aware collective operations for the given system
+
+PATCHES=( "${FILESDIR}/respect-flags.patch" )
+
+RDEPEND="
+	${PYTHON_DEPS}
+	mpi? ( virtual/mpi )
+	ompi? (
+		sys-libs/libomp
+		virtual/mpi
+	)
+	openmp? ( sys-libs/libomp )
+"
+DEPEND="${RDEPEND}"
+BDEPEND="doc? ( app-doc/doxygen )"
+S="${WORKDIR}/${PN}"
+
+pkg_setup() {
+	FORTRAN_NEED_OPENMP=0
+	use openmp && FORTRAN_NEED_OPENMP=1
+	use ompi && FORTRAN_NEED_OPENMP=1
+
+	fortran-2_pkg_setup
+}
+
+src_configure() {
+	export AR=$(tc-getAR)
+	export CC=$(tc-getCC)
+	export CXX=$(tc-getCXX)
+	export MPICC=/usr/bin/mpicc
+	export MPICXX=/usr/bin/mpicxx
+	export MPIF77=/usr/bin/mpif77
+	export MPIF90=/usr/bin/mpif90
+	export F77=$(tc-getF77)
+	export F90=$(tc-getFC)
+	export OMPF77=$(tc-getF77)
+	export OMPF90=$(tc-getFC)
+
+	append-fflags -fallow-argument-mismatch
+
+	local myconf=(
+		--disable-mic
+		--prefix="${EPREFIX}/usr"
+	)
+
+	#custom configure?
+	use cxx || myconf+=( "--disable-cxx" )
+	use fortran || myconf+=( "--disable-fortran" )
+	use mpi || myconf+=( "--disable-mpi" )
+	use ompi || myconf+=( "--disable-ompi" )
+	use openmp || myconf+=( "--disable-omp" )
+	use parutils || myconf+=( "--disable-parutils" )
+	use pthreads || myconf+=( "--disable-pthreads" )
+
+	use debug && myconf+=( "--enable-debug" )
+	use python && myconf+=( "--enable-python=3" )
+
+	./configure "${myconf[@]}" || die
+}
+
+src_compile() {
+	default
+	use doc && doxygen -u doxy && doxygen doxy || die
+}
+
+src_install() {
+	sed -e "s|\${PREFIX}|${D}/usr|g" -i mf/common.defs || die
+	sed -e "s|\$(PREFIX)|${D}/usr|g" -i src/utils/Makefile || die
+	sed \
+		-e "s|\$(PREFIX)|${D}/usr|g" \
+		-e "s|\${PREFIX}|${D}/usr|g" \
+		-i mf/RealMakefile || die
+
+	default
+
+	use doc && dodoc -r doc/html
+
+	mv "${ED}/usr/examples" "${ED}/usr/share/doc/${PF}/" || die
+	docompress -x "/usr/share/doc/${PF}/examples"
+	docompress -x "/usr/share/doc/${PF}/html"
+
+	#TODO: build shared libs
+	#find "${ED}" -name '*.a' -delete || die
+	find "${ED}" -name '*.la' -delete || die
+}


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [gentoo-commits] repo/proj/guru:dev commit in: sys-cluster/sionlib/, sys-cluster/sionlib/files/
@ 2021-08-29  0:33 Alessandro Barbieri
  0 siblings, 0 replies; 4+ messages in thread
From: Alessandro Barbieri @ 2021-08-29  0:33 UTC (permalink / raw
  To: gentoo-commits

commit:     899c3526b1b0c2bacf460f6c050e47439ede7f74
Author:     Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
AuthorDate: Sat Aug 28 23:29:35 2021 +0000
Commit:     Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
CommitDate: Sun Aug 29 00:33:32 2021 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=899c3526

sys-cluster/sionlib: build shared libraries

Signed-off-by: Alessandro Barbieri <lssndrbarbieri <AT> gmail.com>

 .../files/sionlib-build-shared-libraries.patch     | 337 +++++++++++++++++++++
 .../sionlib/files/sionlib-respect-flags-v3.patch   |   6 +-
 ...lib-1.7.7-r2.ebuild => sionlib-1.7.7-r3.ebuild} |  11 +-
 3 files changed, 346 insertions(+), 8 deletions(-)

diff --git a/sys-cluster/sionlib/files/sionlib-build-shared-libraries.patch b/sys-cluster/sionlib/files/sionlib-build-shared-libraries.patch
new file mode 100644
index 000000000..9c1895499
--- /dev/null
+++ b/sys-cluster/sionlib/files/sionlib-build-shared-libraries.patch
@@ -0,0 +1,337 @@
+diff '--color=auto' -ru sionlib-ori/src/cppinterface/Makefile sionlib/src/cppinterface/Makefile
+--- sionlib-ori/src/cppinterface/Makefile	2021-08-29 01:04:54.919546800 +0200
++++ sionlib/src/cppinterface/Makefile	2021-08-29 00:44:20.564541936 +0200
+@@ -30,7 +30,7 @@
+ ifeq ($(CXXENABLE),1)
+ 
+ USER_HDRS = sion_cxx_base.hpp sion_cxx_serial.hpp sion_cxx_common.hpp sion_cxx_mpi.hpp sion_cxx_ompi.hpp  sion_cxx_omp.hpp 
+-USER_LIBS = lib$(SION_LIBNAME_CXX_SER).a lib$(SION_LIBNAME_CXX_MPI).a
++USER_LIBS = lib$(SION_LIBNAME_CXX_SER).so lib$(SION_LIBNAME_CXX_MPI).so
+ else
+ USER_HDRS = 
+ USER_LIBS = 
+@@ -58,12 +58,12 @@
+ all: $(USER_LIBS)
+ 
+ 
+-lib$(SION_LIBNAME_CXX_SER).a : $(SION_OBJS_SER)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_SER)
++lib$(SION_LIBNAME_CXX_SER).so : $(SION_OBJS_SER)
++	$(CXX) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_CXX_SER).so -shared -o $@ $(SION_OBJS_SER)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_CXX_MPI).a : $(SION_OBJS_MPI)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_MPI)
++lib$(SION_LIBNAME_CXX_MPI).so : $(SION_OBJS_MPI)
++	$(MPICXX) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_CXX_MPI).so -shared -o $@ $(SION_OBJS_MPI)
+ 	@echo "*** $@ built"
+ 
+ sion_cxx_base.o :
+@@ -118,7 +118,7 @@
+ 	done
+ 
+ clean:
+-	rm -f *.o lib*.a
++	rm -f *.o lib*.so
+ 
+ #------------------------------------------------------------------------------
+ # Dependencies
+diff '--color=auto' -ru sionlib-ori/src/fortraninterface/Makefile sionlib/src/fortraninterface/Makefile
+--- sionlib-ori/src/fortraninterface/Makefile	2021-08-29 01:04:54.928546844 +0200
++++ sionlib/src/fortraninterface/Makefile	2021-08-29 01:21:47.153471098 +0200
+@@ -39,7 +39,7 @@
+ 
+ USER_HDRS = sion_f77.H sion_f77.h 
+ USER_MODS = sion_f90.mod
+-USER_LIBS = lib$(SION_LIBNAME_F77_SER).a lib$(SION_LIBNAME_F77_MPI).a lib$(SION_LIBNAME_F90_SER).a lib$(SION_LIBNAME_F90_MPI).a
++USER_LIBS = lib$(SION_LIBNAME_F77_SER).so lib$(SION_LIBNAME_F77_MPI).so lib$(SION_LIBNAME_F90_SER).so lib$(SION_LIBNAME_F90_MPI).so
+ else
+ USER_HDRS = 
+ USER_MODS =
+@@ -56,18 +56,24 @@
+   SION_OBJS_F77_SER += sion_f77_omp.o sion_fortran_omp.o
+   SION_OBJS_F90_SER += sion_f90_omp.o sion_fortran_omp.o
+   USER_MODS += sion_f90_omp.mod
++  F77_SER_LIBS = $(OMPFLAG) -l$(SION_LIBNAME_OMP)
++  F90_SER_LIBS = $(OMPFLAG) -l$(SION_LIBNAME_OMP)
+ endif
+ 
+ ifeq ($(MPIENABLE),1)
+   SION_OBJS_F77_MPI += sion_f77_mpi.o sion_fortran_mpi.o sion_fortran_writeread_mpi_f77.o
+   SION_OBJS_F90_MPI += sion_f90_mpi.o sion_fortran_mpi.o sion_fortran_writeread_mpi_f90.o
+   USER_MODS += sion_f90_mpi.mod
++  F77_MPI_LIBS = -l$(SION_LIBNAME_MPI)
++  F90_MPI_LIBS = -l$(SION_LIBNAME_MPI)
+ endif
+ 
+ ifeq ($(HYBENABLE),1)
+   SION_OBJS_F77_MPI += sion_f77_ompi.o sion_fortran_ompi.o
+   SION_OBJS_F90_MPI += sion_f90_ompi.o sion_fortran_ompi.o
+   USER_MODS += sion_f90_ompi.mod
++  F77_MPI_LIBS = $(HYBFLAG) -l$(SION_LIBNAME_OMPI)
++  F90_MPI_LIBS = $(HYBFLAG) -l$(SION_LIBNAME_OMPI)
+ endif   
+ 
+ SION_DEPEND_OBJS=sion_fortran.o sion_fortran_omp.o sion_fortran_mpi.o sion_fortran_ompi.o sion_fortran_writeread_f77.o sion_fortran_writeread_f90.o  sion_fortran_writeread_mpi_f77.o sion_fortran_writeread_mpi_f90.o 
+@@ -75,20 +81,20 @@
+ all: $(USER_LIBS) $(USER_MODS)
+ 
+ 
+-lib$(SION_LIBNAME_F77_SER).a : $(SION_OBJS_F77_SER)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_F77_SER)
++lib$(SION_LIBNAME_F77_SER).so : $(SION_OBJS_F77_SER)
++	$(F77) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_F77_SER).so -shared -o $@ $(SION_OBJS_F77_SER) $(F77_SER_LIBS)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_F77_MPI).a : $(SION_OBJS_F77_MPI)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_F77_MPI)
++lib$(SION_LIBNAME_F77_MPI).so : $(SION_OBJS_F77_MPI)
++	$(MPIF77) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_F77_MPI).so -shared -o $@ $(SION_OBJS_F77_MPI) $(F77_MPI_LIBS)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_F90_SER).a : $(SION_OBJS_F90_SER)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_F90_SER)
++lib$(SION_LIBNAME_F90_SER).so : $(SION_OBJS_F90_SER)
++	$(F90) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_F90_SER).so -shared -o $@ $(SION_OBJS_F90_SER) $(F90_SER_LIBS)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_F90_MPI).a : $(SION_OBJS_F90_MPI)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_F90_MPI)
++lib$(SION_LIBNAME_F90_MPI).so : $(SION_OBJS_F90_MPI)
++	$(MPIF90) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_F90_MPI).so -shared -o $@ $(SION_OBJS_F90_MPI) $(F90_MPI_LIBS)
+ 	@echo "*** $@ built"
+ 
+ # F77 interface
+@@ -206,7 +212,7 @@
+ 	done
+ 
+ clean:
+-	rm -f *.o lib*.a *.mod
++	rm -f *.o lib*.so *.mod
+ 
+ #------------------------------------------------------------------------------
+ # Dependencies
+diff '--color=auto' -ru sionlib-ori/src/lib/Makefile sionlib/src/lib/Makefile
+--- sionlib-ori/src/lib/Makefile	2021-08-29 01:04:54.930546854 +0200
++++ sionlib/src/lib/Makefile	2021-08-29 00:44:20.574541984 +0200
+@@ -67,25 +67,25 @@
+ endif
+ 
+ USER_HDRS = sion.h sion_common.h sion_serial.h sion_const.h sion_datatypes.h sion_platform.h sion_debug.h $(SION_CXX_HDR)
+-USER_LIBS = lib$(SION_LIBNAME_SER).a lib$(SION_LIBNAME_COM).a lib$(SION_LIBNAME_COM_LOCK_PTHREADS).a lib$(SION_LIBNAME_COM_LOCK_NONE).a 
++USER_LIBS = lib$(SION_LIBNAME_SER).so lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_COM_LOCK_PTHREADS).so lib$(SION_LIBNAME_COM_LOCK_NONE).so
+ 
+ 
+-all: lib$(SION_LIBNAME_COM).a lib$(SION_LIBNAME_SER).a  lib$(SION_LIBNAME_COM_LOCK_PTHREADS).a lib$(SION_LIBNAME_COM_LOCK_NONE).a 
++all: lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_SER).so  lib$(SION_LIBNAME_COM_LOCK_PTHREADS).so lib$(SION_LIBNAME_COM_LOCK_NONE).so
+ 
+-lib$(SION_LIBNAME_COM).a : $(SION_COMMON_OBJS)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_COMMON_OBJS)
++lib$(SION_LIBNAME_COM).so : $(SION_COMMON_OBJS)
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_COM).so -shared -o $@ $(SION_COMMON_OBJS)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_COM_LOCK_PTHREADS).a : $(SION_COMMON_LOCK_PTHREADS_OBJS)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_COMMON_LOCK_PTHREADS_OBJS)
++lib$(SION_LIBNAME_COM_LOCK_PTHREADS).so : $(SION_COMMON_LOCK_PTHREADS_OBJS)
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_COM_LOCK_PTHREADS).so -shared -o $@ $(SION_COMMON_LOCK_PTHREADS_OBJS)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_COM_LOCK_NONE).a : $(SION_COMMON_LOCK_NONE_OBJS)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_COMMON_LOCK_NONE_OBJS)
++lib$(SION_LIBNAME_COM_LOCK_NONE).so : $(SION_COMMON_LOCK_NONE_OBJS)
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_COM_LOCK_NONE).so -shared -o $@ $(SION_COMMON_LOCK_NONE_OBJS)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_SER).a : $(SION_SER_OBJS)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_SER_OBJS)
++lib$(SION_LIBNAME_SER).so : $(SION_SER_OBJS)
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_SER).so -shared -o $@ $(SION_SER_OBJS)
+ 	@echo "*** $@ built"
+ 
+ sion_lock_pthreads.o: sion_lock.c
+@@ -178,7 +178,7 @@
+ 	done
+ 
+ clean:
+-	rm -f *.o lib*.a
++	rm -f *.o lib*.so
+ 
+ #------------------------------------------------------------------------------
+ # Dependencies
+diff '--color=auto' -ru sionlib-ori/src/parlib/Makefile sionlib/src/parlib/Makefile
+--- sionlib-ori/src/parlib/Makefile	2021-08-29 01:04:54.921546810 +0200
++++ sionlib/src/parlib/Makefile	2021-08-29 01:03:58.041270101 +0200
+@@ -29,7 +29,7 @@
+ .SUFFIXES:  .cpp .c .f
+ 
+ USER_HDRS = sion_datatypes_mpi.h sion_mpi.h sion_ompi.h sion_omp.h sion_generic.h 
+-USER_LIBS = lib$(SION_LIBNAME_GEN).a
++USER_LIBS = lib$(SION_LIBNAME_GEN).so
+ 
+ SION_OBJS_GEN = sion_generic.o \
+ 	sion_generic_internal.o \
+@@ -46,7 +46,7 @@
+ 	          sion_omp_cb_gen.o \
+ 	          sion_omp_internal_gen.o 
+   USER_HDRS += sion_omp.h 
+-  USER_LIBS += lib$(SION_LIBNAME_OMP).a 
++  USER_LIBS += lib$(SION_LIBNAME_OMP).so
+ endif
+ 
+ ifeq ($(MPIENABLE),1)
+@@ -58,7 +58,7 @@
+ 	          sion_mpi_util.o  \
+ 		  sion_mpi_file_check.o
+   USER_HDRS += sion_datatypes_mpi.h sion_mpi.h 
+-  USER_LIBS += lib$(SION_LIBNAME_MPI).a 
++  USER_LIBS += lib$(SION_LIBNAME_MPI).so
+ endif
+ ifeq ($(HYBENABLE),1)
+   SION_OBJS_HYB = sion_ompi_gen.o \
+@@ -67,16 +67,18 @@
+ 	          sion_ompi_util.o \
+                   sion_ompi_internal_gen.o 
+   USER_HDRS += sion_datatypes_mpi.h sion_ompi.h
+-  USER_LIBS += lib$(SION_LIBNAME_OMPI).a 
++  USER_LIBS += lib$(SION_LIBNAME_OMPI).so
+ endif   
+ 
+ ifeq ($(HYBENABLE),1)
+   LOCKCC    =$(HYBCC)
+   LOCKCFLAGS=$(CHYBFLAGS)
++  LOCKLINK=$(HYBFLAG)
+ else 
+ ifeq ($(OMPENABLE),1)
+   LOCKCC    =$(OMPCC)
+   LOCKCFLAGS=$(COMPFLAGS)
++  LOCKLINK=$(OMPFLAG)
+ else
+   LOCKCC    =$(CC)
+   LOCKCFLAGS=$(CFLAGS)
+@@ -87,20 +89,20 @@
+ 
+ all: $(USER_LIBS)
+ 
+-lib$(SION_LIBNAME_GEN).a : $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL)
++lib$(SION_LIBNAME_GEN).so : $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL)
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_GEN).so -shared -o $@ $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL) $(LOCKLINK)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_OMP).a : $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL)
++lib$(SION_LIBNAME_OMP).so : $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL)
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMP).so -shared -o $@ $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) $(LOCKLINK) $(OMPFLAG)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_MPI).a : $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL)
++lib$(SION_LIBNAME_MPI).so : $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL)
++	$(MPICC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_MPI).so -shared -o $@ $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) $(LOCKLINK)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_OMPI).a : $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL)
+-	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL)
++lib$(SION_LIBNAME_OMPI).so : $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL)
++	$(HYBCC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMPI).so -shared -o $@ $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) $(LOCKLINK) $(HYBFLAG)
+ 	@echo "*** $@ built"
+ 
+ sion_generic.o : sion_generic.c
+@@ -224,7 +226,7 @@
+ 	done
+ 
+ clean:
+-	rm -f *.o lib*.a opari*
++	rm -f *.o lib*.so opari*
+ 
+ #------------------------------------------------------------------------------
+ # Dependencies
+diff '--color=auto' -ru sionlib-ori/src/parutils/Makefile sionlib/src/parutils/Makefile
+--- sionlib-ori/src/parutils/Makefile	2021-08-29 01:04:54.928546844 +0200
++++ sionlib/src/parutils/Makefile	2021-08-29 00:44:20.571541969 +0200
+@@ -75,10 +75,10 @@
+ 
+ all: $(USER_UTILS)
+ 
+-partest: $(PARTEST_OBJS) ../parlib/lib$(SION_LIBNAME_MPI).a  ../parlib/lib$(SION_LIBNAME_GEN).a  ../lib/lib$(SION_LIBNAME_SER).a 
++partest: $(PARTEST_OBJS) ../parlib/lib$(SION_LIBNAME_MPI).so  ../parlib/lib$(SION_LIBNAME_GEN).so  ../lib/lib$(SION_LIBNAME_SER).so
+ 	$(MPICC) -o $@ $(PARTEST_OBJS) -L../lib -l$(SION_LIBNAME_SER) $(CMPILDFLAGS) $(MPILIB)
+ 
+-ompi_partest: $(PARTEST_OMPI_OBJS) ../parlib/lib$(SION_LIBNAME_OMPI).a ../parlib/lib$(SION_LIBNAME_OMP).a ../lib/lib$(SION_LIBNAME_SER).a 
++ompi_partest: $(PARTEST_OMPI_OBJS) ../parlib/lib$(SION_LIBNAME_OMPI).so ../parlib/lib$(SION_LIBNAME_OMP).so ../lib/lib$(SION_LIBNAME_SER).so
+ 	$(HYBCC) -o $@ $(PARTEST_OMPI_OBJS) $(CHYBLDFLAGS) -L../parlib -l$(SION_LIBNAME_OMP) -L../lib -l$(SION_LIBNAME_SER)  $(MPILIB)
+ 
+ ompi_partest.o : ompi_partest.c
+@@ -114,7 +114,7 @@
+ fpartest.o : fpartest.F90
+ 	$(MPIF90) $(FFLAGS) -c fpartest.F90
+ 
+-fpartest: fpartest.o  ../parlib/lib$(SION_LIBNAME_MPI).a  ../parlib/lib$(SION_LIBNAME_GEN).a ../lib/lib$(SION_LIBNAME_SER).a ../fortraninterface/lib$(SION_LIBNAME_F77_MPI).a ../fortraninterface/lib$(SION_LIBNAME_F77_SER).a
++fpartest: fpartest.o  ../parlib/lib$(SION_LIBNAME_MPI).so  ../parlib/lib$(SION_LIBNAME_GEN).so ../lib/lib$(SION_LIBNAME_SER).so ../fortraninterface/lib$(SION_LIBNAME_F77_MPI).so ../fortraninterface/lib$(SION_LIBNAME_F77_SER).so
+ 	$(MPIF90) -o $@ fpartest.o  -L../fortraninterface -l$(SION_LIBNAME_F77_MPI) -l$(SION_LIBNAME_F77_SER) $(FMPILDFLAGS) $(MPILIB) 
+ 
+ 
+@@ -161,7 +161,7 @@
+ 	@rm -f header.tmp
+ 
+ clean:
+-	rm -f *.o lib*.a $(USER_UTILS)
++	rm -f *.o lib*.so $(USER_UTILS)
+ 
+ #------------------------------------------------------------------------------
+ # Dependencies
+diff '--color=auto' -ru sionlib-ori/src/utils/Makefile sionlib/src/utils/Makefile
+--- sionlib-ori/src/utils/Makefile	2021-08-29 01:04:54.925546830 +0200
++++ sionlib/src/utils/Makefile	2021-08-29 00:44:20.568541955 +0200
+@@ -45,32 +45,32 @@
+ siondump.o : siondump.c 
+ 	$(CC) $(CFLAGS) -c siondump.c
+ 
+-siondefrag.o : siondefrag.c ../lib/lib$(SION_LIBNAME_SER).a 
++siondefrag.o : siondefrag.c ../lib/lib$(SION_LIBNAME_SER).so
+ 	$(CC) $(CFLAGS) -c siondefrag.c
+ 
+-sionsplit.o : sionsplit.c ../lib/lib$(SION_LIBNAME_SER).a  
++sionsplit.o : sionsplit.c ../lib/lib$(SION_LIBNAME_SER).so
+ 	$(CC) $(CFLAGS) -c sionsplit.c
+ 
+-sioncat.o : sioncat.c ../lib/lib$(SION_LIBNAME_SER).a  
++sioncat.o : sioncat.c ../lib/lib$(SION_LIBNAME_SER).so
+ 	$(CC) $(CFLAGS) -c sioncat.c
+ 
+-sionversion.o : sionversion.c ../lib/lib$(SION_LIBNAME_SER).a  
++sionversion.o : sionversion.c ../lib/lib$(SION_LIBNAME_SER).so
+ 	$(CC) $(CFLAGS) -c sionversion.c
+ 
+-siondump: siondump.o ../lib/lib$(SION_LIBNAME_SER).a  ../lib/lib$(SION_LIBNAME_COM).a  ../lib/lib$(SION_LIBNAME_COM_LOCK_NONE).a
++siondump: siondump.o ../lib/lib$(SION_LIBNAME_SER).so  ../lib/lib$(SION_LIBNAME_COM).so  ../lib/lib$(SION_LIBNAME_COM_LOCK_NONE).so
+ 	$(CC)  -o $@ siondump.o $(LDFLAGS)
+ 	cp siondump $(TOPDIR)/..
+ 
+-siondefrag: siondefrag.o ../lib/lib$(SION_LIBNAME_SER).a  ../lib/lib$(SION_LIBNAME_COM).a  ../lib/lib$(SION_LIBNAME_COM_LOCK_NONE).a
++siondefrag: siondefrag.o ../lib/lib$(SION_LIBNAME_SER).so  ../lib/lib$(SION_LIBNAME_COM).so  ../lib/lib$(SION_LIBNAME_COM_LOCK_NONE).so
+ 	$(CC)  -o $@ siondefrag.o $(LDFLAGS)
+ 
+-sionsplit: sionsplit.o ../lib/lib$(SION_LIBNAME_SER).a  ../lib/lib$(SION_LIBNAME_COM).a  ../lib/lib$(SION_LIBNAME_COM_LOCK_NONE).a
++sionsplit: sionsplit.o ../lib/lib$(SION_LIBNAME_SER).so  ../lib/lib$(SION_LIBNAME_COM).so  ../lib/lib$(SION_LIBNAME_COM_LOCK_NONE).so
+ 	$(CC)  -o $@ sionsplit.o $(LDFLAGS)
+ 
+-sioncat: sioncat.o ../lib/lib$(SION_LIBNAME_SER).a  ../lib/lib$(SION_LIBNAME_COM).a  ../lib/lib$(SION_LIBNAME_COM_LOCK_NONE).a
++sioncat: sioncat.o ../lib/lib$(SION_LIBNAME_SER).so  ../lib/lib$(SION_LIBNAME_COM).so  ../lib/lib$(SION_LIBNAME_COM_LOCK_NONE).so
+ 	$(CC)  -o $@ sioncat.o $(LDFLAGS)
+ 
+-sionversion: sionversion.o ../lib/lib$(SION_LIBNAME_SER).a  ../lib/lib$(SION_LIBNAME_COM).a  ../lib/lib$(SION_LIBNAME_COM_LOCK_NONE).a
++sionversion: sionversion.o ../lib/lib$(SION_LIBNAME_SER).so  ../lib/lib$(SION_LIBNAME_COM).so  ../lib/lib$(SION_LIBNAME_COM_LOCK_NONE).so
+ 	$(CC)  -o $@ sionversion.o $(LDFLAGS)
+ 
+ 
+@@ -136,7 +136,7 @@
+ 	@rm -f header.tmp
+ 
+ clean:
+-	rm -f *.o lib*.a $(USER_UTILS)
++	rm -f *.o lib*.so $(USER_UTILS)
+ 
+ #------------------------------------------------------------------------------
+ # Dependencies

diff --git a/sys-cluster/sionlib/files/sionlib-respect-flags-v3.patch b/sys-cluster/sionlib/files/sionlib-respect-flags-v3.patch
index 7bf98ced1..e71d7d46d 100644
--- a/sys-cluster/sionlib/files/sionlib-respect-flags-v3.patch
+++ b/sys-cluster/sionlib/files/sionlib-respect-flags-v3.patch
@@ -115,18 +115,18 @@
  
 -CC       = gcc
 -CFLAGS   = -std=c99 $(PFLAG) $(OPTFLAGS) -fPIC
-+CXXFLAGS += $(PFLAG)
++CXXFLAGS += $(PFLAG) -fPIC
  
 -CXX      = g++
 -CXXFLAGS = $(PFLAG) $(OPTFLAGS) -O3
 -
 -F77      = gfortran
 -FFLAGS   = $(PFLAG) $(OPTFLAGS) -fallow-argument-mismatch
-+FFLAGS   += $(PFLAG) -fallow-argument-mismatch
++FFLAGS   += $(PFLAG) -fallow-argument-mismatch -fPIC
  
  F90      = $(F77)
 -F90FLAGS = $(PFLAG) $(OPTFLAGS) -ffree-form -fallow-argument-mismatch
-+F90FLAGS += $(PFLAG) -ffree-form -fallow-argument-mismatch
++F90FLAGS += $(PFLAG) -ffree-form -fallow-argument-mismatch -fPIC $(FCFLAGS)
  
  FPP      =
  FDOPT    = -D

diff --git a/sys-cluster/sionlib/sionlib-1.7.7-r2.ebuild b/sys-cluster/sionlib/sionlib-1.7.7-r3.ebuild
similarity index 96%
rename from sys-cluster/sionlib/sionlib-1.7.7-r2.ebuild
rename to sys-cluster/sionlib/sionlib-1.7.7-r3.ebuild
index 33e8dbdd8..9fbf33425 100644
--- a/sys-cluster/sionlib/sionlib-1.7.7-r2.ebuild
+++ b/sys-cluster/sionlib/sionlib-1.7.7-r3.ebuild
@@ -20,9 +20,6 @@ SLOT="0"
 KEYWORDS="~amd64"
 IUSE="+cxx debug deep-est-sdv doc examples +fortran hostname-regex +mpi +ompi +openmp +parutils +pthreads python sionfwd" #cuda
 
-REQUIRED_USE="?? ( hostname-regex deep-est-sdv )"
-PATCHES=( "${FILESDIR}/${PN}-respect-flags-v3.patch" )
-
 RDEPEND="
 	mpi? ( virtual/mpi )
 	ompi? (
@@ -37,6 +34,12 @@ DEPEND="
 	${PYTHON_DEPS}
 "
 
+REQUIRED_USE="?? ( hostname-regex deep-est-sdv )"
+PATCHES=(
+	"${FILESDIR}/${PN}-respect-flags-v3.patch"
+	"${FILESDIR}/${PN}-build-shared-libraries.patch"
+)
+
 pkg_setup() {
 	FORTRAN_NEED_OPENMP=0
 	use openmp && FORTRAN_NEED_OPENMP=1
@@ -119,7 +122,5 @@ src_install() {
 	rsync -ravXHA "${T}/prefix/usr" "${ED}/" || die
 	docompress -x "/usr/share/doc/${PF}/examples"
 
-	#TODO: build shared libs
-	#find "${ED}" -name '*.a' -delete || die
 	find "${ED}" -name '*.la' -delete || die
 }


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [gentoo-commits] repo/proj/guru:dev commit in: sys-cluster/sionlib/, sys-cluster/sionlib/files/
@ 2021-08-29 22:33 Alessandro Barbieri
  0 siblings, 0 replies; 4+ messages in thread
From: Alessandro Barbieri @ 2021-08-29 22:33 UTC (permalink / raw
  To: gentoo-commits

commit:     9eae29ade42e8dbbab389b3b19543d793363e202
Author:     Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
AuthorDate: Sun Aug 29 15:39:40 2021 +0000
Commit:     Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
CommitDate: Sun Aug 29 22:33:07 2021 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=9eae29ad

sys-cluster/sionlib: fix linking issues

Signed-off-by: Alessandro Barbieri <lssndrbarbieri <AT> gmail.com>

 .../files/sionlib-build-shared-libraries.patch     | 16 +++----
 .../sionlib/files/sionlib-fix-linking.patch        | 52 ++++++++++++++++++++++
 ...lib-1.7.7-r3.ebuild => sionlib-1.7.7-r4.ebuild} |  7 ++-
 3 files changed, 65 insertions(+), 10 deletions(-)

diff --git a/sys-cluster/sionlib/files/sionlib-build-shared-libraries.patch b/sys-cluster/sionlib/files/sionlib-build-shared-libraries.patch
index 2f41d58c1..30e6cd32e 100644
--- a/sys-cluster/sionlib/files/sionlib-build-shared-libraries.patch
+++ b/sys-cluster/sionlib/files/sionlib-build-shared-libraries.patch
@@ -211,26 +211,26 @@
  
 -lib$(SION_LIBNAME_GEN).a : $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL)
 -	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL)
-+lib$(SION_LIBNAME_GEN).so : $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL)
-+	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_GEN).so -shared -o $@ $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL) $(LOCKLINK)
++lib$(SION_LIBNAME_GEN).so : $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_GEN).so -shared -o $@ $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM)
  	@echo "*** $@ built"
  
 -lib$(SION_LIBNAME_OMP).a : $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL)
 -	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL)
-+lib$(SION_LIBNAME_OMP).so : $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL)
-+	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMP).so -shared -o $@ $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) $(LOCKLINK) $(OMPFLAG)
++lib$(SION_LIBNAME_OMP).so : $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMP).so -shared -o $@ $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) $(OMPFLAG)
  	@echo "*** $@ built"
  
 -lib$(SION_LIBNAME_MPI).a : $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL)
 -	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL)
-+lib$(SION_LIBNAME_MPI).so : $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL)
-+	$(MPICC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_MPI).so -shared -o $@ $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) $(LOCKLINK)
++lib$(SION_LIBNAME_MPI).so : $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
++	$(MPICC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_MPI).so -shared -o $@ $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM)
  	@echo "*** $@ built"
  
 -lib$(SION_LIBNAME_OMPI).a : $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL)
 -	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL)
-+lib$(SION_LIBNAME_OMPI).so : $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL)
-+	$(HYBCC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMPI).so -shared -o $@ $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) $(LOCKLINK) $(HYBFLAG)
++lib$(SION_LIBNAME_OMPI).so : $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
++	$(HYBCC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMPI).so -shared -o $@ $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) $(HYBFLAG)
  	@echo "*** $@ built"
  
  sion_generic.o : sion_generic.c

diff --git a/sys-cluster/sionlib/files/sionlib-fix-linking.patch b/sys-cluster/sionlib/files/sionlib-fix-linking.patch
new file mode 100644
index 000000000..7148eff31
--- /dev/null
+++ b/sys-cluster/sionlib/files/sionlib-fix-linking.patch
@@ -0,0 +1,52 @@
+diff '--color=auto' -ru sionlib-ori/src/lib/Makefile sionlib/src/lib/Makefile
+--- sionlib-ori/src/lib/Makefile	2021-08-29 08:14:05.901799434 +0200
++++ sionlib/src/lib/Makefile	2021-08-29 16:49:25.241515611 +0200
+@@ -66,14 +66,20 @@
+ SION_CXX_HDR = sion_cxx.h
+ endif
+ 
++ifeq ($(PTHREADSUPPORT),"yes")
++LOCKLIB = $(SION_LIBNAME_COM_LOCK_PTHREADS)
++else
++LOCKLIB = $(SION_LIBNAME_COM_LOCK_NONE)
++endif
++
+ USER_HDRS = sion.h sion_common.h sion_serial.h sion_const.h sion_datatypes.h sion_platform.h sion_debug.h $(SION_CXX_HDR)
+ USER_LIBS = lib$(SION_LIBNAME_SER).so lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_COM_LOCK_PTHREADS).so lib$(SION_LIBNAME_COM_LOCK_NONE).so
+ 
+ 
+ all: lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_SER).so  lib$(SION_LIBNAME_COM_LOCK_PTHREADS).so lib$(SION_LIBNAME_COM_LOCK_NONE).so
+ 
+-lib$(SION_LIBNAME_COM).so : $(SION_COMMON_OBJS)
+-	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_COM).so -shared -o $@ $(SION_COMMON_OBJS)
++lib$(SION_LIBNAME_COM).so : $(SION_COMMON_OBJS) lib$(LOCKLIB).so
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_COM).so -shared -o $@ $(SION_COMMON_OBJS) $(SIONFWD_LIBS) -l$(LOCKLIB)
+ 	@echo "*** $@ built"
+ 
+ lib$(SION_LIBNAME_COM_LOCK_PTHREADS).so : $(SION_COMMON_LOCK_PTHREADS_OBJS)
+diff '--color=auto' -ru sionlib-ori/src/parlib/Makefile sionlib/src/parlib/Makefile
+--- sionlib-ori/src/parlib/Makefile	2021-08-29 08:14:05.888799373 +0200
++++ sionlib/src/parlib/Makefile	2021-08-29 17:21:42.262938785 +0200
+@@ -93,16 +93,16 @@
+ 	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_GEN).so -shared -o $@ $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL) $(LOCKLINK)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_OMP).so : $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
+-	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMP).so -shared -o $@ $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) $(OMPFLAG)
++lib$(SION_LIBNAME_OMP).so : $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_GEN).so
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMP).so -shared -o $@ $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) -l$(SION_LIBNAME_GEN) $(OMPFLAG)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_MPI).so : $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
+-	$(MPICC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_MPI).so -shared -o $@ $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM)
++lib$(SION_LIBNAME_MPI).so : $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_GEN).so
++	$(MPICC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_MPI).so -shared -o $@ $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) -l$(SION_LIBNAME_GEN)
+ 	@echo "*** $@ built"
+ 
+-lib$(SION_LIBNAME_OMPI).so : $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
+-	$(HYBCC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMPI).so -shared -o $@ $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) $(HYBFLAG)
++lib$(SION_LIBNAME_OMPI).so : $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_GEN).so
++	$(HYBCC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMPI).so -shared -o $@ $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) -l$(SION_LIBNAME_GEN) $(HYBFLAG)
+ 	@echo "*** $@ built"
+ 
+ sion_generic.o : sion_generic.c

diff --git a/sys-cluster/sionlib/sionlib-1.7.7-r3.ebuild b/sys-cluster/sionlib/sionlib-1.7.7-r4.ebuild
similarity index 96%
rename from sys-cluster/sionlib/sionlib-1.7.7-r3.ebuild
rename to sys-cluster/sionlib/sionlib-1.7.7-r4.ebuild
index 9fbf33425..76df6efc6 100644
--- a/sys-cluster/sionlib/sionlib-1.7.7-r3.ebuild
+++ b/sys-cluster/sionlib/sionlib-1.7.7-r4.ebuild
@@ -38,6 +38,7 @@ REQUIRED_USE="?? ( hostname-regex deep-est-sdv )"
 PATCHES=(
 	"${FILESDIR}/${PN}-respect-flags-v3.patch"
 	"${FILESDIR}/${PN}-build-shared-libraries.patch"
+	"${FILESDIR}/${PN}-fix-linking.patch"
 )
 
 pkg_setup() {
@@ -65,9 +66,13 @@ src_configure() {
 	use hostname-regex && msa="hostname-regex"
 
 	local myconf=(
+		--disable-gcovr
+		--disable-kcov
 		--disable-mic
 		--msa="${msa}"
 		--prefix="${T}/prefix/usr"
+		$(use_enable debug)
+		$(use_enable pthreads)
 	)
 
 	#custom configure?
@@ -77,9 +82,7 @@ src_configure() {
 	use ompi || myconf+=( "--disable-ompi" )
 	use openmp || myconf+=( "--disable-omp" )
 	use parutils || myconf+=( "--disable-parutils" )
-	use pthreads || myconf+=( "--disable-pthreads" )
 
-	use debug && myconf+=( "--enable-debug" )
 	use python && myconf+=( "--enable-python=3" )
 	use sionfwd && myconf+=( "--enable-sionfwd=${EPREFIX}/usr" )
 


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [gentoo-commits] repo/proj/guru:dev commit in: sys-cluster/sionlib/, sys-cluster/sionlib/files/
@ 2021-08-29 22:33 Alessandro Barbieri
  0 siblings, 0 replies; 4+ messages in thread
From: Alessandro Barbieri @ 2021-08-29 22:33 UTC (permalink / raw
  To: gentoo-commits

commit:     80ceb49a9fca18a91c44ebbcf67774ff9b6648e0
Author:     Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
AuthorDate: Sun Aug 29 22:32:30 2021 +0000
Commit:     Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
CommitDate: Sun Aug 29 22:33:07 2021 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=80ceb49a

sys-cluster/sionlib: merge patches

Signed-off-by: Alessandro Barbieri <lssndrbarbieri <AT> gmail.com>

 .../files/sionlib-build-shared-libraries.patch     | 46 ++++++++++++++-----
 .../sionlib/files/sionlib-fix-linking.patch        | 52 ----------------------
 sys-cluster/sionlib/sionlib-1.7.7-r4.ebuild        |  1 -
 3 files changed, 35 insertions(+), 64 deletions(-)

diff --git a/sys-cluster/sionlib/files/sionlib-build-shared-libraries.patch b/sys-cluster/sionlib/files/sionlib-build-shared-libraries.patch
index 30e6cd32e..6d5c69f48 100644
--- a/sys-cluster/sionlib/files/sionlib-build-shared-libraries.patch
+++ b/sys-cluster/sionlib/files/sionlib-build-shared-libraries.patch
@@ -111,9 +111,16 @@
  # Dependencies
 --- a/src/lib/Makefile
 +++ b/src/lib/Makefile
-@@ -67,25 +67,25 @@
+@@ -66,26 +66,32 @@
+ SION_CXX_HDR = sion_cxx.h
  endif
  
++ifneq ($(PTHREADSUPPORT),"no")
++LOCKLIB = $(SION_LIBNAME_COM_LOCK_PTHREADS)
++else
++LOCKLIB = $(SION_LIBNAME_COM_LOCK_NONE)
++endif
++
  USER_HDRS = sion.h sion_common.h sion_serial.h sion_const.h sion_datatypes.h sion_platform.h sion_debug.h $(SION_CXX_HDR)
 -USER_LIBS = lib$(SION_LIBNAME_SER).a lib$(SION_LIBNAME_COM).a lib$(SION_LIBNAME_COM_LOCK_PTHREADS).a lib$(SION_LIBNAME_COM_LOCK_NONE).a 
 +USER_LIBS = lib$(SION_LIBNAME_SER).so lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_COM_LOCK_PTHREADS).so lib$(SION_LIBNAME_COM_LOCK_NONE).so
@@ -124,8 +131,8 @@
  
 -lib$(SION_LIBNAME_COM).a : $(SION_COMMON_OBJS)
 -	$(C_AR) $(AFLAG) -rcs $@ $(SION_COMMON_OBJS)
-+lib$(SION_LIBNAME_COM).so : $(SION_COMMON_OBJS)
-+	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_COM).so -shared -o $@ $(SION_COMMON_OBJS)
++lib$(SION_LIBNAME_COM).so : $(SION_COMMON_OBJS) lib$(LOCKLIB).so
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_COM).so -shared -o $@ $(SION_COMMON_OBJS) $(SIONFWD_LIBS) -L. -l$(LOCKLIB)
  	@echo "*** $@ built"
  
 -lib$(SION_LIBNAME_COM_LOCK_PTHREADS).a : $(SION_COMMON_LOCK_PTHREADS_OBJS)
@@ -147,7 +154,7 @@
  	@echo "*** $@ built"
  
  sion_lock_pthreads.o: sion_lock.c
-@@ -178,7 +178,7 @@
+@@ -178,7 +184,7 @@
  	done
  
  clean:
@@ -212,25 +219,25 @@
 -lib$(SION_LIBNAME_GEN).a : $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL)
 -	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL)
 +lib$(SION_LIBNAME_GEN).so : $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
-+	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_GEN).so -shared -o $@ $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM)
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_GEN).so -shared -o $@ $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL) $(LOCKLINK) -L../lib -l$(SION_LIBNAME_COM)
  	@echo "*** $@ built"
  
 -lib$(SION_LIBNAME_OMP).a : $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL)
 -	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL)
-+lib$(SION_LIBNAME_OMP).so : $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
-+	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMP).so -shared -o $@ $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) $(OMPFLAG)
++lib$(SION_LIBNAME_OMP).so : $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_GEN).so
++	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMP).so -shared -o $@ $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) $(LOCKLINK) -L../lib -l$(SION_LIBNAME_COM) -L. -l$(SION_LIBNAME_GEN) $(OMPFLAG)
  	@echo "*** $@ built"
  
 -lib$(SION_LIBNAME_MPI).a : $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL)
 -	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL)
-+lib$(SION_LIBNAME_MPI).so : $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
-+	$(MPICC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_MPI).so -shared -o $@ $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM)
++lib$(SION_LIBNAME_MPI).so : $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_GEN).so
++	$(MPICC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_MPI).so -shared -o $@ $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) $(LOCKLINK) -L../lib -l$(SION_LIBNAME_COM) -L. -l$(SION_LIBNAME_GEN)
  	@echo "*** $@ built"
  
 -lib$(SION_LIBNAME_OMPI).a : $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL)
 -	$(C_AR) $(AFLAG) -rcs $@ $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL)
-+lib$(SION_LIBNAME_OMPI).so : $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
-+	$(HYBCC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMPI).so -shared -o $@ $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) $(HYBFLAG)
++lib$(SION_LIBNAME_OMPI).so : $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_GEN).so
++	$(HYBCC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMPI).so -shared -o $@ $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) $(LOCKLINK) -L../lib -l$(SION_LIBNAME_COM) -L. -l$(SION_LIBNAME_GEN) $(HYBFLAG)
  	@echo "*** $@ built"
  
  sion_generic.o : sion_generic.c
@@ -245,6 +252,23 @@
  # Dependencies
 --- a/src/parutils/Makefile
 +++ b/src/parutils/Makefile
+@@ -30,12 +30,12 @@
+ COMPFLAGS = $(OMPMFLAG) $(OMPFLAG)
+ CHYBFLAGS = $(HYBMFLAG) $(HYBFLAG)
+ 
+-CMPILDFLAGS = $(LDFLAGS) -L../parlib -l$(SION_LIBNAME_MPI) -L../lib -l$(SION_LIBNAME_GEN) -L../lib -l$(SION_LIBNAME_COM) -l$(SION_LIBNAME_COM_LOCK_PTHREADS) $(HINTSLIB) $(CACHELIB) $(CUDA_LIBRARY_PATHS) $(CUDA_LIBRARIES) $(SIONFWD_LIBS) $(IMELIB_LIBPATH) $(IMELIB_LIB)
++CMPILDFLAGS = $(LDFLAGS) -L../parlib -l$(SION_LIBNAME_MPI) -L../lib -l$(SION_LIBNAME_GEN) -L../lib -l$(SION_LIBNAME_COM) $(HINTSLIB) $(CACHELIB) $(CUDA_LIBRARY_PATHS) $(CUDA_LIBRARIES) $(SIONFWD_LIBS) $(IMELIB_LIBPATH) $(IMELIB_LIB)
+
+-COMPLDFLAGS = $(LDFLAGS) -L../parlib -l$(SION_LIBNAME_OMP)  -L../lib -l$(SION_LIBNAME_COM) -l$(SION_LIBNAME_COM_LOCK_PTHREADS) $(HINTSLIB) $(CACHELIB) $(OMPFLAG) $(CUDA_LIBRARY_PATHS) $(CUDA_LIBRARIES) $(SIONFWD_LIBS) $(IMELIB_LIBPATH) $(IMELIB_LIB)
+-CHYBLDFLAGS = $(LDFLAGS) -L../parlib -l$(SION_LIBNAME_OMPI) -L../lib -l$(SION_LIBNAME_GEN) -L../lib -l$(SION_LIBNAME_COM) -l$(SION_LIBNAME_COM_LOCK_PTHREADS) $(HINTSLIB) $(CACHELIB) $(OMPFLAG) $(CUDA_LIBRARY_PATHS) $(CUDA_LIBRARIES) $(SIONFWD_LIBS) $(IMELIB_LIBPATH) $(IMELIB_LIB)
++COMPLDFLAGS = $(LDFLAGS) -L../parlib -l$(SION_LIBNAME_OMP)  -L../lib -l$(SION_LIBNAME_COM) $(HINTSLIB) $(CACHELIB) $(OMPFLAG) $(CUDA_LIBRARY_PATHS) $(CUDA_LIBRARIES) $(SIONFWD_LIBS) $(IMELIB_LIBPATH) $(IMELIB_LIB)
++CHYBLDFLAGS = $(LDFLAGS) -L../parlib -l$(SION_LIBNAME_OMPI) -L../lib -l$(SION_LIBNAME_GEN) -L../lib -l$(SION_LIBNAME_COM) $(HINTSLIB) $(CACHELIB) $(OMPFLAG) $(CUDA_LIBRARY_PATHS) $(CUDA_LIBRARIES) $(SIONFWD_LIBS) $(IMELIB_LIBPATH) $(IMELIB_LIB)
+ 
+-FMPILDFLAGS = $(LDFLAGS) -L../parlib -l$(SION_LIBNAME_MPI) -L../lib -l$(SION_LIBNAME_GEN) -L../lib -l$(SION_LIBNAME_SER) -l$(SION_LIBNAME_COM) -l$(SION_LIBNAME_COM_LOCK_PTHREADS) $(HINTSLIB) $(CACHELIB) $(CUDA_LIBRARY_PATHS) $(CUDA_LIBRARIES) $(SIONFWD_LIBS) $(IMELIB_LIBPATH) $(IMELIB_LIB)
++FMPILDFLAGS = $(LDFLAGS) -L../parlib -l$(SION_LIBNAME_MPI) -L../lib -l$(SION_LIBNAME_GEN) -L../lib -l$(SION_LIBNAME_SER) -l$(SION_LIBNAME_COM) $(HINTSLIB) $(CACHELIB) $(CUDA_LIBRARY_PATHS) $(CUDA_LIBRARIES) $(SIONFWD_LIBS) $(IMELIB_LIBPATH) $(IMELIB_LIB)
+ FOMPLDFLAGS = $(COMPLDFLAGS)  $(OMPFLAG)
+ FHYBLDFLAGS = $(COMPILDFLAGS) $(OMPFLAG)
+ 
 @@ -55,6 +55,13 @@
  ifeq ($(FORTRANENABLE),1)
    ifeq ($(MPIENABLE),1)

diff --git a/sys-cluster/sionlib/files/sionlib-fix-linking.patch b/sys-cluster/sionlib/files/sionlib-fix-linking.patch
deleted file mode 100644
index 7148eff31..000000000
--- a/sys-cluster/sionlib/files/sionlib-fix-linking.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-diff '--color=auto' -ru sionlib-ori/src/lib/Makefile sionlib/src/lib/Makefile
---- sionlib-ori/src/lib/Makefile	2021-08-29 08:14:05.901799434 +0200
-+++ sionlib/src/lib/Makefile	2021-08-29 16:49:25.241515611 +0200
-@@ -66,14 +66,20 @@
- SION_CXX_HDR = sion_cxx.h
- endif
- 
-+ifeq ($(PTHREADSUPPORT),"yes")
-+LOCKLIB = $(SION_LIBNAME_COM_LOCK_PTHREADS)
-+else
-+LOCKLIB = $(SION_LIBNAME_COM_LOCK_NONE)
-+endif
-+
- USER_HDRS = sion.h sion_common.h sion_serial.h sion_const.h sion_datatypes.h sion_platform.h sion_debug.h $(SION_CXX_HDR)
- USER_LIBS = lib$(SION_LIBNAME_SER).so lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_COM_LOCK_PTHREADS).so lib$(SION_LIBNAME_COM_LOCK_NONE).so
- 
- 
- all: lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_SER).so  lib$(SION_LIBNAME_COM_LOCK_PTHREADS).so lib$(SION_LIBNAME_COM_LOCK_NONE).so
- 
--lib$(SION_LIBNAME_COM).so : $(SION_COMMON_OBJS)
--	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_COM).so -shared -o $@ $(SION_COMMON_OBJS)
-+lib$(SION_LIBNAME_COM).so : $(SION_COMMON_OBJS) lib$(LOCKLIB).so
-+	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_COM).so -shared -o $@ $(SION_COMMON_OBJS) $(SIONFWD_LIBS) -l$(LOCKLIB)
- 	@echo "*** $@ built"
- 
- lib$(SION_LIBNAME_COM_LOCK_PTHREADS).so : $(SION_COMMON_LOCK_PTHREADS_OBJS)
-diff '--color=auto' -ru sionlib-ori/src/parlib/Makefile sionlib/src/parlib/Makefile
---- sionlib-ori/src/parlib/Makefile	2021-08-29 08:14:05.888799373 +0200
-+++ sionlib/src/parlib/Makefile	2021-08-29 17:21:42.262938785 +0200
-@@ -93,16 +93,16 @@
- 	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_GEN).so -shared -o $@ $(SION_OBJS_GEN) $(SION_OBJS_INTERNAL) $(LOCKLINK)
- 	@echo "*** $@ built"
- 
--lib$(SION_LIBNAME_OMP).so : $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
--	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMP).so -shared -o $@ $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) $(OMPFLAG)
-+lib$(SION_LIBNAME_OMP).so : $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_GEN).so
-+	$(CC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMP).so -shared -o $@ $(SION_OBJS_OMP) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) -l$(SION_LIBNAME_GEN) $(OMPFLAG)
- 	@echo "*** $@ built"
- 
--lib$(SION_LIBNAME_MPI).so : $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
--	$(MPICC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_MPI).so -shared -o $@ $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM)
-+lib$(SION_LIBNAME_MPI).so : $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_GEN).so
-+	$(MPICC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_MPI).so -shared -o $@ $(SION_OBJS_MPI) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) -l$(SION_LIBNAME_GEN)
- 	@echo "*** $@ built"
- 
--lib$(SION_LIBNAME_OMPI).so : $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so
--	$(HYBCC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMPI).so -shared -o $@ $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) $(HYBFLAG)
-+lib$(SION_LIBNAME_OMPI).so : $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) ../lib/lib$(SION_LIBNAME_COM).so lib$(SION_LIBNAME_GEN).so
-+	$(HYBCC) $(LDFLAGS) -Wl,-soname,lib$(SION_LIBNAME_OMPI).so -shared -o $@ $(SION_OBJS_HYB) $(SION_OBJS_INTERNAL) $(LOCKLINK) -l$(SION_LIBNAME_COM) -l$(SION_LIBNAME_GEN) $(HYBFLAG)
- 	@echo "*** $@ built"
- 
- sion_generic.o : sion_generic.c

diff --git a/sys-cluster/sionlib/sionlib-1.7.7-r4.ebuild b/sys-cluster/sionlib/sionlib-1.7.7-r4.ebuild
index 76df6efc6..3cc5f940f 100644
--- a/sys-cluster/sionlib/sionlib-1.7.7-r4.ebuild
+++ b/sys-cluster/sionlib/sionlib-1.7.7-r4.ebuild
@@ -38,7 +38,6 @@ REQUIRED_USE="?? ( hostname-regex deep-est-sdv )"
 PATCHES=(
 	"${FILESDIR}/${PN}-respect-flags-v3.patch"
 	"${FILESDIR}/${PN}-build-shared-libraries.patch"
-	"${FILESDIR}/${PN}-fix-linking.patch"
 )
 
 pkg_setup() {


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-08-29 22:33 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-04-25  1:01 [gentoo-commits] repo/proj/guru:dev commit in: sys-cluster/sionlib/, sys-cluster/sionlib/files/ Alessandro Barbieri
  -- strict thread matches above, loose matches on Subject: below --
2021-08-29  0:33 Alessandro Barbieri
2021-08-29 22:33 Alessandro Barbieri
2021-08-29 22:33 Alessandro Barbieri

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