[133724] trunk/dports/math/octave-symbolic

michaelld at macports.org michaelld at macports.org
Mon Mar 9 09:42:54 PDT 2015


Revision: 133724
          https://trac.macports.org/changeset/133724
Author:   michaelld at macports.org
Date:     2015-03-09 09:42:54 -0700 (Mon, 09 Mar 2015)
Log Message:
-----------
octave-symbolic:
+ update to 2.1.0;
+ use SymPy instead of GiNac;
+ patch and variants to select which Python to use.

Modified Paths:
--------------
    trunk/dports/math/octave-symbolic/Portfile

Added Paths:
-----------
    trunk/dports/math/octave-symbolic/files/
    trunk/dports/math/octave-symbolic/files/patch-inst_sympref.m.diff

Modified: trunk/dports/math/octave-symbolic/Portfile
===================================================================
--- trunk/dports/math/octave-symbolic/Portfile	2015-03-09 15:21:38 UTC (rev 133723)
+++ trunk/dports/math/octave-symbolic/Portfile	2015-03-09 16:42:54 UTC (rev 133724)
@@ -4,15 +4,46 @@
 PortSystem          1.0
 PortGroup           octave 1.0
 
-octave.setup        symbolic 1.1.0
+octave.setup        symbolic 2.1.0
 platforms           darwin
-license             GPL-2
+license             GPL-3
 maintainers         nomaintainer
-description         Symbolic toolbox based on GiNaC and CLN.
+description         Symbolic toolbox based on SymPy.
 
 long_description    ${description}
 
-checksums           rmd160 03ef679484489a3879a4435b5e2ee6d81ea08c4b \
-                    sha256 663c295eeed824b183d8d43e4c8836837ef76522f7393d4cd95c12878a59ece6
+checksums           rmd160 8cd1e45333df54ce2815ea2ef2468b6653cee0c7 \
+                    sha256 5d42e77e7bed56c43d9354ded5b6e9abe2dbe1c07551561a2966467b835b8d8c
 
-depends_lib-append  port:GiNaC
+# fix default Python to be within MacPorts
+
+patchfiles-append   patch-inst_sympref.m.diff
+
+variant python27 description "Use Python 2.7 SymPy" conflicts python34 {
+    depends_run-append  port:py27-sympy
+    post-patch {
+        reinplace "s|@PYTHON@|${prefix}/bin/python2.7|g" \
+            ${worksrcpath}/inst/sympref.m
+    }
+}
+
+variant python34 description "Use Python 3.4 SymPy" conflicts python27 {
+    depends_run-append  port:py34-sympy
+    post-patch {
+        reinplace "s|@PYTHON@|${prefix}/bin/python3.4|g" \
+            ${worksrcpath}/inst/sympref.m
+    }
+}
+
+if {![variant_isset python27] && ![variant_isset python34]} {
+    default_variants +python27
+}
+
+# make sure -python27 was not specified alone
+
+if {![variant_isset python27] && ![variant_isset python34]} {
+
+    ui_error "\n\nYou must select either the +python27 or +python34 variant.\n"
+    return -code error "Invalid variant selection"
+
+}

Added: trunk/dports/math/octave-symbolic/files/patch-inst_sympref.m.diff
===================================================================
--- trunk/dports/math/octave-symbolic/files/patch-inst_sympref.m.diff	                        (rev 0)
+++ trunk/dports/math/octave-symbolic/files/patch-inst_sympref.m.diff	2015-03-09 16:42:54 UTC (rev 133724)
@@ -0,0 +1,20 @@
+--- inst/sympref.m.orig	2015-03-09 12:26:26.000000000 -0400
++++ inst/sympref.m	2015-03-09 12:27:39.000000000 -0400
+@@ -22,7 +22,7 @@
+ %%
+ %% Python executable path/command:
+ %% @example
+-%% sympref python '/usr/bin/python'
++%% sympref python '@PYTHON@'
+ %% sympref python 'C:\Python\python.exe'
+ %% sympref python 'N:\myprogs\py.exe'
+ %% @end example
+@@ -124,7 +124,7 @@
+       else
+         settings.display = 'unicode';
+       end
+-      settings.whichpython = '';
++      settings.whichpython = '@PYTHON@';
+       settings.digits = 32;
+       settings.snippet = false;  % Should be false for a release
+ 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20150309/c7caf14a/attachment.html>


More information about the macports-changes mailing list