source: trunk/dports/science/gr-iqbalance/Portfile

Last change on this file was 153036, checked in by michaelld@…, 14 months ago

gr-iqbalance: "${prefix}/Library/Frameworks" -> "${frameworks_dir}".

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.8 KB
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
2# $Id: Portfile 153036 2016-09-22 14:55:40Z ryandesign@macports.org $
3
4PortSystem          1.0
5PortGroup           cmake 1.0
6PortGroup           active_variants 1.1
7
8name                gr-iqbalance
9maintainers         michaelld openmaintainer
10
11description         gr-iqbalance provides I/Q balancing blocks for GNU Radio
12
13categories          science comms
14homepage            http://sdr.osmocom.org/trac/wiki/GrOsmoSDR
15license             GPL-3
16platforms           darwin macosx
17
18long_description    ${description}\
19    This port is kept up with the gr-iqbal GIT 'master' branch, which is typically updated monthly, providing compatibility with GNU Radio release 3.7 API: the gnuradio and gnuradio-devel ports.
20
21set commit          44ab02f671dbc8765391a83d8186779fbb38baea
22version             20140825
23revision            7
24checksums           rmd160 8ec7b22e2ac37c972c4f7df187f66830ab38cb1e \
25                    sha256 e2c8f0ecc97eaebdf0178a5375181c957484c02985c8e3d018dac1cc14567232
26
27distname            gr-iqbal-${commit}
28master_sites        http://cgit.osmocom.org/gr-iqbal/snapshot/
29
30conflicts           gr-iqbalance-legacy
31
32# allow gr-iqbalance to work with both gnuradio and gnuradio-devel ...
33
34depends_lib-append  path:lib/libgnuradio-runtime.dylib:gnuradio
35
36# ... but not with gnuradio-next
37
38pre-fetch {
39    if {![catch {set installed [lindex [registry_active gnuradio-next] 0]}]} {
40        # gnuradio-next is installed; this version of gr-osmosdr does not work with gnuradio-next
41        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"
42        return -code error "Invalid port dependency: gnuradio-next"
43    }
44}
45
46livecheck.url       http://cgit.osmocom.org/gr-iqbal/log/?h=master
47livecheck.version   ${commit}
48livecheck.regex     id=(\[a-f0-9\]+).*>HEAD<
49
50depends_build-append port:pkgconfig
51
52depends_lib-append  port:boost \
53                    port:libosmo-dsp \
54                    port:fftw-3-single
55
56# do VPATH (out of source tree) build
57
58cmake.out_of_source yes
59
60# remove top-level library path, such that internal libraries are used
61# instead of any already-installed ones.
62
63configure.ldflags-delete -L${prefix}/lib
64
65# specify the Python dependencies
66
67depends_lib-append \
68    port:python27
69
70# specify the Python version to use
71
72configure.args-append \
73    -DPYTHON_EXECUTABLE=${frameworks_dir}/Python.framework/Versions/2.7/bin/python2.7 \
74    -DPYTHON_INCLUDE_DIR=${frameworks_dir}/Python.framework/Versions/2.7/Headers \
75    -DPYTHON_LIBRARY=${frameworks_dir}/Python.framework/Versions/2.7/Python \
76    -DGR_PYTHON_DIR=${frameworks_dir}/Python.framework/Versions/2.7/lib/python2.7/site-packages
77
78# per user concensus: enable all variants except +debug and +universal
79
80default_variants +docs +swig
81
82variant docs description "Install ${name} documentation" {
83
84    depends_build-append \
85        port:doxygen \
86        path:bin/dot:graphviz
87
88    configure.args-append \
89        -DDOXYGEN_DOT_EXECUTABLE=${prefix}/bin/dot \
90        -DDOXYGEN_EXECUTABLE=${prefix}/bin/doxygen
91
92}
93
94if {![variant_isset docs]} {
95
96    configure.args-append \
97        -DDOXYGEN_DOT_EXECUTABLE= \
98        -DDOXYGEN_EXECUTABLE=
99
100}
101
102variant swig description "Install ${name} with support for SWIG-base Python bindings" {
103
104    depends_lib-append \
105        port:swig-python
106
107    # require gnuradio to also have this variant
108
109    if {${subport} eq "gr-osmosdr-legacy"} {
110
111        require_active_variants port:gnuradio-legacy swig
112
113    } else {
114
115        require_active_variants \
116            path:lib/libgnuradio-runtime.dylib:gnuradio swig
117
118    }
119
120    configure.args-append \
121        -DSWIG_EXECUTABLE=${prefix}/bin/swig
122
123}
124
125if {![variant_isset swig]} {
126
127    configure.args-append \
128        -DSWIG_EXECUTABLE=
129
130}
Note: See TracBrowser for help on using the repository browser.