Changeset 143305


Ignore:
Timestamp:
Dec 10, 2015, 3:21:32 AM (4 years ago)
Author:
dstrubbe@…
Message:

itsol: Use vecLibFort for Accelerate, which should resolve the concerns about its bugginess. I don't see any problem for g95, since atlas does not need to be installed with the same Fortran compiler as used here; all tests passed regardless. Use more condensed link line for atlas.

File:
1 edited

Legend:

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

    r143304 r143305  
    4343compilers.setup     require_fortran
    4444
    45 # atlas does not provide a +g95 variant, so if +g95 is used,
    46 # +accelerate must also be used.  +accelerate will work with +gccXY,
    47 # so this is all a bit complex to check for.  Setting 'requires' here
    48 # does not yet seem to work with 'port' to get [+]accelerate; leaving
    49 # it out does work, so doing that and checking for this condition
    50 # later, for now.
    51 
    52 ######################
    53 # set up BLAS variants
    54 
    55 # atlas does not work with g95, so always conflict with it
    56 
    5745variant atlas description {use BLAS from MacPorts' atlas port} \
    58     conflicts g95 accelerate {}
    59 
    60 # accelerate works with any fortran variant
     46    conflicts accelerate {}
    6147
    6248variant accelerate description \
    63     {use BLAS from Apple's Accelerate.framework [might be buggy]} \
     49    {use BLAS from Apple's Accelerate.framework} \
    6450    conflicts atlas {}
    6551
    66 ##################
    67 # variant checking
    68 
    69 # check for BLAS default variant, use +atlas if nothing else
    70 
    7152set blas_variant_selection ""
    72 if {[variant_isset g95] || [variant_isset accelerate]} {
     53if {[variant_isset accelerate]} {
    7354    set blas_variant_selection "accelerate"
    7455} else {
     
    9071if {[variant_isset accelerate]} {
    9172
    92     configure.ldflags-append -Wl,-framework -Wl,Accelerate
     73    depends_lib-append        vecLibFort
     74    configure.ldflags-append  -lvecLibFort
    9375
    9476} else {
    9577
    9678    depends_lib-append       port:atlas
    97     configure.ldflags-append -llapack -lcblas -lf77blas -latlas
     79    configure.ldflags-append -lsatlas
    9880
    9981}
     
    10991destroot.env-append  PREFIX=${prefix}
    11092
    111 pre-fetch {
    112 
    113     # check for +accelerate.  Apple's VecLib has bugs that can cause
    114     # crashes, while Atlas does not have these issues.  Print a
    115     # warning if this variant is in use, but do not force the use of
    116     # +atlas (for now).
    117 
    118     if {[variant_isset accelerate]} {
    119         ui_msg "\nWARNING: The +accelerate variant has been selected, using Apple's Vector Libraries which have known bugs that can cause crashes.  The +atlas variant does not have these issues, and is generally considered a better way to go.\n"
    120     }
    121 }
    122 
    12393test.run       yes
    12494pre-test {
Note: See TracChangeset for help on using the changeset viewer.