Changeset 149006


Ignore:
Timestamp:
May 24, 2016, 9:56:20 PM (3 years ago)
Author:
dstrubbe@…
Message:

mumps: Use linear_algebra port group, thus offering atlas and openblas as options for BLAS. Add test phase: this required undoing the patch in the examples directory which seemed confused about which libraries were being built shared.

Location:
trunk/dports/math/mumps
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/dports/math/mumps/Portfile

    r146242 r149006  
    44PortSystem          1.0
    55PortGroup           mpi 1.0
     6PortGroup           linear_algebra 1.0
    67
    78name                mumps
     
    2829
    2930mpi.enforce_variant scalapack
     31
     32linalg.setup        blas_only
    3033
    3134patch.pre_args      -p1
     
    5962    reinplace "s|^INCPAR.*$|INCPAR = -I\$(topdir)/include|" ${worksrcpath}/Makefile.inc
    6063    reinplace "s|^LIBPAR.*$|LIBPAR = \$(SCALAP)|" ${worksrcpath}/Makefile.inc
    61     reinplace "s|^LIBBLAS.*$|LIBBLAS = -framework Accelerate|" ${worksrcpath}/Makefile.inc
     64    reinplace "s|^LIBBLAS.*$|LIBBLAS = ${linalglib}|" ${worksrcpath}/Makefile.inc
    6265}
    6366
     
    6972
    7073livecheck.type      none
     74
     75test.run            yes
     76test.target         all
     77test.args-append    PREFIX="${prefix}" LPORD=../lib/libpord.a
     78
     79post-test {
     80    if {![catch {sysctl hw.ncpu} result]} {
     81        set njobs $result
     82    } else {
     83        set njobs 1
     84    }
     85    set runcmd "${mpi.exec} -np ${njobs}"
     86
     87    system -W ${worksrcpath}/examples "${runcmd} ./ssimpletest < input_simpletest_real"
     88    system -W ${worksrcpath}/examples "${runcmd} ./dsimpletest < input_simpletest_real"
     89    system -W ${worksrcpath}/examples "${runcmd} ./csimpletest < input_simpletest_cmplx"
     90    system -W ${worksrcpath}/examples "${runcmd} ./zsimpletest < input_simpletest_cmplx"
     91    system -W ${worksrcpath}/examples "${runcmd} ./c_example"
     92}
  • trunk/dports/math/mumps/files/patch-shared.diff

    r140102 r149006  
    6262-       rm -f *.o libpord.a
    6363+       rm -f *.o libpord$(LIBEXT) libpord$(SHAREDLIBEXT)
    64 diff --git a/examples/Makefile b/examples/Makefile
    65 --- a/examples/Makefile
    66 +++ b/examples/Makefile
    67 @@ -18,32 +18,32 @@ s:  ssimpletest
    68  d:     dsimpletest c_example
    69  
    70  
    71  include $(topdir)/Makefile.inc
    72  
    73 -LIBMUMPS_COMMON = $(libdir)/libmumps_common$(PLAT)$(LIBEXT)
    74 +LIBMUMPS_COMMON = $(libdir)/libmumps_common$(PLAT)$(SHAREDLIBEXT)
    75  
    76  
    77 -LIBSMUMPS = $(libdir)/libsmumps$(PLAT)$(LIBEXT) $(LIBMUMPS_COMMON)
    78 +LIBSMUMPS = $(libdir)/libsmumps$(PLAT)$(SHAREDLIBEXT) $(LIBMUMPS_COMMON)
    79  
    80  ssimpletest:  $(LIBSMUMPS)  $$@.o
    81         $(FL) -o $@ $(OPTL) ssimpletest.o  $(LIBSMUMPS) $(LORDERINGS) $(LIBS) $(LIBBLAS) $(LIBOTHERS)
    82  
    83  
    84 -LIBDMUMPS = $(libdir)/libdmumps$(PLAT)$(LIBEXT) $(LIBMUMPS_COMMON)
    85 +LIBDMUMPS = $(libdir)/libdmumps$(PLAT)$(SHAREDLIBEXT) $(LIBMUMPS_COMMON)
    86  
    87  dsimpletest: $(LIBDMUMPS)  $$@.o
    88         $(FL) -o $@ $(OPTL) dsimpletest.o  $(LIBDMUMPS) $(LORDERINGS) $(LIBS) $(LIBBLAS) $(LIBOTHERS)
    89  
    90  
    91 -LIBCMUMPS = $(libdir)/libcmumps$(PLAT)$(LIBEXT) $(LIBMUMPS_COMMON)
    92 +LIBCMUMPS = $(libdir)/libcmumps$(PLAT)$(SHAREDLIBEXT) $(LIBMUMPS_COMMON)
    93  
    94  csimpletest: $(LIBCMUMPS)  $$@.o
    95         $(FL) -o $@ $(OPTL) csimpletest.o  $(LIBCMUMPS) $(LORDERINGS) $(LIBS) $(LIBBLAS) $(LIBOTHERS)
    96  
    97  
    98 -LIBZMUMPS = $(libdir)/libzmumps$(PLAT)$(LIBEXT) $(LIBMUMPS_COMMON)
    99 +LIBZMUMPS = $(libdir)/libzmumps$(PLAT)$(SHAREDLIBEXT) $(LIBMUMPS_COMMON)
    100  
    101  zsimpletest: $(LIBZMUMPS)  $$@.o
    102         $(FL) -o $@ $(OPTL) zsimpletest.o  $(LIBZMUMPS) $(LORDERINGS) $(LIBS) $(LIBBLAS) $(LIBOTHERS)
    103  
    104  
    105 @@ -56,23 +56,23 @@ c_example:  $(LIBDMUMPS) $$@.o
    106         $(FC) $(OPTF) $(INCS) -I. -I$(topdir)/include -c $*.F $(OUTF)$*.o
    107  .c.o:
    108         $(CC) $(OPTC) $(INCS) $(CDEFS) -I. -I$(topdir)/include -I$(topdir)/src -c $*.c $(OUTC)$*.o
    109  
    110  
    111 -$(libdir)/libsmumps$(PLAT)$(LIBEXT):
    112 +$(libdir)/libsmumps$(PLAT)$(SHAREDLIBEXT):
    113         @echo 'Error: you should build the library' $@ 'first'
    114         exit 1
    115  
    116 -$(libdir)/libdmumps$(PLAT)$(LIBEXT):
    117 +$(libdir)/libdmumps$(PLAT)$(SHAREDLIBEXT):
    118         @echo 'Error: you should build the library' $@ 'first'
    119         exit 1
    120  
    121 -$(libdir)/libcmumps$(PLAT)$(LIBEXT):
    122 +$(libdir)/libcmumps$(PLAT)$(SHAREDLIBEXT):
    123         @echo 'Error: you should build the library' $@ 'first'
    124         exit 1
    125  
    126 -$(libdir)/libzmumps$(PLAT)$(LIBEXT):
    127 +$(libdir)/libzmumps$(PLAT)$(SHAREDLIBEXT):
    128         @echo 'Error: you should build the library' $@ 'first'
    129         exit 1
    130  
    131  $(LIBMUMPS_COMMON):
    132         @echo 'Error: you should build the library' $@ 'first'
    13364diff --git a/src/Makefile b/src/Makefile
    13465--- a/src/Makefile
Note: See TracChangeset for help on using the changeset viewer.