[131521] trunk/dports/science/gr-fosphor/Portfile
michaelld at macports.org
michaelld at macports.org
Tue Jan 13 07:34:45 PST 2015
Revision: 131521
https://trac.macports.org/changeset/131521
Author: michaelld at macports.org
Date: 2015-01-13 07:34:45 -0800 (Tue, 13 Jan 2015)
Log Message:
-----------
gr-fosphor:
+ use qt4 PortGroup;
+ require Python 2.7; leave +python2[67] legacy variants for now.
Modified Paths:
--------------
trunk/dports/science/gr-fosphor/Portfile
Modified: trunk/dports/science/gr-fosphor/Portfile
===================================================================
--- trunk/dports/science/gr-fosphor/Portfile 2015-01-13 15:24:31 UTC (rev 131520)
+++ trunk/dports/science/gr-fosphor/Portfile 2015-01-13 15:34:45 UTC (rev 131521)
@@ -4,6 +4,7 @@
PortSystem 1.0
PortGroup cmake 1.0
PortGroup wxWidgets 1.0
+PortGroup qt4 1.0
PortGroup active_variants 1.1
wxWidgets.use wxPython-3.0
@@ -32,12 +33,10 @@
port:cppunit \
port:freetype \
port:glfw \
- port:qt4-mac \
port:swig-python \
port:${wxWidgets.port}
depends_build-append \
- port:pkgconfig \
port:doxygen
# do VPATH build
@@ -61,70 +60,31 @@
build.post_args VERBOSE=1
-# set Python variants
+# set Python legacy variants; these can be removed 2016-01-01
-set pythons_suffixes {26 27}
-global chosen_python_suffix
-set chosen_python_suffix ""
+variant python26 description {Legacy variant} {}
+variant python27 description {Legacy variant} {}
-set pythons_ports {}
-foreach s ${pythons_suffixes} {
- lappend pythons_ports python${s}
-}
+# specify the Python dependencies
-foreach s ${pythons_suffixes} {
- set p python${s}
- set v [join [split ${s} ""] "."]
- set i [lsearch -exact ${pythons_ports} ${p}]
- set c [lreplace ${pythons_ports} ${i} ${i}]
- eval [subst {
- variant ${p} description "Build ${name} using Python ${v}" \
- conflicts ${c} {
+depends_lib-append \
+ port:python27
- set chosen_python_suffix ${s}
+# wxPython is required for configure and runtime
- # specify the Python dependencies
+depends_lib-append \
+ port:py27-wxpython-3.0
- depends_lib-append \
- port:${p}
+# specify the Python version to use
- # wxPython is required for configure and runtime
+configure.args-append \
+ -DPYTHON_EXECUTABLE=${prefix}/Library/Frameworks/Python.framework/Versions/2.7/bin/python2.7 \
+ -DPYTHON_INCLUDE_DIR=${prefix}/Library/Frameworks/Python.framework/Versions/2.7/Headers \
+ -DPYTHON_LIBRARY=${prefix}/Library/Frameworks/Python.framework/Versions/2.7/Python \
+ -DGR_PYTHON_DIR=${frameworks_dir}/Python.framework/Versions/2.7/lib/python2.7/site-packages
- depends_lib-append \
- port:py${s}-wxpython-3.0
+# allow gr-forphor to work with both gnuradio and gnuradio-devel ...
- # require gnuradio to also have this Python variant
-
- require_active_variants \
- path:lib/libgnuradio-runtime.dylib:gnuradio ${p}
-
- # specify the Python version to use
-
- configure.args-append \
- -DPYTHON_EXECUTABLE=${prefix}/bin/python${v} \
- -DPYTHON_INCLUDE_DIR=${prefix}/Library/Frameworks/Python.framework/Versions/${v}/Headers \
- -DPYTHON_LIBRARY=${prefix}/Library/Frameworks/Python.framework/Versions/${v}/Python \
- -DGR_PYTHON_DIR=${frameworks_dir}/Python.framework/Versions/${v}/lib/python${v}/site-packages
-
- }
- }]
-}
-
-# Python is required; default to 2.7
-
-if {![variant_isset python26] && ![variant_isset python27]} {
- default_variants +python27
-}
-
-# Make sure -python27 was not specified alone
-
-if {![variant_isset python26] && ![variant_isset python27]} {
- ui_error "This port requires a Python to be selected; you cannot use -python27 as a variant alone."
- return -code error "Invalid variant selection"
-}
-
-# allow gr-osmosdr to work with both gnuradio and gnuradio-devel ...
-
depends_lib-append path:lib/libgnuradio-runtime.dylib:gnuradio
# ... but not with gnuradio-legacy or gnuradio-next
@@ -132,12 +92,12 @@
pre-fetch {
if {![catch {set installed [lindex [registry_active gnuradio-legacy] 0]}]} {
- # gnuradio-legacy is installed; this version of gr-osmosdr does not work with gnuradio-legacy
+ # gnuradio-legacy is installed; this version of gr-forphor does not work with gnuradio-legacy
ui_msg "\nError: ${name} requires the gnuradio or gnuradio-devel port, and will not work with the gnuradio-legacy port. deactivate gnuradio-legacy, and then install or activate gnuradio or gnuradio-devel.\n"
return -code error "Invalid port dependency: gnuradio-legacy"
}
if {![catch {set installed [lindex [registry_active gnuradio-next] 0]}]} {
- # gnuradio-next is installed; this version of gr-osmosdr does not work with gnuradio-next
+ # gnuradio-next is installed; this version of gr-forphor does not work with gnuradio-next
ui_msg "\nError: ${name} requires the gnuradio or gnuradio-devel port, and will not work with the gnuradio-next port. deactivate gnuradio-next, and then install or activate gnuradio or gnuradio-devel.\n"
return -code error "Invalid port dependency: gnuradio-next"
}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20150113/ef7e2f98/attachment-0001.html>
More information about the macports-changes
mailing list