source: trunk/dports/math/blitz/Portfile @ 143116

Last change on this file since 143116 was 143116, checked in by devans@…, 4 years ago

blitz: set default variant to +gcc49, gcc48 doesn't build on El Capitan, increment revision (#48471).

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.1 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 143116 2015-12-04 14:58:25Z devans@macports.org $
3
4PortSystem          1.0
5PortGroup           muniversal 1.0
6
7name                blitz
8version             0.10
9revision            4
10categories          math devel
11license             {LGPL-3+ BSD Artistic-2}
12platforms           darwin
13maintainers         nomaintainer
14
15description         a C++ class library for scientific computing
16
17long_description    Blitz++ is ${description} which provides performance on \
18                    par with Fortran 77/90. It uses template techniques to \
19                    achieve high performance.
20
21homepage            http://web.archive.org/web/20110721185508/http://www.oonumerics.org/blitz/
22master_sites        sourceforge:project/blitz/blitz/Blitz%2B%2B%20${version}
23
24# 0.10 was stealth-updated 2012-07-03
25dist_subdir         ${name}/${version}_1
26
27checksums           rmd160  c48e8a01ebfb8ae907a8a2c2c8d345b1625b4ad5 \
28                    sha256  804ef0e6911d43642a2ea1894e47c6007e4c185c866a7d68bad1e4c8ac4e6f94
29
30configure.args      --enable-shared \
31                    --disable-doxygen \
32                    --disable-dot \
33                    --disable-fortran \
34                    --disable-latex-docs
35
36destroot.args       docdir=${prefix}/share/doc/${name}
37
38set gcc_versions {4.3 4.4 4.5 4.6 4.7 4.8 4.9}
39set default_fortran_variant +gcc49
40set g95_conflicts {}
41
42foreach ver ${gcc_versions} {
43    set ver_no_dot [join [split ${ver} "."] ""]
44
45    set variant_line {variant gcc${ver_no_dot} description "build with gfortran from gcc${ver_no_dot}" conflicts g95}
46
47    foreach over ${gcc_versions} {
48        if {${ver} == ${over}} {
49            continue
50        }
51
52        set over_no_dot [join [split ${over} "."] ""]
53        append variant_line " conflicts gcc${over_no_dot}"
54    }
55    append variant_line { {}}
56
57    eval $variant_line
58
59    append g95_conflicts " conflicts gcc${ver_no_dot}"
60
61    if {[variant_isset gcc${ver_no_dot}]} {
62        if {${default_fortran_variant} != "+gcc${ver_no_dot}"} {
63            set default_fortran_variant ""
64        }
65    }
66}
67
68eval [concat {variant g95 description {build with g95}} $g95_conflicts {{}}]
69
70if {[variant_isset g95]} {
71    if {${default_fortran_variant} != "+g95"} {
72        set default_fortran_variant ""
73    }
74}
75
76if {${default_fortran_variant} != ""} {
77    default_variants "${default_fortran_variant}"
78}
79
80foreach ver ${gcc_versions} {
81    set ver_no_dot [join [split ${ver} "."] ""]
82
83    if {[variant_isset gcc${ver_no_dot}]} {
84        depends_lib-append path:lib/libgcc/libgcc_s.1.dylib:libgcc
85        depends_build-append port:gcc${ver_no_dot}
86
87        configure.fc  ${prefix}/bin/gfortran-mp-${ver}
88        configure.f77 ${prefix}/bin/gfortran-mp-${ver}
89        configure.f90 ${prefix}/bin/gfortran-mp-${ver}
90    }
91}
92
93if {[variant_isset g95]} {
94    depends_lib-append path:lib/libgcc/libgcc_s.1.dylib:libgcc
95    depends_build-append port:g95
96
97    configure.fc ${prefix}/bin/g95
98    configure.f77 ${prefix}/bin/g95
99    configure.f90 ${prefix}/bin/g95
100}
101
102livecheck.regex     /${name}-(\[0-9.\]+)${extract.suffix}
Note: See TracBrowser for help on using the repository browser.