Ticket #28154: Portfile_2011_01_25_2312

File Portfile_2011_01_25_2312, 6.6 KB (added by lukas.reichlin@…, 14 years ago)

octave-devel @3.3.90_1

Line 
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 75431 2011-01-25 01:44:31Z michaelld@macports.org $
3
4PortSystem 1.0
5
6name                octave-devel
7version             3.3.90
8revision            1
9conflicts           octave
10categories          math science
11maintainers         michaelld openmaintainer
12platforms           darwin
13description         a Matlab-like environment for numerical analysis
14long_description    Octave provides a convenient command line interface \
15                    for solving linear and nonlinear problems numerically, \
16                    using a language that is mostly compatible with Matlab. \
17                    It is easily extensible and customizable via \
18                    user-defined functions or using dynamically loaded \
19                    modules written in e.g. C++, C or Fortran.
20
21homepage            http://www.gnu.org/software/octave/
22master_sites        ftp://alpha.gnu.org/gnu/octave
23distname            octave-${version}
24use_bzip2           yes
25
26checksums           md5     36e915de4b24fd5d988a5885d82cc795 \
27                    sha1    bb7b40703aae04854aa367d3eec42d7019649d75 \
28                    rmd160  e59b482f062042aa658ec1107537c03f704222f5
29
30depends_build       port:bison \
31                    port:flex \
32                    port:gawk \
33                    port:gperf \
34                    port:gsed \
35                    path:bin/perl:perl5 \
36                    port:texinfo
37
38depends_lib         port:arpack \
39                    port:atlas \
40                    port:curl \
41                    port:fftw-3 \
42                    port:fftw-3-single \
43                    port:ftgl \
44                    port:ghostscript \
45                    port:glpk \
46                    port:GraphicsMagick \
47                    port:gnuplot \
48                    port:hdf5-18 \
49                    port:less \
50                    port:metis \
51                    port:ncurses \
52                    port:pcre \
53                    port:readline \
54                    port:qhull \
55                    port:qrupdate \
56                    port:SuiteSparse
57
58# allow non-Apple compilers to work with FLTK by removing the -arch
59# flag, which means this port cannot easy compile as universal.
60patchfiles-append patch-configure.diff
61
62#platform darwin 10 {
63#    # for 10.6 only
64#    patchfiles-append patch-lo-specfun.cc.diff
65#}
66
67universal_variant   no
68
69configure.args      --without-x \
70                    --enable-shared \
71                    --enable-dl \
72                    --disable-docs \
73                    --disable-openmp
74
75# do not build static libraries; just shared
76#                    --enable-static
77
78### the following are probably not necessary (except possibly the
79### 'cholmod' one), but are included for completion.  Ordering is the
80### same as in './configure --help'.
81configure.args-append \
82                    --enable-readline \
83                    --enable-extra-warning-flags \
84                    --with-qhull \
85                    --with-z \
86                    --with-hdf5 \
87                    --with-fftw3 \
88                    --with-fftw3f \
89                    --with-glpk \
90                    --with-curl \
91                    --with-blas \
92                    --with-lapack \
93                    --with-qrupdate \
94                    --with-amd \
95                    --with-camd \
96                    --with-colamd \
97                    --with-ccolamd \
98                    --with-cholmod="-lcholmod -lmetis" \
99                    --with-cxsparse \
100                    --with-umfpack \
101                    --with-arpack
102
103### the following are probably not necessary, but are included for
104### completion.
105# octave uses a number of other ports to create sources from template:
106# perl, gawk, gsed, flex, bison, texinfo.  python is not used if perl
107# is available, so clear it out.  FLTK doesn't work as of 1.3.x-r7794,
108# so disable it entirely (via "no" here and a configure patch).
109configure.perl      ${prefix}/bin/perl
110configure.python    ' '
111configure.awk       ${prefix}/bin/gawk
112configure.env-append SED="${prefix}/bin/gsed" \
113                     TEXI2DVI="${prefix}/bin/texi2dvi" \
114                     TEXI2PDF="${prefix}/bin/texi2pdf" \
115                     FLTK_CONFIG=no
116
117### parallel build is supposed to work now
118# use_parallel_build  no
119
120test.run            yes
121test.target         check
122
123variant gcc43 description {build with the macports gcc43 toolchain} conflicts gcc45 gcc44 g95 {
124    depends_build-append    port:gcc43
125    configure.compiler      macports-gcc-4.3
126}
127
128variant gcc44 description {build with the macports gcc44 toolchain} conflicts gcc45 gcc43 g95 {
129    configure.env-append    LDFLAGS="${prefix}/lib/gcc44/libstdc++.6.dylib"
130    depends_build-append    port:gcc44
131    configure.compiler      macports-gcc-4.4
132}
133
134variant gcc45 description {build with the macports gcc45 toolchain} conflicts gcc44 gcc43 g95 {
135    configure.env-append    LDFLAGS="${prefix}/lib/gcc45/libstdc++.6.dylib"
136    depends_build-append    port:gcc45
137    configure.compiler      macports-gcc-4.5
138}
139
140variant g95 description {build with g95} conflicts gcc43 gcc44 gcc45 {
141    depends_build-append    port:g95
142    configure.f77           "${prefix}/bin/g95"
143}
144
145if { ![variant_isset gcc43] && ![variant_isset gcc44] && \
146         ![variant_isset gcc45] && ![variant_isset g95] } {
147    default_variants +gcc44
148}
149
150variant docs description {Enable creation and installation of documentation} {
151    configure.args-replace s|--disable-docs|--enable-docs|
152}
153
154variant x11 description {Enable use of X11} {
155    configure.args-replace s|--without-x|--with-x|
156    configure.args-append --x-includes=${prefix}
157}
158
159variant debug description {Produce debugging information in compiled code} {
160    configure.cflags-delete    -O2
161    configure.cxxflags-delete  -O2
162    configure.fflags-delete    -O2
163    configure.fcflags-delete   -O2
164    configure.f90flags-delete  -O2
165    configure.objcflags-delete -O2
166    configure.cflags-append    -g3 -O0
167    configure.cxxflags-append  -g3 -O0
168    configure.fcflags-append   -g3 -O0
169    configure.f90flags-append  -g3 -O0
170    configure.fflags-append    -g3 -O0
171    configure.objcflags-append -g3 -O0
172}
173
174#variant fltk description {Include FLTK option} {
175#    depends_lib-append port:fltk-devel
176#    post-patch
177        # fix use of #include Fl -> FL
178#        reinplace "/include/s,Fl/,FL/,g"
179#            ${worksrcpath}/src/DLD-FUNCTIONS/fltk_backend.cc
180#    }
181#}
182
183#if {![variant_isset fltk]} {
184#    configure.env-append FLTK_CONFIG=no
185#}
186
187livecheck.type      regex
188livecheck.url       http://www.gnu.org/software/octave/news.html
189livecheck.regex     Version (\\d+(\\.\\d+)*)