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$ |
---|
3 | |
---|
4 | PortSystem 1.0 |
---|
5 | PortGroup python 1.0 |
---|
6 | |
---|
7 | name py-scipy |
---|
8 | version 0.9.0 |
---|
9 | categories python |
---|
10 | platforms darwin |
---|
11 | license BSD |
---|
12 | maintainers ram openmaintainer |
---|
13 | description An opensource library of scientific tools for Python |
---|
14 | long_description ${description} |
---|
15 | |
---|
16 | homepage http://www.scipy.org/ |
---|
17 | master_sites sourceforge:project/scipy/scipy/${version}/ |
---|
18 | distname scipy-${version} |
---|
19 | |
---|
20 | checksums md5 ebfef6e8e82d15c875a4ee6a46d4e1cd \ |
---|
21 | sha1 a586b10d0613cd61dbfcfd42f3d2609062cd10b8 \ |
---|
22 | rmd160 2aef8c3413ba9c7731d078b27eef1e03419de606 |
---|
23 | |
---|
24 | python.versions 24 25 26 27 31 32 |
---|
25 | |
---|
26 | if {${subport} != ${name}} { |
---|
27 | |
---|
28 | depends_lib-append port:py${python.version}-numpy \ |
---|
29 | port:py${python.version}-nose \ |
---|
30 | port:SuiteSparse \ |
---|
31 | port:swig-python |
---|
32 | |
---|
33 | worksrcdir ${distname} |
---|
34 | |
---|
35 | build.env-append CCFLAGS="-I${prefix}/include -L${prefix}/lib" |
---|
36 | |
---|
37 | destroot.env-append CCFLAGS="-I${prefix}/include -L${prefix}/lib" |
---|
38 | |
---|
39 | patchfiles scipy_complex.patch |
---|
40 | post-patch { |
---|
41 | reinplace "s|include <\\(umfpack\.*.h\\)>|include <${prefix}/include/ufsparse/\\1>|g" ${worksrcpath}/scipy/sparse/linalg/dsolve/umfpack/umfpack.i |
---|
42 | } |
---|
43 | |
---|
44 | variant atlas description "Use MacPorts ATLAS libraries" { |
---|
45 | depends_lib-append port:atlas |
---|
46 | |
---|
47 | build.env-append ATLAS=${prefix}/lib \ |
---|
48 | LAPACK=${prefix}/lib \ |
---|
49 | BLAS=${prefix}/lib |
---|
50 | |
---|
51 | destroot.env-append ATLAS=${prefix}/lib \ |
---|
52 | LAPACK=${prefix}/lib \ |
---|
53 | BLAS=${prefix}/lib |
---|
54 | } |
---|
55 | |
---|
56 | variant gcc42 conflicts gcc43 gcc44 gcc45 description "Use gcc 4.2 tool chain for building" { |
---|
57 | configure.compiler macports-gcc-4.2 |
---|
58 | depends_lib-append port:gcc42 |
---|
59 | set fc_options "config_fc --fcompiler gnu95 --f77exec ${prefix}/bin/gfortran-mp-4.2 --f90exec ${prefix}/bin/gfortran-mp-4.2" |
---|
60 | set config_options "config --cc ${prefix}/bin/gcc-mp-4.2 --include-dirs ${prefix}/include --library-dirs ${prefix}/lib" |
---|
61 | build.cmd-append ${fc_options} ${config_options} |
---|
62 | destroot.cmd-append ${fc_options} ${config_options} |
---|
63 | |
---|
64 | destroot.env-append CC="${prefix}/bin/gcc-mp-4.2" \ |
---|
65 | CXX="${prefix}/bin/g++-mp-4.2" |
---|
66 | build.env-append CC="${prefix}/bin/gcc-mp-4.2" \ |
---|
67 | CXX="${prefix}/bin/g++-mp-4.2" |
---|
68 | } |
---|
69 | |
---|
70 | variant gcc43 conflicts gcc42 gcc44 gcc45 description "Use gcc 4.3 tool chain for building" { |
---|
71 | configure.compiler macports-gcc-4.3 |
---|
72 | depends_lib-append port:gcc43 |
---|
73 | set fc_options "config_fc --fcompiler gnu95 --f77exec ${prefix}/bin/gfortran-mp-4.3 --f90exec ${prefix}/bin/gfortran-mp-4.3" |
---|
74 | set config_options "config --cc ${prefix}/bin/gcc-mp-4.3 --include-dirs ${prefix}/include --library-dirs ${prefix}/lib" |
---|
75 | build.cmd-append ${fc_options} ${config_options} |
---|
76 | destroot.cmd-append ${fc_options} ${config_options} |
---|
77 | |
---|
78 | destroot.env-append CC="${prefix}/bin/gcc-mp-4.3" \ |
---|
79 | CXX="${prefix}/bin/g++-mp-4.3" |
---|
80 | build.env-append CC="${prefix}/bin/gcc-mp-4.3" \ |
---|
81 | CXX="${prefix}/bin/g++-mp-4.3" |
---|
82 | } |
---|
83 | |
---|
84 | variant gcc44 conflicts gcc42 gcc43 gcc45 description "Use gfortran-mp-4.4 as fortran compiler" { |
---|
85 | configure.compiler macports-gcc-4.4 |
---|
86 | depends_lib-append port:gcc44 |
---|
87 | set fc_options "config_fc --fcompiler gnu95 --f77exec ${prefix}/bin/gfortran-mp-4.4 --f90exec ${prefix}/bin/gfortran-mp-4.4" |
---|
88 | set config_options "config --cc ${prefix}/bin/gcc-mp-4.4 --include-dirs ${prefix}/include --library-dirs ${prefix}/lib" |
---|
89 | build.cmd-append ${fc_options} ${config_options} |
---|
90 | destroot.cmd-append ${fc_options} ${config_options} |
---|
91 | |
---|
92 | destroot.env-append CC="${prefix}/bin/gcc-mp-4.4" \ |
---|
93 | CXX="${prefix}/bin/g++-mp-4.4" |
---|
94 | build.env-append CC="${prefix}/bin/gcc-mp-4.4" \ |
---|
95 | CXX="${prefix}/bin/g++-mp-4.4" |
---|
96 | } |
---|
97 | |
---|
98 | variant gcc45 conflicts gcc42 gcc43 gcc44 description "Use gfortran-mp-4.5 as fortran compiler" { |
---|
99 | configure.compiler macports-gcc-4.5 |
---|
100 | depends_lib-append port:gcc45 |
---|
101 | set fc_options "config_fc --fcompiler gnu95 --f77exec ${prefix}/bin/gfortran-mp-4.5 --f90exec ${prefix}/bin/gfortran-mp-4.5" |
---|
102 | set config_options "config --cc ${prefix}/bin/gcc-mp-4.5 --include-dirs ${prefix}/include --library-dirs ${prefix}/lib" |
---|
103 | build.cmd-append ${fc_options} ${config_options} |
---|
104 | destroot.cmd-append ${fc_options} ${config_options} |
---|
105 | |
---|
106 | destroot.env-append CC="${prefix}/bin/gcc-mp-4.5" \ |
---|
107 | CXX="${prefix}/bin/g++-mp-4.5" |
---|
108 | build.env-append CC="${prefix}/bin/gcc-mp-4.5" \ |
---|
109 | CXX="${prefix}/bin/g++-mp-4.5" |
---|
110 | } |
---|
111 | |
---|
112 | if { ![variant_isset gcc42] && ![variant_isset gcc43] && ![variant_isset gcc45] } { |
---|
113 | default_variants +gcc44 |
---|
114 | } |
---|
115 | |
---|
116 | } |
---|
117 | |
---|
118 | python.add_archflags no |
---|
119 | universal_variant no |
---|
120 | |
---|
121 | livecheck.type regex |
---|
122 | livecheck.url http://sourceforge.net/projects/scipy/files/ |
---|
123 | livecheck.regex "files\/scipy\/(\\d+(?:\\.\\d+)*)\/scipy" |
---|