Changeset 150510 for trunk/dports/math


Ignore:
Timestamp:
Jul 20, 2016, 8:37:59 PM (3 years ago)
Author:
sean@…
Message:

superlu_dist: update to 5.1.0 which supports cmake

Location:
trunk/dports/math/superlu_dist
Files:
1 deleted
1 edited

Legend:

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

    r146235 r150510  
    33
    44PortSystem          1.0
     5PortGroup           cmake 1.0
    56PortGroup           mpi 1.0
    67
    78name                superlu_dist
    8 version             4.3
    9 revision            1
     9version             5.1.0
    1010categories          math
    1111license             BSD
     
    2323worksrcdir          SuperLU_DIST_${version}
    2424
    25 checksums           rmd160  7fd929f6a30b3c121af9894846df17f8b366fff0 \
    26                     sha256  daffdb64386c7d970d7f591d0be3cd3441e60bc3453365b0badfd364d2452db2
     25checksums           rmd160  148bf92ee5bfa7fec8501b61d56ce32bc83b4376 \
     26                    sha256  30ac554a992441e6041c6fb07772da4fa2fa6b30714279de03573c2cad6e4b60
    2727
    2828compilers.choose    cc cxx
    2929mpi.setup           require
    3030
    31 depends_lib         port:parmetis
     31depends_lib         port:parmetis \
     32                    port:superlu
    3233
    33 patchfiles-append   patch-remove-duplicate-symbols.diff
     34configure.cflags    -Os -mtune=native
    3435
    35 use_configure       no
    36 
    37 configure.cflags    -fPIC -Wall -Wwrite-strings -Wno-strict-aliasing -O3 -mtune=native
    38 configure.cxxflags  ${configure.cflags}
    39 
    40 build.target        lib
    41 build.args          LAAUX="smach.o dmach.o"
    42 
    43 post-extract {
    44     reinplace "s|^DSuperLUroot.*$|DSuperLUroot = ${worksrcpath}|" ${worksrcpath}/make.inc
    45     reinplace "s|^ PARMETIS_DIR.*$|PARMETIS_DIR = ${prefix}|" ${worksrcpath}/make.inc
    46     reinplace "s|^PARMETISLIB.*$|PARMETISLIB = -L${prefix}/lib -lparmetis|" ${worksrcpath}/make.inc
    47     reinplace "s|^METISLIB.*$|METISLIB = -L${prefix}/lib -lmetis|" ${worksrcpath}/make.inc
    48     reinplace "s|^IMPI.*$||" ${worksrcpath}/make.inc
    49     reinplace "s|^CC.*$|CC = ${mpi.cc}|" ${worksrcpath}/make.inc
    50     reinplace "s|^CFLAGS.*$|CFLAGS = ${configure.cflags} \\\\|" ${worksrcpath}/make.inc
    51     reinplace "s|^BLASLIB.*$|BLASLIB = -framework Accelerate -framework vecLib|" ${worksrcpath}/make.inc
    52     reinplace "s|supermatrix\.h|supermatrix_dist\.h|" ${worksrcpath}/SRC/superlu_defs.h
    53     file rename ${worksrcpath}/SRC/supermatrix.h ${worksrcpath}/SRC/supermatrix_dist.h
     36post-patch {
     37    reinplace "s|^enable_language.*Fortran.*||" ${worksrcpath}/CMakeLists.txt
     38    reinplace "s|^set(NOFORTRAN FALSE)$|set(NOFORTRAN TRUE)|" ${worksrcpath}/CMakeLists.txt
    5439}
    5540
    56 post-build {
    57     # make shared libraries
    58     system -W ${worksrcpath}/SRC "${mpi.cc} *.o -framework Accelerate -L${prefix}/lib -lparmetis -lmetis -dynamiclib -all_load -Wl,-headerpad_max_install_names,-multiply_defined,suppress,-commons,use_dylibs,-search_paths_first -install_name ${prefix}/lib/lib${distname}.dylib -o ../lib/lib${distname}.dylib"
    59 }
     41configure.args-append \
     42                    -DTPL_BLAS_LIBRARIES="-framework Accelerate" \
     43                    -DTPL_PARMETIS_INCLUDE_DIRS=${prefix}/include \
     44                    -DTPL_PARMETIS_LIBRARIES="${prefix}/lib/libparmetis.dylib\;${prefix}/lib/libmetis.dylib" \
     45                    -Denable_tests=OFF \
     46                    -DUSE_XSDK_DEFAULTS=ON \
     47                    -DXSDK_ENABLE_Fortran=OFF
    6048
    61 destroot {
    62     xinstall -W ${worksrcpath}/SRC -m 644 Cnames.h dcomplex.h machines.h old_colamd.h \
    63         psymbfact.h superlu_ddefs.h superlu_defs.h superlu_zdefs.h util_dist.h supermatrix_dist.h \
    64         ${destroot}${prefix}/include
    65     xinstall -m 644 ${worksrcpath}/lib/libsuperlu_dist_${version}.dylib ${destroot}${prefix}/lib
    66     ln -s ${prefix}/lib/lib${distname}.dylib ${destroot}${prefix}/lib/libsuperlu_dist.dylib
    67 }
     49post-destroot {
     50    # these are the same files as installed by superlu, so we'll just depend on
     51    # superlu for now
     52    delete ${destroot}${prefix}/include/superlu_enum_consts.h
     53    delete ${destroot}${prefix}/include/supermatrix.h
     54}   
    6855
    6956variant longindex description {Build with 64 ints} {
    70     configure.cflags-append     -D_LONGINT
     57    configure.cflags-append     -DXSDK_INDEX_SIZE=64
    7158}
    7259
Note: See TracChangeset for help on using the changeset viewer.