[136518] trunk/dports/graphics/asymptote/Portfile

mojca at macports.org mojca at macports.org
Wed May 20 01:39:55 PDT 2015


Revision: 136518
          https://trac.macports.org/changeset/136518
Author:   mojca at macports.org
Date:     2015-05-20 01:39:55 -0700 (Wed, 20 May 2015)
Log Message:
-----------
asymptote: fix handling of python variant

Modified Paths:
--------------
    trunk/dports/graphics/asymptote/Portfile

Modified: trunk/dports/graphics/asymptote/Portfile
===================================================================
--- trunk/dports/graphics/asymptote/Portfile	2015-05-20 08:26:47 UTC (rev 136517)
+++ trunk/dports/graphics/asymptote/Portfile	2015-05-20 08:39:55 UTC (rev 136518)
@@ -69,7 +69,12 @@
                     port:texlive-latex-recommended
 
 post-destroot {
-    if {![variant_isset python27]} {
+    if {[variant_isset python27]} {
+        set python.branch   2.7
+        set python.bin      ${prefix}/bin/python${python.branch}
+        eval reinplace {"s|#!/usr/bin/env python|#!${python.bin}|"} \
+            [glob -directory ${destroot}${prefix}/share/${name}/GUI *.py]
+    } else {
         delete ${destroot}${prefix}/bin/xasy
     }
 }
@@ -87,14 +92,9 @@
 variant python27 description {Enable xasy GUI using Python 2.7} {
     set python.version  27
     set python.branch   2.7
-    set python.bin      ${prefix}/bin/python${python.branch}
 
     depends_lib-append  port:py${python.version}-tkinter \
                         path:${frameworks_dir}/Python.framework/Versions/${python.branch}/lib/python${python.branch}/site-packages/PIL:py${python.version}-Pillow
-    post-destroot {
-        eval reinplace {"s|#!/usr/bin/env python|#!${python.bin}|"} \
-            [glob -directory ${destroot}${prefix}/share/${name}/GUI *.py]
-    }
 }
 default_variants    +python27
 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20150520/f05ae0da/attachment.html>


More information about the macports-changes mailing list