Changeset 150509 for trunk/dports/math


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

superlu: update to 5.2.1 which supports cmake

File:
1 edited

Legend:

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

    r146234 r150509  
    33
    44PortSystem          1.0
     5PortGroup           cmake 1.0
    56
    67name                superlu
    7 version             5.1.1
     8version             5.2.1
    89categories          math
    910license             BSD
     
    1819master_sites        ${homepage}
    1920
    20 checksums           rmd160  16c0d070032392fe9f6477920a2c585dacfeb984 \
    21                     sha256  cec5022c8dc16e38e5c8bc92ed196144fe58864bd1c5ad73fb698398308f8065
     21checksums           rmd160  2aae43b29da1301e70625d79d41453e5d5ed04e2 \
     22                    sha256  28fb66d6107ee66248d5cf508c79de03d0621852a0ddeba7301801d3d859f463
    2223
    2324distname            ${name}_${version}
    2425worksrcdir          SuperLU_${version}
    2526
    26 use_configure       no
    27 use_parallel_build  no
     27configure.cflags    -Os -mtune=native
    2828
    29 configure.cflags    -fPIC -Wall -Wwrite-strings -Wno-strict-aliasing -O3 -mtune=native
    30 
    31 build.target        lib
    32 build.args          LAAUX="" SLASRC="" DLASRC="" CLASRC="" ZLASRC="" SCLAUX="" DZLAUX=""
    33 
    34 post-extract {
    35     reinplace "s|^SuperLUroot.*$|SuperLUroot = ${worksrcpath}|" ${worksrcpath}/make.inc
    36     reinplace "s|^SUPERLULIB.*$|SUPERLULIB = \$(SuperLUroot)/lib/libsuperlu_${version}.a|" ${worksrcpath}/make.inc
    37     reinplace "s|^BLASLIB.*$|BLASLIB = -framework Accelerate|" ${worksrcpath}/make.inc
    38     reinplace "s|^CC.*$|CC = ${configure.cc}|" ${worksrcpath}/make.inc
    39     reinplace "s|^LOADER.*$|LOADER = ${configure.cc}|" ${worksrcpath}/make.inc
    40     reinplace "s|^CFLAGS.*$|CFLAGS = ${configure.cflags}|" ${worksrcpath}/make.inc
    41     reinplace "s|^MATLAB.*$||" ${worksrcpath}/make.inc
    42     reinplace "s|^PLAT.*$||" ${worksrcpath}/make.inc
    43     reinplace "s|^RANLIB.*$|RANLIB = ranlib -c|" ${worksrcpath}/make.inc
    44     reinplace "s|^TMGLIB.*$|TMGLIB = tmglib.a|" ${worksrcpath}/make.inc
    45 
    46     # Prefixing a namespace so that colamd doesn't conflict with itself (used in
    47     # other packages
    48     reinplace "s|^#include \"colamd\.h\"|#include \"slu_colamd\.h\"|" ${worksrcpath}/SRC/colamd.c
    49     reinplace "s|^#include \"colamd\.h\"|#include \"slu_colamd\.h\"|" ${worksrcpath}/SRC/get_perm_c.c
    50     move ${worksrcpath}/SRC/colamd.h ${worksrcpath}/SRC/slu_colamd.h
     29post-patch {
     30    reinplace "s|^enable_language.*Fortran.*||" ${worksrcpath}/CMakeLists.txt
     31    reinplace "s|^set(NOFORTRAN FALSE)$|set(NOFORTRAN TRUE)|" ${worksrcpath}/CMakeLists.txt
    5132}
    5233
    53 destroot {
    54     # make shared libraries
    55     system -W ${worksrcpath}/SRC "${configure.cc} *.o -framework Accelerate -dynamiclib -Wl,-headerpad_max_install_names,-multiply_defined,suppress,-commons,use_dylibs,-search_paths_first -install_name ${prefix}/lib/lib${distname}.dylib -o lib${distname}.dylib"
    56 
    57     xinstall -W ${worksrcpath}/SRC -m 644 slu_colamd.h slu_Cnames.h slu_dcomplex.h slu_scomplex.h superlu_enum_consts.h \
    58         slu_util.h supermatrix.h html_mainpage.h slu_cdefs.h slu_ddefs.h slu_sdefs.h slu_zdefs.h \
    59         ${destroot}${prefix}/include
    60     xinstall -m 644 ${worksrcpath}/SRC/libsuperlu_${version}.dylib ${destroot}${prefix}/lib
    61     ln -s ${prefix}/lib/lib${distname}.dylib ${destroot}${prefix}/lib/libsuperlu.dylib
    62 }
     34configure.args-append \
     35                    -DTPL_BLAS_LIBRARIES="-framework Accelerate" \
     36                    -Denable_tests=OFF \
     37                    -DUSE_XSDK_DEFAULTS=ON \
     38                    -DXSDK_ENABLE_Fortran=OFF
    6339
    6440livecheck.type      none
Note: See TracChangeset for help on using the changeset viewer.