source: trunk/dports/devel/ice-python25/Portfile @ 37863

Last change on this file since 37863 was 37863, checked in by blair@…, 11 years ago

Now that MacPorts has a framework Python 2.5 build, the Ice bindings
to them can be built.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.4 KB
Line 
1# $Id: Portfile 37863 2008-06-26 22:05:17Z blair@macports.org $
2
3PortSystem 1.0
4
5name            ice-python25
6version         3.3.0
7categories      devel python
8maintainers     blair
9description     Fast, object-oriented RPC for C++, Java, Python, Ruby, PHP
10
11long_description \
12        The Internet Communications Engine (Ice) is a modern alternative to \
13        object middleware such as CORBA or COM/DCOM/COM+, with support for \
14        C++, C#, Java, PHP, Python, Ruby and Visual Basic. \
15        Ice consists of the following packages. \
16        Slice: The Specification Language for Ice.  Slice establishes a \
17        contract between clients and servers, and is also used to describe \
18        persistent data. \
19        Slice Compilers: Slice specifications are compiled into various \
20        programming languages. Ice supports C++, Java, C#, Visual Basic, PHP, \
21        Python and Ruby.  Ice clients and servers work together, regardless \
22        of the programming language. \
23        Ice: The Ice core library manages all the communication tasks using a \
24        highly efficient protocol (including protocol compression and support \
25        for both TCP and UDP), provides a flexible thread pool for \
26        multi-threaded servers. \
27        This Port provides the Python bindings that sit on top of the C++ \
28        Ice C++ runtime libraries.
29
30homepage        http://www.zeroc.com/
31master_sites    http://www.zeroc.com/download/Ice/3.3/
32dist_subdir     ice-cpp
33distname        Ice-${version}
34checksums       md5 0500306d9cdbc0fbb553fbb529de557a \
35                sha1 b599c3a4d1d3006b868bf2cbcd8e2a2d4575fb22 \
36                rmd160 e85b37c93f12d9ae97c6b7b2f64f506fa051e4f8
37platforms       darwin
38
39depends_lib     port:python25 \
40                port:ice-cpp
41
42patchfiles      patch-py.config.Make.rules.Darwin.diff \
43                patch-config.TestUtil.py.diff
44
45post-patch {
46        reinplace "s#python Client.py#${prefix}/bin/python2.5 Client.py#" \
47                ${worksrcpath}/py/test/Slice/keyword/run.py
48}
49
50use_configure   no
51
52build.dir       ${worksrcpath}/py
53build.target    prefix="${prefix}" \
54                ICE_HOME="${prefix}" \
55                PYTHON_HOME="${prefix}/Library/Frameworks/Python.framework/Versions/2.5" \
56                PYTHON_VERSION=python2.5 \
57                OPTIMIZE="yes" \
58                all
59
60test.run        yes
61test.dir        ${worksrcpath}/py
62test.env        ICE_HOME=${prefix}
63test.cmd        ${prefix}/bin/python2.5
64test.target     allTests.py
65
66destroot.dir    ${worksrcpath}/py
67destroot.target prefix="${destroot}${prefix}" \
68                ICE_HOME="${prefix}" \
69                PYTHON_HOME="${prefix}/Library/Frameworks/Python.framework/Versions/2.5" \
70                PYTHON_VERSION=python2.5 \
71                OPTIMIZE="yes" \
72                install
73
74post-destroot {
75        set sharedir ${destroot}${prefix}/share
76        set docdir ${sharedir}/doc/${name}
77
78        delete ${destroot}${prefix}/slice
79
80        xinstall -m 755 -d ${docdir}
81
82        file mkdir ${destroot}${prefix}/lib/python2.5
83        file rename ${destroot}${prefix}/python ${destroot}${prefix}/lib/python2.5/site-packages
84
85        set cmd "${prefix}/bin/python2.5 \
86                ${prefix}/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/compileall.py \
87                ${destroot}${prefix}/lib/python2.5/site-packages"
88        ui_debug ${cmd}
89        system ${cmd}
90
91        set cmd "${prefix}/bin/python2.5 -O \
92                ${prefix}/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/compileall.py \
93                ${destroot}${prefix}/lib/python2.5/site-packages"
94        ui_debug ${cmd}
95        system ${cmd}
96
97        file rename ${destroot}${prefix}/ICE_LICENSE ${docdir}
98        file rename ${destroot}${prefix}/LICENSE ${docdir}
99        foreach f {CHANGES RELEASE_NOTES} {
100                file copy ${worksrcpath}/${f} ${docdir}
101        }
102        file copy ${worksrcpath}/py/INSTALL ${docdir}
103
104        if {[variant_isset demo_source_code]} {
105                file copy ${worksrcpath}/py/demo ${docdir}
106        }
107}
108
109variant demo_source_code description {Install demonstration Python code} {
110}
Note: See TracBrowser for help on using the repository browser.