[133004] trunk/dports/math/octave/Portfile

michaelld at macports.org michaelld at macports.org
Tue Feb 17 11:33:42 PST 2015


Revision: 133004
          https://trac.macports.org/changeset/133004
Author:   michaelld at macports.org
Date:     2015-02-17 11:33:42 -0800 (Tue, 17 Feb 2015)
Log Message:
-----------
octave:
+ add +glgui with explicit depends, to correct dependencies removed in r121950 (where this variant was +fltk); might address ticket #46879;
+ move +gui to +qtgui; set +gui as replaced by +qtgui;
+ shuffle sections around to make 'port' happier when getting info.

Revision Links:
--------------
    https://trac.macports.org/changeset/121950

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

Modified: trunk/dports/math/octave/Portfile
===================================================================
--- trunk/dports/math/octave/Portfile	2015-02-17 18:08:05 UTC (rev 133003)
+++ trunk/dports/math/octave/Portfile	2015-02-17 19:33:42 UTC (rev 133004)
@@ -9,7 +9,7 @@
 name                octave
 
 version             3.8.2
-revision            4
+revision            5
 #conflicts           octave-devel
 categories          math science
 maintainers         michaelld openmaintainer
@@ -99,8 +99,6 @@
     --disable-dependency-tracking \
     --with-umfpack="-lumfpack -lSuiteSparse" \
     --disable-java \
-    --with-opengl \
-    --with-framework-opengl \
     --enable-docs
 
 # octave uses a number of other ports to create sources from template:
@@ -154,12 +152,27 @@
 # atlas does not work with g95, so always conflict with it
 
 variant atlas description {use BLAS from MacPorts' atlas port} \
-    conflicts g95 accelerate {}
+    conflicts g95 accelerate {
 
+    depends_lib-append port:atlas
+    # NOTE: libtatlas does not work as of 3.10.1_5
+    configure.args-append \
+        --with-blas="-lcblas -lf77blas -latlas" \
+        --with-lapack="-llapack"
+
+}
+
 variant accelerate description \
     {use BLAS from Apple's Accelerate.framework [might be buggy]} \
-    conflicts atlas {}
+    conflicts atlas {
 
+    depends_lib-append port:vecLibFort
+    configure.args-append \
+        --with-blas=-lvecLibFort \
+        --with-lapack="-Wl,-framework -Wl,Accelerate"
+
+}
+
 if {![variant_isset accelerate] && ![variant_isset atlas]} {
 
     # when neither +accelerate nor +atlas is selected, default to the
@@ -181,40 +194,49 @@
 
 }
 
-if {[variant_isset accelerate]} {
+variant x11 description {Enable use of X11} {}
 
-    depends_lib-append port:vecLibFort
-    configure.args-append \
-        --with-blas=-lvecLibFort \
-        --with-lapack="-Wl,-framework -Wl,Accelerate"
+if {[variant_isset x11]} {
 
+    configure.args-append --with-x --x-includes=${prefix}
+
 } else {
 
-    depends_lib-append    port:atlas
-    # NOTE: libtatlas does not work as of 3.10.1_5
-    configure.args-append \
-        --with-blas="-lcblas -lf77blas -latlas" \
-        --with-lapack="-llapack"
+    configure.args-append --without-x
 
 }
 
-variant x11 description {Enable use of X11} {}
+default_variants +glgui
 
-if {[variant_isset x11]} {
+variant glgui description {Enable OpenGL GUI (via FLTK) as the default graphical front-end} {
 
-    configure.args-append --with-x --x-includes=${prefix}
+    depends_lib-append path:lib/libfltk.dylib:fltk \
+                       port:fontconfig \
+                       port:freetype \
+                       port:gl2ps
 
+}
+
+if {[variant_isset glgui]} {
+
+    configure.args-append --with-opengl
+
 } else {
 
-    configure.args-append --without-x
+    configure.args-append --without-opengl
 
 }
 
-variant gui description {Enable experimental Qt GUI} {}
+variant gui requires qtgui description {Legacy variant} {}
 
-if {[variant_isset gui]} {
+variant qtgui description {Enable experimental Qt GUI Application} {
 
     depends_lib-append port:qscintilla
+
+}
+
+if {[variant_isset qtgui]} {
+
     configure.args-append --enable-gui
 
 } else {
@@ -242,12 +264,15 @@
 # }
 
 variant metis description {Use SuiteSparse + Metis for graph partitioning} {
+
     notes-append "\nWARNING: ${name} variant +metis uses the metis port, whose license is incompatible with Octave's.  You can use this combination locally, but you cannot distribute them as a single package (e.g., tarball, m/pkg, archive)."
+
+    depends_lib-append      port:metis
+
 }
 
 if {[variant_isset metis]} {
 
-    depends_lib-append      port:metis
     configure.args-append   --with-cholmod="-lcholmod -lmetis"
 
     # make sure SuiteSparse is installed with +metis
@@ -279,9 +304,9 @@
 
 post-destroot {
 
-    # select the default graphics toolkit depending on the +gui variant
+    # select the default graphics toolkit depending on the +glgui variant
 
-    if {[variant_isset gui]} {
+    if {[variant_isset glgui]} {
         system "echo 'graphics_toolkit(\"fltk\");' >> ${destroot}${prefix}/share/octave/site/m/startup/octaverc"
     } else {
         system "echo 'graphics_toolkit(\"gnuplot\");' >> ${destroot}${prefix}/share/octave/site/m/startup/octaverc"
@@ -293,9 +318,9 @@
     xinstall -m 640 ${worksrcpath}/liboctave/operators/libcxx-fix.h \
         ${destroot}${prefix}/include/${name}-${version}/${name}/libcxx-fix.h
 
-    # when doing +gui variant, create the Mac OS X .app
+    # when doing +qtgui variant, create the Mac OS X .app
 
-    if {[variant_isset gui]} {
+    if {[variant_isset qtgui]} {
         set appdir ${destroot}${applications_dir}/Octave.app
         xinstall -d ${appdir}/Contents/MacOS
         xinstall -d ${appdir}/Contents/Resources
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20150217/5f557548/attachment-0001.html>


More information about the macports-changes mailing list