source: trunk/dports/science/gnss-sdr/Portfile @ 142108

Last change on this file since 142108 was 142108, checked in by michaelld@…, 4 years ago

gnss-sdr*:
+ use new volk-gnss-sdr* ports;
+ add overall dependnecy on boost;
+ rev bump for changes.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 7.1 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 142108 2015-11-03 19:54:49Z michaelld@macports.org $
3
4PortSystem          1.0
5
6PortGroup           cmake 1.0
7PortGroup           github 1.0
8PortGroup           active_variants 1.1
9
10name                gnss-sdr
11maintainers         michaelld gmail.com:carlesfernandez openmaintainer
12description         An Open Source Global Navigation Satellite Systems (GNSS)(for example: GPS, Galileo, Glonass, Beidou, etc) Software Defined Radio (SDR) Receiver
13categories          science
14license             GPL-3
15platforms           darwin
16
17dist_subdir         gnss-sdr
18
19if {${subport} eq "gnss-sdr"} {
20
21    long_description    ${description}: \
22        This port is kept up with the GNSS-SDR release, which is typically updated every few months. This version compiles against the gnuradio port, which represents the current GNU Radio release.
23
24    github.setup        gnss-sdr gnss-sdr 0.0.6 v
25    revision            1
26    checksums           rmd160 3a578f4795f6230d3f627dbe6f80f77c7dac206e \
27                        sha256 ed81a5dff8d91b0b1d561ab8a240818da447c8358b95ab42d6a17b479e873c3e
28    github.tarball_from tags
29
30    conflicts           gnss-sdr-devel gnss-sdr-next
31
32    depends_lib-append  port:gnuradio port:volk-gnss-sdr
33
34    require_active_variants port:gnuradio uhd
35
36    # temporary patch to fix Volk #define in compatibility
37
38    patchfiles-append patch-volk.diff
39
40    # temporary patch; will be fixed in next release.
41
42    post-patch {
43        reinplace "s@multithread@opencl@g" ${worksrcpath}/src/algorithms/acquisition/gnuradio_blocks/pcps_opencl_acquisition_cc.cc
44    }
45
46}
47
48subport gnss-sdr-devel {
49
50    long_description    ${description}: \
51        This port is kept up with the GNSS-SDR GIT master branch, which is typically updated daily to weekly.  This version of GNSS-SDR generally contains fixes and new features that will be incorporated in an upcoming release, and compiles against the gnuradio-devel port, which represents GNU Radio GIT master branch.  This port may or not compile or function correctly, as it represents a work in progress.  If it does not work, check back in a few days.  Or try deactivating the currently active gnss-sdr and gnuradio ports, cleaning any current builds, and trying again.
52
53    name                gnss-sdr-devel
54    github.setup        gnss-sdr gnss-sdr df6bd17bd844cddf46ce3f7e2a86fcde4a5eb24b
55    version             20151025
56    revision            1
57    checksums           rmd160 022cdccaf466d7c5cd43e4fd0ba201400eda9d0e \
58                        sha256 0808ecf6e17bf8e2b52f19bfd0c472f18c5a8718d5a665574c052c0a06452789
59
60    conflicts           gnss-sdr gnss-sdr-next
61
62    depends_lib-append  port:gnuradio-devel port:volk-gnss-sdr-devel
63
64    require_active_variants port:gnuradio-devel uhd
65
66}
67
68subport gnss-sdr-next {
69    long_description    ${description}: \
70        This port is kept up with the GNSS-SDR GIT next branch, which is typically updated daily to weekly.  This version of GNSS-SDR generally contains fixes and new features that will be incorporated in an upcoming release, and compiles against the gnuradio-next port, which represents GNU Radio GIT next branch.  This port may or not compile or function correctly, as it represents a work in progress.  If it does not work, check back in a few days.  Or try deactivating the currently active gnss-sdr and gnuradio ports, cleaning any current builds, and trying again.
71
72    name                gnss-sdr-next
73    github.setup        gnss-sdr gnss-sdr db4d55db6227cb220499ef1431f79cfbbf48b469
74    version             20151101
75    revision            1
76    checksums           rmd160 a362905eab0ce835ae9acaeabf5d5f46e72289a9 \
77                        sha256 bc3be18d87cc2de812ba4ee3f00e9c27052e99fe2b2e3905236ce236522448da
78
79    conflicts           gnss-sdr gnss-sdr-devel
80
81    depends_lib-append  port:gnuradio-next port:volk-gnss-sdr-next
82
83    require_active_variants port:gnuradio-next uhd
84
85}
86
87# override githib PortGroup homepage setting
88
89homepage            http://gnss-sdr.org
90
91depends_build-append port:pkgconfig
92
93depends_lib-append  \
94    port:armadillo \
95    port:google-glog \
96    path:lib/libuhd.dylib:uhd \
97    port:py27-cheetah \
98    port:boost
99
100# release uses openssl while delve and next use gnutls;
101# next release update to just gnutls.
102
103if {${subport} eq "gnss-sdr"} {
104    depends_lib-append  path:lib/libssl.dylib:openssl
105} else {
106    depends_lib-append  port:gnutls
107}
108
109# require specific variants
110
111require_active_variants port:google-glog gflags
112
113# do VPATH (out of source tree) build
114
115cmake.out_of_source yes
116
117# remove top-level library path, such that internal libraries are used
118# instead of any already-installed ones.
119
120configure.ldflags-delete -L${prefix}/lib
121
122configure.args-append \
123    -DENABLE_PACKAGING=OFF \
124    -DENABLE_OWN_GLOG=OFF \
125    -DENABLE_GENERIC_ARCH=OFF
126
127# enable default variants: all except +docs, +debug, and +universal
128# do not enable +docs because it requires a non-standard variant for doxygen.
129
130default_variants +opencl
131
132# release and devel can use use gr-osmosdr, while next can't
133# (because gr-osmosdr can't use gnuradio-next)
134
135if {${subport} ne "gnss-sdr-next"} {
136    default_variants +osmosdr
137}
138
139variant docs description "Install ${name} documentation" {
140
141    depends_build-append \
142        port:doxygen
143
144    # for wasysym.sty
145
146    depends_build-append \
147        port:texlive-fonts-recommended
148
149    # require specific variant
150
151    require_active_variants port:doxygen latex
152
153    configure.args-append \
154        -DDOXYGEN_EXECUTABLE=${prefix}/bin/doxygen
155
156    # extra targets
157
158    build.target-append doc pdfmanual
159
160}
161
162if {![variant_isset docs]} {
163
164    configure.args-append \
165        -DDOXYGEN_EXECUTABLE=
166
167}
168
169variant opencl description "Install ${name} with support for building of processing blocks implemented with OpenCL (experimental)" {
170
171    configure.args-append \
172        -DENABLE_OPENCL=ON
173
174}
175
176if {![variant_isset opencl]} {
177
178    configure.args-append \
179        -DENABLE_OPENCL=OFF
180
181}
182
183variant osmosdr description "Install ${name} with support for OsmoSDR and other front-ends (RTL-based dongles, HackRF, bladeRF, etc.) as signal source (experimental). NOTE: Does not work with gnss-sdr-next." {
184
185    if {${subport} ne "gnss-sdr-next"} {
186
187        depends_build-append \
188            port:gr-osmosdr
189
190        configure.args-append \
191            -DENABLE_OSMOSDR=ON
192
193    } else {
194
195        ui_error "$subport variant +osmosdr is not viable because port:gr-osmosdr cannot use port:gnuradio-next."
196        error "unsupported variant"
197
198    }
199}
200
201if {![variant_isset osmosdr]} {
202    if {${subport} ne "gnss-sdr-next"} {
203        configure.args-append \
204            -DENABLE_OSMOSDR=OFF
205    }
206}
207
208variant array description "Install ${name} with support for CTTC's antenna array front-end as signal source (experimental)" {
209
210    configure.args-append \
211        -DENABLE_ARRAY=ON
212
213}
214
215if {![variant_isset array]} {
216
217    configure.args-append \
218        -DENABLE_ARRAY=OFF
219
220}
221
222variant gn3s description "Install ${name} with support for the GN3S dongle as signal source (experimental)" {
223
224    configure.args-append \
225        -DENABLE_GN3S=ON
226
227}
228
229if {![variant_isset gn3s]} {
230
231    configure.args-append \
232        -DENABLE_GN3S=OFF
233
234}
Note: See TracBrowser for help on using the repository browser.