1 | # $Id$ |
---|
2 | |
---|
3 | PortSystem 1.0 |
---|
4 | PortGroup python24 1.0 |
---|
5 | |
---|
6 | categories python |
---|
7 | name py-cvxopt |
---|
8 | version 1.0 |
---|
9 | distname cvxopt-${version} |
---|
10 | maintainers nomaintainer |
---|
11 | platforms darwin |
---|
12 | |
---|
13 | description Python module for convex optimization |
---|
14 | long_description CVXOPT is a free software package for convex optimization \ |
---|
15 | based on the Python programming language. It can be used with the interactive \ |
---|
16 | Python interpreter, on the command line by executing Python scripts, or \ |
---|
17 | integrated in other software via Python extension modules. Its main purpose is \ |
---|
18 | to make the development of software for convex optimization applications \ |
---|
19 | straightforward by building on Python's extensive standard library and on the \ |
---|
20 | strengths of Python as a high-level programming language. |
---|
21 | |
---|
22 | homepage http://abel.ee.ucla.edu/cvxopt |
---|
23 | |
---|
24 | distfiles cvxopt-${version}.tar.gz.gtar |
---|
25 | master_sites http://abel.ee.ucla.edu/download.php |
---|
26 | |
---|
27 | checksums md5 4fccd976f8e39d9b7f38c663f7652a8a \ |
---|
28 | sha1 d05700009b1df26c97d20c5afb22386fe587fc0e \ |
---|
29 | rmd160 9034093062ba66f72dd2af65f4d982bd7b5e1ce0 |
---|
30 | |
---|
31 | depends_lib port:atlas |
---|
32 | |
---|
33 | variant gsl description {Allow linking to gsl} { |
---|
34 | depends_lib-append port:gsl |
---|
35 | } |
---|
36 | |
---|
37 | variant fftw description {Link to fftw library} { |
---|
38 | depends_lib-append port:fftw-3 |
---|
39 | } |
---|
40 | |
---|
41 | variant glpk description {Link to glpk library} { |
---|
42 | depends_lib-append port:glpk |
---|
43 | } |
---|
44 | |
---|
45 | default_variants +gsl +glpk +fftw |
---|
46 | |
---|
47 | configure { |
---|
48 | reinplace "s|ATLAS_LIB_DIR = .*|ATLAS_LIB_DIR = '/opt/local/lib'|" \ |
---|
49 | ${worksrcpath}/src/setup.py |
---|
50 | |
---|
51 | if {[variant_isset gsl]} { |
---|
52 | reinplace "s|BUILD_GSL = .*|BUILD_GSL = 1|" \ |
---|
53 | ${worksrcpath}/src/setup.py |
---|
54 | reinplace "s|GSL_LIB_DIR = .*|GSL_LIB_DIR = '/opt/local/lib'|" \ |
---|
55 | ${worksrcpath}/src/setup.py |
---|
56 | reinplace "s|GSL_INC_DIR = .*|GSL_INC_DIR = '/opt/local/include'|" \ |
---|
57 | ${worksrcpath}/src/setup.py |
---|
58 | } |
---|
59 | if {[variant_isset glpk]} { |
---|
60 | reinplace "s|BUILD_GLPK = .*|BUILD_GLPK = 1|" \ |
---|
61 | ${worksrcpath}/src/setup.py |
---|
62 | reinplace "s|GLPK_LIB_DIR = .*|GLPK_LIB_DIR = '/opt/local/lib'|" \ |
---|
63 | ${worksrcpath}/src/setup.py |
---|
64 | reinplace "s|GLPK_INC_DIR = .*|GLPK_INC_DIR = '/opt/local/include'|" \ |
---|
65 | ${worksrcpath}/src/setup.py |
---|
66 | } |
---|
67 | if {[variant_isset fftw]} { |
---|
68 | reinplace "s|BUILD_FFTW = .*|BUILD_FFTW = 1|" \ |
---|
69 | ${worksrcpath}/src/setup.py |
---|
70 | reinplace "s|FFTW_LIB_DIR = .*|FFTW_LIB_DIR = '/opt/local/lib'|" \ |
---|
71 | ${worksrcpath}/src/setup.py |
---|
72 | reinplace "s|FFTW_INC_DIR = .*|FFTW_INC_DIR = '/opt/local/include'|" \ |
---|
73 | ${worksrcpath}/src/setup.py |
---|
74 | } |
---|
75 | } |
---|
76 | |
---|
77 | build.dir ${worksrcpath}/src |
---|
78 | |
---|
79 | destroot.dir ${build.dir} |
---|