source: trunk/dports/math/blitz-devel/Portfile @ 143117

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

blitz-devel: update to hg default branch as of 20151126, set default variant to +gcc49, gcc48 doesn't build on El Capitan.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.8 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 143117 2015-12-04 14:59:51Z devans@macports.org $
3
4PortSystem          1.0
5
6name                blitz-devel
7version             0.10-20151126
8categories          math devel
9platforms           darwin
10license             {LGPL-3+ BSD Artistic-2}
11maintainers         nomaintainer
12
13fetch.type          hg
14hg.url              http://blitz.hg.sourceforge.net:8000/hgroot/blitz/blitz
15hg.tag              8749c555825c
16
17description         a C++ class library for scientific computing
18
19long_description    Blitz++ is a (LGPLv3+) licensed meta-template library for \
20                    array manipulation in C++ with a speed comparable to \
21                    Fortran implementations, while preserving an \
22                    object-oriented interface. These results are being \
23                    obtained not through better optimizing compilers, \
24                    preprocessors, or language extensions, but through the \
25                    use of template techniques. By using templates cleverly, \
26                    optimizations such as loop fusion, unrolling, tiling, \
27                    and algorithm specialization can be performed \
28                    automatically at compile time.
29
30homepage            http://blitz.sourceforge.net/
31
32platforms           darwin
33
34use_autoreconf yes
35
36configure.args      --infodir=${prefix}/share/info \
37                    --enable-shared \
38                    --enable-static \
39                    --enable-optimize \
40                    --disable-doxygen \
41                    --disable-dot \
42                    --disable-latex-docs
43
44destroot.args       docdir=${prefix}/share/doc/${name}
45
46variant docs description {Generate API documentation} {
47  depends_lib-append     port:doxygen \
48                         path:bin/dot:graphviz
49  configure.args-delete --disable-doxygen \
50                        --disable-dot
51  configure.args-append --enable-doxygen \
52                        --enable-dot
53}
54
55set gcc_versions {4.3 4.4 4.5 4.6 4.7 4.8 4.9}
56set default_fortran_variant +gcc49
57set g95_conflicts {}
58
59foreach ver ${gcc_versions} {
60    set ver_no_dot [join [split ${ver} "."] ""]
61
62    set variant_line {variant gcc${ver_no_dot} description "build with gfortran from gcc${ver_no_dot}" conflicts g95}
63
64    foreach over ${gcc_versions} {
65        if {${ver} == ${over}} {
66            continue
67        }
68
69        set over_no_dot [join [split ${over} "."] ""]
70        append variant_line " conflicts gcc${over_no_dot}"
71    }
72    append variant_line { {}}
73
74    eval $variant_line
75
76    append g95_conflicts " conflicts gcc${ver_no_dot}"
77
78    if {[variant_isset gcc${ver_no_dot}]} {
79        if {${default_fortran_variant} != "+gcc${ver_no_dot}"} {
80            set default_fortran_variant ""
81        }
82    }
83}
84
85eval [concat {variant g95 description {build with g95}} $g95_conflicts {{}}]
86
87if {[variant_isset g95]} {
88    if {${default_fortran_variant} != "+g95"} {
89        set default_fortran_variant ""
90    }
91}
92
93if {${default_fortran_variant} != ""} {
94    default_variants "${default_fortran_variant}"
95}
96
97foreach ver ${gcc_versions} {
98    set ver_no_dot [join [split ${ver} "."] ""]
99
100    if {[variant_isset gcc${ver_no_dot}]} {
101        depends_lib-append path:lib/libgcc/libgcc_s.1.dylib:libgcc
102        depends_build-append port:gcc${ver_no_dot}
103
104        configure.fc  ${prefix}/bin/gfortran-mp-${ver}
105        configure.f77 ${prefix}/bin/gfortran-mp-${ver}
106        configure.f90 ${prefix}/bin/gfortran-mp-${ver}
107    }
108}
109
110if {[variant_isset g95]} {
111    depends_lib-append path:lib/libgcc/libgcc_s.1.dylib:libgcc
112    depends_build-append port:g95
113
114    configure.fc ${prefix}/bin/g95
115    configure.f77 ${prefix}/bin/g95
116    configure.f90 ${prefix}/bin/g95
117}
118
119# does not do any live check
120livecheck.type sourceforge
Note: See TracBrowser for help on using the repository browser.