Revision
90202
Author
snc@macports.org
Date
2012-02-25 18:44:44 -0800 (Sat, 25 Feb 2012)

Log Message

pynmr: fixes for pymol 1.4, #29243

Modified Paths

Diff

Modified: trunk/dports/science/pynmr/Portfile (90201 => 90202)


--- trunk/dports/science/pynmr/Portfile	2012-02-26 00:09:53 UTC (rev 90201)
+++ trunk/dports/science/pynmr/Portfile	2012-02-26 02:44:44 UTC (rev 90202)
@@ -2,9 +2,11 @@
 # $Id$
 
 PortSystem          1.0
+PortGroup           python26 1.0
 
 name                pynmr
 version             0.37f
+revision            1
 categories          science
 maintainers         bromo.med.uc.edu:howarth
 
@@ -38,14 +40,18 @@
 post-patch {
     reinplace  "s|@PREFIX@|${prefix}|g" ${build.dir}/run.macos \
                                         ${build.dir}/test_data/test.script
+    reinplace  "s|Numeric import|numpy.oldnumeric import|g"  ${build.dir}/SVDSuperimposer.py \
+                                                             ${build.dir}/rmsd.py
+    reinplace  "s|LinearAlgebra import|numpy.oldnumeric.linear_algebra import|g" ${build.dir}/SVDSuperimposer.py
+    reinplace  "s|import MLab|import numpy.oldnumeric.mlab as MLab|g" ${build.dir}/rmsd.py
 }
 
 destroot {
-    xinstall -d ${destroot}${prefix}/lib/pymol/modules/pmg_tk/startup/pynmr
-    xinstall -m 644 ${worksrcpath}/pmg_tk/startup/plug_nmr.py ${destroot}${prefix}/lib/pymol/modules/pmg_tk/startup
-    xinstall -m 644 -W ${build.dir} Crmsd.so BIOPYTHON_LICENSE LICENSE README ${destroot}${prefix}/lib/pymol/modules/pmg_tk/startup/pynmr
+    xinstall -d ${destroot}${python.pkgd}/pmg_tk/startup/pynmr
+    xinstall -m 644 ${worksrcpath}/pmg_tk/startup/plug_nmr.py ${destroot}${python.pkgd}/pmg_tk/startup
+    xinstall -m 644 -W ${build.dir} Crmsd.so BIOPYTHON_LICENSE LICENSE README ${destroot}${python.pkgd}/pmg_tk/startup/pynmr
     foreach d {help images test_data} {
-       copy ${build.dir}/${d} ${destroot}${prefix}/lib/pymol/modules/pmg_tk/startup/pynmr
+       copy ${build.dir}/${d} ${destroot}${python.pkgd}/pmg_tk/startup/pynmr
     }
-    eval xinstall -m 644 [glob ${build.dir}/*.py] ${destroot}${prefix}/lib/pymol/modules/pmg_tk/startup/pynmr
+    eval xinstall -m 644 [glob ${build.dir}/*.py] ${destroot}${python.pkgd}/pmg_tk/startup/pynmr
 }