Ticket #39365: Portfile-arpack.diff

File Portfile-arpack.diff, 3.0 KB (added by dstrubbe (David Strubbe), 11 years ago)
  • Portfile

    old new  
    22
    33PortSystem 1.0
    44PortGroup  muniversal 1.0
     5PortGroup  active_variants 1.1
    56
    67name          arpack
    78version       3.1.2
     
    6768variant gcc43 description {build with gfortran-mp-4.3} conflicts gcc44 gcc45 gcc46 gcc47 g95 universal {
    6869        depends_build-append    port:gcc43
    6970        configure.env-append F77=${prefix}/bin/gfortran-mp-4.3
     71        if {[variant_isset mpich]}   { require_active_variants mpich   gcc43 }
     72        if {[variant_isset openmpi]} { require_active_variants openmpi gcc43 }
    7073}
    7174
    7275variant gcc44 description {build with gfortran-mp-4.4} conflicts gcc43 gcc45 gcc46 gcc47 g95 {
    7376        depends_build-append    port:gcc44
    7477        configure.env-append F77=${prefix}/bin/gfortran-mp-4.4
     78        if {[variant_isset mpich]}   { require_active_variants mpich   gcc44 }
     79        if {[variant_isset openmpi]} { require_active_variants openmpi gcc44 }
    7580}
    7681
    7782variant gcc45 description {build with gfortran-mp-4.5} conflicts gcc43 gcc44 gcc46 gcc47 g95 {
    7883        depends_build-append    port:gcc45
    7984        configure.env-append F77=${prefix}/bin/gfortran-mp-4.5
     85        if {[variant_isset mpich]}   { require_active_variants mpich   gcc45 }
     86        if {[variant_isset openmpi]} { require_active_variants openmpi gcc45 }
    8087}
    8188
    8289variant gcc46 description {build with gfortran-mp-4.6} conflicts gcc43 gcc44 gcc45 gcc47 g95 {
    8390        depends_build-append    port:gcc46
    8491        configure.env-append F77=${prefix}/bin/gfortran-mp-4.6
     92        if {[variant_isset mpich]}   { require_active_variants mpich   gcc46 }
     93        if {[variant_isset openmpi]} { require_active_variants openmpi gcc46 }
    8594}
    8695
    8796variant gcc47 description {build with gfortran-mp-4.7} conflicts gcc43 gcc44 gcc45 gcc46 g95 {
    8897        depends_build-append    port:gcc47
    8998        configure.env-append F77=${prefix}/bin/gfortran-mp-4.7
     99        if {[variant_isset mpich]}   { require_active_variants mpich   gcc47 }
     100        if {[variant_isset openmpi]} { require_active_variants openmpi gcc47 }
    90101}
    91102variant g95 description {build with g95} conflicts gcc43 gcc44 gcc45 gcc46 gcc47 universal {
    92103        depends_build-append    port:g95
    93104        configure.env-append F77=${prefix}/bin/g95
     105        if {[variant_isset mpich]}   { require_active_variants mpich   g95 }
     106        if {[variant_isset openmpi]} { require_active_variants openmpi g95 }
    94107}
    95108
    96109if { ![variant_isset gcc43] && ![variant_isset gcc44] && ![variant_isset gcc45] && ![variant_isset gcc46] && ![variant_isset g95] } {
     
    117130post-destroot {
    118131    delete ${destroot}${prefix}/bin/dnsimp
    119132    reinplace "s|/usr|${prefix}|g" ${destroot}${prefix}/lib/pkgconfig/arpack.pc
     133
     134    if {[variant_isset openmpi] || [variant_isset mpich]} {
     135       delete ${destroot}${prefix}/bin/pcndrv1
     136       delete ${destroot}${prefix}/bin/pdndrv1
     137       delete ${destroot}${prefix}/bin/pdndrv3
     138       delete ${destroot}${prefix}/bin/pdsdrv1
     139       delete ${destroot}${prefix}/bin/psndrv3
     140       delete ${destroot}${prefix}/bin/pssdrv1
     141       delete ${destroot}${prefix}/bin/pzndrv1
     142    }
    120143}
    121144
    122145livecheck.type  regex