Ticket #29242: Portfile

File Portfile, 2.9 KB (added by howarth@…, 13 years ago)

Portfile bumped to svn revision 3945

Line 
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: Portfile 75159 2011-01-17 02:00:53Z rmstonecipher@macports.org $
3
4PortSystem          1.0
5PortGroup           python26 1.0
6
7name                pymol
8version             1.4
9categories          science
10maintainers         bromo.med.uc.edu:howarth
11description         Molecular graphics system
12long_description    PyMOL is a molecular graphics system with an embedded Python interpreter \
13                    designed for real-time visualization and rapid generation of high-quality \
14                    molecular graphics images and animations.
15
16platforms           darwin
17
18homepage            http://www.pymol.org/
19
20master_sites        sourceforge
21fetch.type          svn
22svn.url             https://pymol.svn.sourceforge.net/svnroot/pymol/trunk/pymol
23svn.revision        3945
24worksrcdir          pymol
25
26depends_lib         port:freetype port:libpng port:python26 port:py26-pmw port:py26-numeric port:mesa port:glew port:py26-tkinter
27depends_run         port:xdpyinfo
28
29patchfiles         setup_py.diff pymol_shell.diff
30
31post-patch {
32    reinplace  "s|@PREFIX@|${prefix}|g" ${worksrcpath}/setup.py
33    reinplace  "s|@@PYTHON_PKGDIR@@|${python.pkgd}|g" ${worksrcpath}/setup/pymol_macports
34    reinplace  "s|@@PYTHON_BINARY@@|${python.bin}|g" ${worksrcpath}/setup/pymol_macports
35}
36
37use_parallel_build  no
38
39variant gcc43 description conflicts gcc44 gcc45 description {build using macports-gcc-4.3} {
40    depends_lib-append  port:gcc43
41    # the current pymol makefile does not honour CC and CXX environment variables
42    build.args-delete   CC="${configure.cc}" CXX="${configure.cxx}"
43    build.args-append   CC="${prefix}/bin/gcc-mp-4.3" CXX="${prefix}/bin/g++-mp-4.3"
44    configure.compiler  macports-gcc-4.3
45}
46
47variant gcc44 description conflicts gcc43 gcc45 description {build using macports-gcc-4.4} {
48    depends_lib-append  port:gcc44
49    # the current pymol makefile does not honour CC and CXX environment variables
50    build.args-delete   CC="${configure.cc}" CXX="${configure.cxx}"
51    build.args-append   CC="${prefix}/bin/gcc-mp-4.4" CXX="${prefix}/bin/g++-mp-4.4"
52    configure.compiler  macports-gcc-4.4
53}
54
55variant gcc45 description conflicts gcc43 gcc44 description {build using macports-gcc-4.5} {
56    depends_lib-append  port:gcc45
57    # the current pymol makefile does not honour CC and CXX environment variables
58    build.args-delete   CC="${configure.cc}" CXX="${configure.cxx}"
59    build.args-append   CC="${prefix}/bin/gcc-mp-4.5" CXX="${prefix}/bin/g++-mp-4.5"
60    configure.compiler  macports-gcc-4.5
61}
62
63post-destroot {
64     file copy ${worksrcpath}/setup/pymol_macports ${destroot}${prefix}/bin/pymol
65     file attributes ${destroot}${prefix}/bin/pymol -permissions a+x
66     foreach d {data modules examples test scripts} {
67        copy ${worksrcpath}/${d} ${destroot}${python.pkgd}/pymol
68    }
69}