<pre style='margin:0'>
Mojca Miklavec (mojca) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/b505e0c37285cd971a06156fc1a4da1aac537801">https://github.com/macports/macports-ports/commit/b505e0c37285cd971a06156fc1a4da1aac537801</a></p>
<pre style="white-space: pre; background: #F8F8F8">The following commit(s) were added to refs/heads/master by this push:
<span style='display:block; white-space:pre;color:#404040;'> new b505e0c pymol: restore use of -O3 optimization flag
</span>b505e0c is described below
<span style='display:block; white-space:pre;color:#808000;'>commit b505e0c37285cd971a06156fc1a4da1aac537801
</span>Author: jwhowarth <howarth.mailing.lists@gmail.com>
AuthorDate: Sat Apr 28 08:41:52 2018 -0400
<span style='display:block; white-space:pre;color:#404040;'> pymol: restore use of -O3 optimization flag
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> Fix lack of optimization in compiling pymol on clang compilers.
</span><span style='display:block; white-space:pre;color:#404040;'> Restores the previous -O3 optimization of pymol on darwin by passing -fno-strict-aliasing.
</span><span style='display:block; white-space:pre;color:#404040;'> Upstream stopped passing any optimization flags at all to pymol due to a compiler segfault
</span><span style='display:block; white-space:pre;color:#404040;'> in compiling layer2/RepCylBond.cpp starting with OS X 10.9 and later.
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> See: https://sourceforge.net/p/pymol/bugs/205/
</span><span style='display:block; white-space:pre;color:#404040;'> See: https://bugs.llvm.org/show_bug.cgi?id=37280
</span><span style='display:block; white-space:pre;color:#404040;'> Closes: https://trac.macports.org/ticket/56373
</span>---
science/pymol/Portfile | 5 +++--
science/pymol/files/setup.py.diff | 29 +++++++++++++++++++++++++++++
2 files changed, 32 insertions(+), 2 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/science/pymol/Portfile b/science/pymol/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 5cc332d..c42552a 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/science/pymol/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/science/pymol/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -7,6 +7,7 @@ PortGroup compilers 1.0
</span>
name pymol
version 2.1.0
<span style='display:block; white-space:pre;background:#e0ffe0;'>+revision 1
</span> categories science chemistry
license PSF
maintainers {gmail.com:howarth.at.macports @jwhowarth} openmaintainer
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -67,7 +68,8 @@ universal_variant no
</span> patchfiles pymol_shell.diff \
pmg_tk_platform.patch \
apbs-psize.patch \
<span style='display:block; white-space:pre;background:#ffe0e0;'>- pdb2pqr.patch
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ pdb2pqr.patch \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ setup.py.diff
</span>
require_active_variants tcl "" corefoundation
require_active_variants tk "" quartz
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -76,7 +78,6 @@ post-patch {
</span> reinplace "s|@PREFIX@|${prefix}|g" ${worksrcpath}/setup.py ${worksrcpath}/modules/pmg_tk/startup/apbs_tools.py
reinplace "s|@@PYTHON_PKGDIR@@|${python.pkgd}|g" ${worksrcpath}/setup/pymol_macports
reinplace "s|@@PYTHON_BINARY@@|${python.bin}|g" ${worksrcpath}/setup/pymol_macports
<span style='display:block; white-space:pre;background:#ffe0e0;'>- reinplace "s|\"-O3\",|\"-O3\", \"-g\",|g" ${worksrcpath}/setup.py
</span> reinplace "s|cxx + \' \' + cxxflags|\'${configure.cxx} \' + cxxflags|g" ${worksrcpath}/monkeypatch_distutils.py
}
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/science/pymol/files/setup.py.diff b/science/pymol/files/setup.py.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..13ff744
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/science/pymol/files/setup.py.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,29 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Index: setup.py
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+===================================================================
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- setup.py (revision 4187)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ setup.py (working copy)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -87,7 +87,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ X11 = ['/usr/X11'] * (not options.osx_frameworks)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if sys.platform == 'darwin':
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- for prefix in ['/sw', '/opt/local', '/usr/local']:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ for prefix in ['@PREFIX@', '/usr/local']:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if sys.executable.startswith(prefix):
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ return [prefix] + X11
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -392,12 +392,12 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ libs += ["GLEW"]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ libs += pyogl_libs
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- ext_comp_args += ["-ffast-math", "-funroll-loops", "-fcommon"]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ ext_comp_args += ["-ffast-math", "-funroll-loops", "-fcommon", "-O3"]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # optimization currently causes a clang segfault on OS X 10.9 when
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # compiling layer2/RepCylBond.cpp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- if sys.platform != 'darwin':
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- ext_comp_args += ["-O3"]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if sys.platform == 'darwin':
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ ext_comp_args += ["-fno-strict-aliasing"]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ def get_pymol_version():
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ return re.findall(r'_PyMOL_VERSION "(.*)"', open('layer0/Version.h').read())[0]
</span></pre><pre style='margin:0'>
</pre>