1 | # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:et:sw=4:ts=4:sts=4 |
---|
2 | # $Id: Portfile 95166 2012-07-06 10:02:04Z and.damore@macports.org $ |
---|
3 | |
---|
4 | PortSystem 1.0 |
---|
5 | |
---|
6 | name octave |
---|
7 | version 3.2.4 |
---|
8 | revision 8 |
---|
9 | conflicts octave-devel |
---|
10 | categories math science |
---|
11 | license GPL-3+ |
---|
12 | maintainers nomaintainer |
---|
13 | platforms darwin |
---|
14 | description a Matlab-like environment for numerical analysis |
---|
15 | long_description Octave provides a convenient command line interface \ |
---|
16 | for solving linear and nonlinear problems numerically, \ |
---|
17 | using a language that is mostly compatible with Matlab. \ |
---|
18 | It is easily extensible and customizable via \ |
---|
19 | user-defined functions or using dynamically loaded \ |
---|
20 | modules written in e.g. C++, C or Fortran. |
---|
21 | |
---|
22 | homepage http://www.gnu.org/software/octave/ |
---|
23 | master_sites gnu |
---|
24 | |
---|
25 | checksums md5 90c39fa9e241ad2e978bcee4682a2ba9 \ |
---|
26 | sha1 93b81fc300bc5e27e88b6668ef0622f29898dfd2 \ |
---|
27 | rmd160 13b2198db1b8684229d2ba787ebbedd8e50a518c |
---|
28 | |
---|
29 | depends_build port:gawk \ |
---|
30 | path:bin/perl:perl5 \ |
---|
31 | port:texinfo |
---|
32 | |
---|
33 | depends_lib port:arpack \ |
---|
34 | port:curl \ |
---|
35 | port:fftw-3 \ |
---|
36 | port:fftw-3-single \ |
---|
37 | port:ftgl \ |
---|
38 | port:ghostscript \ |
---|
39 | port:glpk \ |
---|
40 | port:GraphicsMagick \ |
---|
41 | port:gnuplot \ |
---|
42 | port:hdf5-18 \ |
---|
43 | port:metis \ |
---|
44 | port:ncurses \ |
---|
45 | port:pcre \ |
---|
46 | port:readline \ |
---|
47 | port:qhull \ |
---|
48 | port:qrupdate \ |
---|
49 | port:SuiteSparse \ |
---|
50 | port:gsed |
---|
51 | |
---|
52 | configure.args --enable-shared \ |
---|
53 | --enable-dl \ |
---|
54 | --with-hdf5 \ |
---|
55 | --with-fftw \ |
---|
56 | --enable-static \ |
---|
57 | --enable-readline \ |
---|
58 | --with-zlib \ |
---|
59 | --with-glpk \ |
---|
60 | --with-curl \ |
---|
61 | --with-lapack \ |
---|
62 | --with-umfpack \ |
---|
63 | --with-colamd \ |
---|
64 | --with-ccolamd \ |
---|
65 | --with-cholmod \ |
---|
66 | --with-cxsparse \ |
---|
67 | --without-framework-carbon |
---|
68 | |
---|
69 | configure.perl ${prefix}/bin/perl |
---|
70 | configure.python ' ' |
---|
71 | configure.awk ${prefix}/bin/gawk |
---|
72 | |
---|
73 | configure.env-append SED="${prefix}/bin/gsed" \ |
---|
74 | MAKEINFO="${prefix}/bin/makeinfo" \ |
---|
75 | TEXI2DVI="${prefix}/bin/texi2dvi" \ |
---|
76 | TEXI2PDF="${prefix}/bin/texi2pdf" |
---|
77 | |
---|
78 | post-configure { |
---|
79 | reinplace "s|UMFPACK_LIBS = -lumfpack|UMFPACK_LIBS = -lSuiteSparse -lumfpack|" ${worksrcpath}/Makeconf |
---|
80 | } |
---|
81 | |
---|
82 | use_parallel_build no |
---|
83 | universal_variant no |
---|
84 | |
---|
85 | test.run yes |
---|
86 | test.target check |
---|
87 | |
---|
88 | variant atlas conflicts accelerate description {use BLAS from ATLAS} { |
---|
89 | depends_lib-append port:atlas |
---|
90 | } |
---|
91 | variant accelerate conflicts atlas description {use BLAS from Accelerate.framework} { |
---|
92 | if {![variant_isset g95]} { |
---|
93 | configure.fflags-append -ff2c |
---|
94 | } |
---|
95 | if {[variant_isset g95] || ([string match *64* $build_arch] && ${os.major} >= 10)} { |
---|
96 | depends_lib-append port:dotwrp |
---|
97 | configure.args-append --with-blas="-ldotwrp -framework Accelerate" |
---|
98 | } |
---|
99 | configure.args-append --with-lapack="-framework Accelerate" |
---|
100 | } |
---|
101 | if {[variant_isset g95]} { |
---|
102 | default_variants +accelerate |
---|
103 | } elseif {![variant_isset accelerate]} { |
---|
104 | default_variants +atlas |
---|
105 | } |
---|
106 | if {![variant_isset atlas] && ![variant_isset accelerate]} { |
---|
107 | pre-fetch { |
---|
108 | return -code error "You must use either the atlas or accelerate variant." |
---|
109 | } |
---|
110 | } |
---|
111 | |
---|
112 | variant gcc43 description {build with the macports gcc43 toolchain} conflicts gcc44 gcc45 g95 { |
---|
113 | depends_build-append port:gcc43 |
---|
114 | configure.compiler macports-gcc-4.3 |
---|
115 | } |
---|
116 | |
---|
117 | variant gcc44 description {build with the macports gcc44 toolchain} conflicts gcc43 gcc45 g95 { |
---|
118 | depends_build-append port:gcc44 |
---|
119 | configure.compiler macports-gcc-4.4 |
---|
120 | } |
---|
121 | |
---|
122 | variant gcc45 description {build with the macports gcc45 toolchain} conflicts gcc43 gcc44 g95 { |
---|
123 | depends_build-append port:gcc45 |
---|
124 | configure.compiler macports-gcc-4.5 |
---|
125 | } |
---|
126 | |
---|
127 | variant g95 description {build with g95} requires accelerate conflicts atlas gcc43 gcc44 gcc45 { |
---|
128 | depends_build-append port:g95 |
---|
129 | configure.f77 "${prefix}/bin/g95" |
---|
130 | } |
---|
131 | |
---|
132 | if { ![variant_isset gcc43] && ![variant_isset gcc44] && ![variant_isset g95] } { |
---|
133 | default_variants +gcc45 |
---|
134 | } |
---|
135 | if {![variant_isset gcc43] && ![variant_isset gcc44] && ![variant_isset gcc45] && ![variant_isset g95]} { |
---|
136 | pre-fetch { |
---|
137 | return -code error "You must use one of the compiler variants." |
---|
138 | } |
---|
139 | } |
---|
140 | |
---|
141 | patchfiles patch-lo-specfun.cc.diff \ |
---|
142 | patch-configure-no_x11.diff \ |
---|
143 | patch-src-DLD-FUNCTIONS-urlwrite.cc.diff |
---|
144 | |
---|
145 | post-patch { |
---|
146 | reinplace "s|-lcholmod|-lcholmod -lmetis|g" ${worksrcpath}/configure |
---|
147 | } |
---|
148 | |
---|
149 | livecheck.type regex |
---|
150 | livecheck.url http://www.gnu.org/software/octave/news.html |
---|
151 | livecheck.regex Version (\\d+(\\.\\d+)*) |
---|