diff options
author | Maurice Brémond <Maurice.Bremond@inria.fr> | 2019-10-14 17:44:54 +0200 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2019-10-14 18:25:31 +0200 |
commit | 06e1239502e7cc91f62161f8bab35bbe0119f2e5 (patch) | |
tree | 0f41a73cbd777b822e989b5f7bbb553ffeade417 /gnu/packages/patches/mumps-shared-libseq.patch | |
parent | 5dbc79eb60f4d72953e11f3a7558ef3037b8bdb6 (diff) | |
download | guix-06e1239502e7cc91f62161f8bab35bbe0119f2e5.tar.gz |
gnu: mumps: Build and install shared libraries.
* gnu/packages/patches/mumps-shared-libseq.patch, gnu/packages/patches/mumps-shared-mumps.patch, gnu/packages/patches/mumps-shared-pord.patch: New files. * gnu/local.mk (dist_patch_DATA): Add them. * gnu/packages/maths.scm (mumps)[source](patches): Add them. [arguments]: In 'configure' phase, adjust "Makefile.inc" for shared library support. In 'install' phase, install libmpiseq.so when it exists. Co-authored-by: Ludovic Courtès <ludovic.courtes@inria.fr>
Diffstat (limited to 'gnu/packages/patches/mumps-shared-libseq.patch')
-rw-r--r-- | gnu/packages/patches/mumps-shared-libseq.patch | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/gnu/packages/patches/mumps-shared-libseq.patch b/gnu/packages/patches/mumps-shared-libseq.patch new file mode 100644 index 0000000000..feafcf123b --- /dev/null +++ b/gnu/packages/patches/mumps-shared-libseq.patch @@ -0,0 +1,42 @@ +Create a shared version of the sequential library, MUST BE LAST IN SERIES + +Index: mumps/libseq/Makefile +=================================================================== +--- mumps.orig/libseq/Makefile ++++ mumps/libseq/Makefile +@@ -8,15 +8,17 @@ all: libmpiseq + + include ../Makefile.inc + +-libmpiseq: libmpiseq$(PLAT)$(LIBEXT) ++libmpiseq: libmpiseq$(PLAT).a libmpiseq$(PLAT).so + +-libmpiseq$(PLAT)$(LIBEXT): mpi.o mpic.o elapse.o +- $(AR)$@ mpi.o mpic.o elapse.o ++libmpiseq$(PLAT).a: mpi.o mpic.o elapse.o ++ $(AR) $@ mpi.o mpic.o elapse.o + $(RANLIB) $@ ++libmpiseq$(PLAT).so: mpi.o mpic.o elapse.o ++ $(FC) -shared $^ -Wl,-soname,libmpiseq$(PLAT)-5.1.2.so -o libmpiseq$(PLAT)-5.1.2.so -Wl,-z,defs + .f.o: +- $(FC) $(OPTF) -c $*.f $(OUTF)$*.o ++ $(FC) $(OPTF) -fPIC -c $*.f $(OUTF)$*.o + .c.o: +- $(CC) $(OPTC) $(CDEFS) -I. -c $*.c $(OUTC)$*.o ++ $(CC) $(OPTC) $(CDEFS) -I. -fPIC -c $*.c $(OUTC)$*.o + + clean: +- $(RM) *.o *$(LIBEXT) ++ $(RM) *.o *.a *.so +Index: mumps/Makefile +=================================================================== +--- mumps.orig/Makefile ++++ mumps/Makefile +@@ -60,6 +60,7 @@ requiredobj: Makefile.inc $(LIBSEQNEEDED + + libseqneeded: + (cd libseq; $(MAKE)) ++ cp libseq/lib* $(libdir) + + # Build the libpord.a library and copy it into $(topdir)/lib + $(libdir)/libpord$(PLAT).a: |