[101076] trunk/dports/python/py-mayavi

macsforever2000 at macports.org macsforever2000 at macports.org
Thu Jan 3 16:21:52 PST 2013


Revision: 101076
          https://trac.macports.org/changeset/101076
Author:   macsforever2000 at macports.org
Date:     2013-01-03 16:21:52 -0800 (Thu, 03 Jan 2013)
Log Message:
-----------
py-mayavi: Update to version 4.2.0. (#37410)

Modified Paths:
--------------
    trunk/dports/python/py-mayavi/Portfile

Added Paths:
-----------
    trunk/dports/python/py-mayavi/files/vtk510_text.patch

Removed Paths:
-------------
    trunk/dports/python/py-mayavi/files/changeset_r24036.diff

Modified: trunk/dports/python/py-mayavi/Portfile
===================================================================
--- trunk/dports/python/py-mayavi/Portfile	2013-01-03 23:48:43 UTC (rev 101075)
+++ trunk/dports/python/py-mayavi/Portfile	2013-01-04 00:21:52 UTC (rev 101076)
@@ -5,7 +5,7 @@
 PortGroup           python 1.0
 
 name                py-mayavi
-version             4.1.0
+version             4.2.0
 categories-append   devel graphics math
 maintainers         gmail.com:jjstickel openmaintainer
 description         The Enthought mayavi package
@@ -18,8 +18,8 @@
 master_sites        http://www.enthought.com/repo/ets/
 distname            mayavi-${version}
 
-checksums           sha256  53d44cf4dcd7ebf57e197e0a72002db30a74f23e5642e34b3b8f2ebe7a71bbf9 \
-                    rmd160  db9a6bf5af9778f11ebf5c22e5c2c7f1b8dc6557
+checksums           sha256  4554fc5a5ef58c3e57bb83f8f21340d8e0b483c46d4761ece133baa162a43a9b \
+                    rmd160  6e4ebf8361d13ba9fb58d8636335d73386bc8522
 
 python.versions        25 26 27
 python.default_version 27
@@ -33,7 +33,10 @@
                             port:py${python.version}-traitsui \
                             port:vtk5
 
-    patch {
+    patchfiles        vtk510_text.patch
+    patch.pre_args    -p1
+    
+    post-patch {
         reinplace "s|sphinx-build|sphinx-build-${python.branch}|g" \
             ${worksrcpath}/docs/Makefile \
             ${worksrcpath}/docs/MakefileMayavi \

Deleted: trunk/dports/python/py-mayavi/files/changeset_r24036.diff
===================================================================
--- trunk/dports/python/py-mayavi/files/changeset_r24036.diff	2013-01-03 23:48:43 UTC (rev 101075)
+++ trunk/dports/python/py-mayavi/files/changeset_r24036.diff	2013-01-04 00:21:52 UTC (rev 101076)
@@ -1,14 +0,0 @@
-Index: /Mayavi/trunk/enthought/mayavi/preferences/preference_manager.py
-===================================================================
---- /Mayavi/trunk/enthought/mayavi/preferences/preference_manager.py (revision 22324)
-+++ /Mayavi/trunk/enthought/mayavi/preferences/preference_manager.py (revision 24036)
-@@ -99,7 +99,7 @@
-         """Load the default preferences."""
-         # Save current application_home.
--        app_home = ETSConfig.application_home
-+        app_home = ETSConfig.get_application_home()
-         # Set it to where the mayavi preferences are temporarily.
--        path = join(ETSConfig.application_data, ID)
-+        path = join(ETSConfig.get_application_data(), ID)
-         ETSConfig.application_home = path
-         try:

Added: trunk/dports/python/py-mayavi/files/vtk510_text.patch
===================================================================
--- trunk/dports/python/py-mayavi/files/vtk510_text.patch	                        (rev 0)
+++ trunk/dports/python/py-mayavi/files/vtk510_text.patch	2013-01-04 00:21:52 UTC (rev 101076)
@@ -0,0 +1,83 @@
+From 15b0774659932596dab27363fa8eefdb855fda8f Mon Sep 17 00:00:00 2001
+From: "mluessi at nmr.mgh.harvard.edu" <mluessi at nmr.mgh.harvard.edu>
+Date: Mon, 9 Jul 2012 17:48:20 -0400
+Subject: [PATCH] FIX: version comp. for VTK 5.10
+
+---
+ mayavi/modules/text.py |    8 +++++---
+ tvtk/tools/mlab.py     |    5 +++--
+ 2 files changed, 8 insertions(+), 5 deletions(-)
+
+diff --git a/mayavi/modules/text.py b/mayavi/modules/text.py
+index 1fcc0e0..d1c79c0 100644
+--- a/mayavi/modules/text.py
++++ b/mayavi/modules/text.py
+@@ -5,6 +5,8 @@
+ # Copyright (c) 2005, Enthought, Inc.
+ # License: BSD Style.
+ 
++from distutils.version import StrictVersion
++
+ # Enthought library imports.
+ from traits.api import Instance, Range, Str, Bool, Property, \
+                                     Float
+@@ -16,7 +18,7 @@
+ from mayavi.core.module import Module
+ from mayavi.core.pipeline_info import PipelineInfo
+ 
+-VTK_VER = float(tvtk.Version().vtk_version[:3])
++VTK_VER = StrictVersion(tvtk.Version().vtk_version)
+ 
+ 
+ ######################################################################
+@@ -68,7 +70,7 @@ class Text(Module):
+     ########################################
+     # The view of this object.
+ 
+-    if VTK_VER > 5.1:
++    if VTK_VER > '5.1':
+         _text_actor_group = Group(Item(name='visibility'),
+                                   Item(name='text_scale_mode'),
+                                   Item(name='alignment_point'),
+@@ -152,7 +154,7 @@ def setup_pipeline(self):
+         set the `actors` attribute up at this point.
+         """
+         actor = self.actor = tvtk.TextActor(input=str(self.text))
+-        if VTK_VER > 5.1:
++        if VTK_VER > '5.1':
+             actor.set(text_scale_mode='prop', width=0.4, height=1.0)
+         else:
+             actor.set(scaled_text=True, width=0.4, height=1.0)
+diff --git a/tvtk/tools/mlab.py b/tvtk/tools/mlab.py
+index 8262da0..dfe9230 100644
+--- a/tvtk/tools/mlab.py
++++ b/tvtk/tools/mlab.py
+@@ -92,6 +92,7 @@
+ # Copyright (c) 2005-2007, Enthought, Inc.
+ # License: BSD Style.
+ 
++from distutils.version import StrictVersion
+ 
+ import numpy
+ 
+@@ -107,7 +108,7 @@
+ # Set this to False to not use LOD Actors.
+ USE_LOD_ACTOR = True
+ 
+-VTK_VER = float(tvtk.Version().vtk_version[:3])
++VTK_VER = StrictVersion(tvtk.Version().vtk_version)
+ 
+ ######################################################################
+ # Utility functions.
+@@ -639,7 +640,7 @@ def __init__(self, **traits):
+         super(Title, self).__init__(**traits)
+ 
+         ta = self.text_actor
+-        if VTK_VER > 5.1:
++        if VTK_VER > '5.1':
+             ta.set(text_scale_mode='prop', height=0.05, input=self.text)
+         else:
+             ta.set(scaled_text=True, height=0.05, input=self.text)
+-- 
+1.7.10
+
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20130103/e353f161/attachment-0001.html>


More information about the macports-changes mailing list