# -*- 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 # $Id$ PortSystem 1.0 PortGroup python 1.0 PortGroup active_variants 1.1 PortGroup compilers 1.0 name pymol version 1.8.3.2 categories science chemistry license PSF maintainers gmail.com:howarth.at.macports openmaintainer description Molecular graphics system long_description PyMOL is a molecular graphics system with an embedded Python interpreter \ designed for real-time visualization and rapid generation of high-quality \ molecular graphics images and animations. platforms darwin homepage http://www.pymol.org/ master_sites sourceforge fetch.type svn svn.url https://svn.code.sf.net/p/pymol/code/trunk/pymol svn.revision 4160 worksrcdir pymol compilers.choose cc cxx compilers.setup variant python27 conflicts python34 python35 description {Use Python 2.7} {} variant python34 conflicts python27 python35 description {Use Python 3.4} {} variant python35 conflicts python27 python34 description {Use Python 3.5} {} if {[variant_isset python34]} { python.default_version 34 } elseif {[variant_isset python35]} { python.default_version 35 } else { default_variants +python27 python.default_version 27 } python.link_binaries no depends_lib-append port:freeglut \ port:freetype \ port:glew \ port:libpng \ port:libGLU \ port:mesa \ port:py${python.version}-numpy \ port:py${python.version}-pmw \ port:py${python.version}-scipy \ port:py${python.version}-tkinter \ port:tcl \ port:tk depends_run port:xdpyinfo # py-scipy is not universal universal_variant no patchfiles pymol_shell.diff \ pmg_tk_platform.patch \ apbs-psize.patch if {${os.platform} eq "darwin" && ${os.major} >= 12} { patchfiles-append pymol-use-glkit.diff } require_active_variants tcl "" corefoundation require_active_variants tk "" quartz post-patch { reinplace "s|@PREFIX@|${prefix}|g" ${worksrcpath}/setup.py reinplace "s|@@PYTHON_PKGDIR@@|${python.pkgd}|g" ${worksrcpath}/setup/pymol_macports reinplace "s|@@PYTHON_BINARY@@|${python.bin}|g" ${worksrcpath}/setup/pymol_macports reinplace "s|\"-O3\",|\"-O3\", \"-g\",|g" ${worksrcpath}/setup.py reinplace "s|cxx + \' \' + cxxflags|\'${configure.cxx} \' + cxxflags|g" ${worksrcpath}/monkeypatch_distutils.py } use_parallel_build yes build {} pre-destroot { destroot.env CC="${configure.cc}" CXX="${configure.cxx}" PREFIX_PATH="${prefix}" } post-destroot { file copy ${worksrcpath}/setup/pymol_macports ${destroot}${prefix}/bin/pymol file attributes ${destroot}${prefix}/bin/pymol -permissions a+x foreach d {data modules examples test scripts} { copy ${worksrcpath}/${d} ${destroot}${python.pkgd}/pymol } }