source: trunk/dports/math/arpack/Portfile

Last change on this file was 148850, checked in by dstrubbe@…, 14 months ago

arpack: Use new linear_algebra port group.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.3 KB
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id: Portfile 148850 2016-05-20 01:10:56Z ryandesign@macports.org $
3
4PortSystem          1.0
5PortGroup           muniversal 1.0
6PortGroup           mpi 1.0
7PortGroup           github 1.0
8PortGroup           linear_algebra 1.0
9
10github.setup        opencollab arpack-ng 3.3.0
11name                arpack
12revision            3
13categories          math
14license             BSD
15platforms           darwin
16maintainers         openmaintainer mmoll
17description         Package for solving large-scale eigenvalue problems
18long_description    ARPACK is a collection of Fortran77 subroutines designed to \
19                    solve large scale eigenvalue problems. Parallel ARPACK (PARPACK) \
20                    is included if built with an MPI variant.
21worksrcdir          ${name}-ng-${version}
22
23checksums           rmd160  76f87a65f9c6e6a2a8d5e31acc2e404fd755b473 \
24                    sha256  2d3d0d802fb60a26502c7cace31ef0066ede2b00c193fb2bca437ee54185b617
25
26mpi.setup           require_fortran
27
28use_autoreconf      yes
29configure.args      home=${worksrcpath} --disable-mpi
30
31if {![variant_isset universal]} {
32    if {${build_arch} eq "x86_64" || ${build_arch} eq "ppc64"} {
33        configure.fflags-append -m64
34    } else {
35        configure.fflags-append -m32
36    }
37}
38
39# LDFLAGS needs to be cleared to avoid it having a "-arch" option, considered illegal by gfortran
40# also, if it has ${prefix}/lib it will prevent +accelerate from working if atlas is present.
41configure.args-append LDFLAGS=''
42
43pre-configure {
44    configure.args-append --with-blas="-L${prefix}/lib ${linalglib}"
45
46    if {${os.platform} eq "darwin" && ${os.major} < 9} {
47        ui_error "${name} ${version} requires Mac OS X 10.5 or greater"
48        return -code error "incompatible Mac OS X version"
49    }
50
51    if {[mpi_variant_isset]} {
52        configure.args-delete  --disable-mpi
53        configure.args-append  --enable-mpi
54        configure.args-append  F77=${mpi.f77} \
55                               MPIF77=${mpi.f77}
56    }
57}
58
59# Fortran compilers can not cross-compile
60if {${os.arch} eq "i386"} {
61    set universal_archs_supported "i386 x86_64"
62} else {
63    set universal_archs_supported "ppc ppc64"
64}
65
66post-destroot {
67    reinplace "s|/usr|${prefix}|g" ${destroot}${prefix}/lib/pkgconfig/arpack.pc
68}
69
70test.run    yes
71test.target check
Note: See TracBrowser for help on using the repository browser.