Ticket #52824: gnuradio_enable_ctrlport.diff

File gnuradio_enable_ctrlport.diff, 2.7 KB (added by michaelld (Michael Dickens), 8 years ago)
  • science/gnuradio/Portfile

    diff --git a/science/gnuradio/Portfile b/science/gnuradio/Portfile
    index dff4309fb7..d256c210c7 100644
    a b if {![variant_isset sdl]} { 
    446446
    447447}
    448448
    449 variant ctrlport description {Enable control port enhancements (EXPERIMENTAL)} {
    450 # as of commit 2e691d87 (2014-08-08), all CTRLPORT calls are noops
    451 # because of an issue with ICE.  So, allow +ctrlport, but it won't do
    452 # anything until this is fixed.
     449variant ctrlport requires cxx11 description {Enable control port enhancements (EXPERIMENTAL)} {
    453450
    454 # as of commit 621c086b (2015-04-16), CTRLPORT has been moved to using
    455 # thrift, which needs debugging when building on OSX. Just disable
    456 # CTRLPORT for now.
     451    # require Thrift and Python Thrift
    457452
    458     configure.args-append -DENABLE_GR_CTRLPORT=OFF
     453    depends_lib-append \
     454        port:py27-thrift \
     455        port:thrift
     456
     457    # enable configuration arguments for ctrlport and thrift
     458
     459    configure.args-append \
     460        -DENABLE_GR_CTRLPORT=ON \
     461        -DENABLE_CTRLPORT_THRIFT=ON
    459462
    460463}
    461464
    462465if {![variant_isset ctrlport]} {
    463466
    464     configure.args-append -DENABLE_GR_CTRLPORT=OFF
     467    configure.args-append \
     468        -DENABLE_GR_CTRLPORT=OFF \
     469        -DENABLE_CTRLPORT_THRIFT=OFF
    465470
    466471}
    467472
    if {![variant_isset zeromq]} { 
    509514
    510515}
    511516
    512 variant cxx11 description "Compile using C++11" {
     517variant cxx11 description {Compile using C++11} {
    513518
    514519    # require C++11
    515520
    516     configure.cxxflags-append -std=c++11
    517 
    518     if {${configure.cxx_stdlib} eq "libstdc++"} {
    519 
    520         # *clang* when using libstdc++ do not seem to support C++11;
    521         # C++11 support seems to need GCC 4.7+ when using libstdc++;
    522         # could use C++0x support on GCC4.[56], but just ignore it since
    523         # there are newer compilers already in place as defaults.
     521    PortGroup cxx11 1.1
    524522
    525         # Blacklist GCC compilers not supporting C++11 and all CLANG.
    526         # This is probably not necessary, but it's good practice.
    527 
    528         compiler.blacklist-append *clang* {*gcc-3*} {*gcc-4.[0-6]}
    529 
    530         # and whitelist those we do want to use. wish there were a better way.
    531         # these will be used in the order provided.
    532 
    533         compiler.whitelist macports-gcc-4.9 macports-gcc-4.8 macports-gcc-4.7
    534 
    535     } else {
     523    configure.args-append \
     524        -DCMAKE_CXX_STANDARD=11
    536525
    537         # using libc++;
    538         # Blacklist Clang not supporting C++11 in some form and all GCC.
    539         # Just use the cxx11 PortGroup for this specific case.
     526    # temporary define until code is fixed in gr fec
    540527
    541         PortGroup cxx11 1.0
     528    configure.cxxflags-append \
     529        -DBOOST_NO_CXX11_CONSTEXPR \
     530        -std=c++11
    542531
    543     }
    544532}