Create static and shared versions of the PORD library.
Index: mumps/PORD/lib/Makefile
===================================================================
--- mumps.orig/PORD/lib/Makefile
+++ mumps/PORD/lib/Makefile
@@ -9,7 +9,7 @@
INCLUDES = -I../include
-COPTIONS = $(INCLUDES) $(CFLAGS) $(OPTFLAGS)
+COPTIONS = $(INCLUDES) $(CFLAGS) $(OPTFLAGS) -fPIC
OBJS = graph.o gbipart.o gbisect.o ddcreate.o ddbisect.o nestdiss.o \
multisector.o gelim.o bucket.o tree.o \
@@ -24,12 +24,16 @@ OBJS = graph.o gbipart.o gbisect.o ddcre
.c.o:
$(CC) $(COPTIONS) -c $*.c $(OUTC)$*.o
-libpord$(LIBEXT):$(OBJS)
- $(AR)$@ $(OBJS)
+libpord$(PLAT).a:$(OBJS)
+ $(AR) $@ $(OBJS)
$(RANLIB) $@
+libpord$(PLAT).so: $(OBJS)
+ $(CC) -shared $(OBJS) -Wl,-soname,libpord$(PLAT)-5.2.1.so -o libpord$(PLAT)-5.2.1.so -Wl,-z,defs
+ ln -s libpord$(PLAT)-5.2.1.so $@
+
clean:
rm -f *.o
realclean:
- rm -f *.o libpord.a
+ rm -f *.o libpord*.a *.so
Index: mumps/Makefile
===================================================================
--- mumps.orig/Makefile
+++ mumps/Makefile
@@ -54,7 +54,7 @@ dexamples: d
multi_example: s d c z
(cd examples ; $(MAKE) multi)
-requiredobj: Makefile.inc $(LIBSEQNEEDED) $(libdir)/libpord$(PLAT)$(LIBEXT)
+requiredobj: Makefile.inc $(LIBSEQNEEDED) $(libdir)/libpord$(PLAT).a $(libdir)/libpord$(PLAT).so
# dummy MPI library (sequential version)
@@ -62,19 +62,25 @@ libseqneeded:
(cd libseq; $(MAKE))
# Build the libpord.a library and copy it into $(topdir)/lib
-$(libdir)/libpord$(PLAT)$(LIBEXT):
+$(libdir)/libpord$(PLAT).a:
if [ "$(LPORDDIR)" != "" ] ; then \
cd $(LPORDDIR); \
$(MAKE) CC="$(CC)" CFLAGS="$(OPTC)" AR="$(AR)" RANLIB="$(RANLIB)" OUTC="$(OUTC)" LIBEXT=$(LIBEXT); \
fi;
if [ "$(LPORDDIR)" != "" ] ; then \
- cp $(LPORDDIR)/libpord$(LIBEXT) $@; \
+ cp $(LPORDDIR)/libpord$(PLAT).a $@; \
fi;
+$(libdir)/libpord$(PLAT).so:
+ if [ "$(LPORDDIR)" != "" ] ; then \
+ cd $(LPORDDIR); make CC="$(CC)" CFLAGS="$(OPTC)" AR="$(AR)" ARFUNCT= RANLIB="$(RANLIB)" libpord$(PLAT).so; fi;
+ if [ "$(LPORDDIR)" != "" ] ; then \
+ cp -a $(LPORDDIR)/libpord*.so lib/; fi;
+
clean:
(cd src; $(MAKE) clean)
(cd examples; $(MAKE) clean)
- (cd $(libdir); $(RM) *$(PLAT)$(LIBEXT))
+ (cd $(libdir); $(RM) *$(PLAT).a *$(PLAT).so)
(cd libseq; $(MAKE) clean)
if [ "$(LPORDDIR)" != "" ] ; then \
cd $(LPORDDIR); $(MAKE) realclean; \
49398943fdaf7e2d76acc'>cross-toolchain.scm
Age | Commit message (Expand) | Author |
2020-02-12 | gnu: cross-base: Switch back to 'CROSS_C_INCLUDE_PATH' & co....This is a followup to 2073b55e6b964cb8ca15e8c74cb32dac00f05f0d.
* gnu/build/cross-toolchain.scm (%gcc-include-paths): Switch back to
'C_INCLUDE_PATH' & co.
* gnu/packages/cross-base.scm (%gcc-include-paths): Likewise.
(cross-gcc-arguments): Remove 'treat-glibc-as-system-header' phase.
(cross-gcc)[native-inputs]: Reorder so that libc comes last.
[search-paths]: Add "include/c++" for 'CROSS_CPLUS_INCLUDE_PATH'.
* guix/build-system/gnu.scm (standard-cross-packages): Have "cross-gcc"
appear both for 'host and 'target.
| Ludovic Courtès |
2019-08-29 | Merge branch 'master' into core-updates | Mark H Weaver |
2019-08-28 | gnu: mingw-w64: Update to 6.0.0....* gnu/packages/mingw.scm (mingw-w64): Update to 6.0.0.
* gnu/packages/patches/mingw-w64-6.0.0-gcc.patch: New file.
* gnu/packages/patches/mingw-w64-5.0rc2-gcc-4.9.3.patch: Delete it.
* gnu/local.mk (dist_patch_DATA): Add new patch. Delete old patch.
* gnu/build/cross-toolchain.scm (set-cross-path/mingw): Add additional
autoconf-like substitutions.
| David Thompson |
2019-08-22 | Merge branch 'master' into core-updates | Mark H Weaver |
2019-08-14 | gnu: mingw: Add x86_64 support....This patch parameterizes previously hard-coded instances of
i686-w64-mingw32, adding support for x86_64-w64-mingw32.
* gnu/packages/mingw.scm (make-mingw-w64): New procedure.
(mingw-w64-i686, mingw-w64-x86_64): New variables.
(%mingw-triplet): Remove.
(mingw-w64): Update to point to 'mingw-w64-i686'.
* gnu/packages/cross-base.scm (cross-gcc): Use 'libc' keyword argument
if specified, instead of treating it as a boolean.
(native-libc): Return the correct mingw-w64 depending on machine
specified in target.
* gnu/packages/bootstrap.scm (glibc-dynamic-linker): Add "x86_64-mingw".
* gnu/build/cross-toolchain.scm (set-cross-path/mingw): Replace
hardcoded 'i686-w64-mingw32' instances with 'target' keyword argument.
(cross-gcc-build-phases): Update accordingly; use 'target-mingw?'
implementation of target checking and add commentary.
* gnu/ci.scm (%cross-targets): Add "x86_64-w64-mingw32".
| Carl Dong |
2019-02-28 | gnu: GCC: Move cross-toolchain build fix to (gnu packages cross-base)....This makes sure it is inherited by packages using (cross-gcc ...). This
commit is a followup to 01e8263febb9634564b4b73af49b81a36567a11b.
* gnu/build/cross-toolchain.scm (cross-gcc-build-phases): Move
'treat-glibc-as-system-header' phase ...
* gnu/packages/cross-base.scm (cross-gcc-arguments): ... here.
| Marius Bakke |