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

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

gnss-sdr-next: update to d8737601 (20151027).

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 7.0 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 141793 2015-10-28 19:43:47Z 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    checksums           rmd160 3a578f4795f6230d3f627dbe6f80f77c7dac206e \
26                        sha256 ed81a5dff8d91b0b1d561ab8a240818da447c8358b95ab42d6a17b479e873c3e
27    github.tarball_from tags
28
29    conflicts           gnss-sdr-devel gnss-sdr-next
30
31    depends_lib-append  port:gnuradio
32
33    require_active_variants port:gnuradio uhd
34
35    # temporary patch to fix Volk #define in compatibility
36
37    patchfiles-append patch-volk.diff
38
39    # temporary patch; will be fixed in next release.
40
41    post-patch {
42        reinplace "s@multithread@opencl@g" ${worksrcpath}/src/algorithms/acquisition/gnuradio_blocks/pcps_opencl_acquisition_cc.cc
43    }
44
45}
46
47subport gnss-sdr-devel {
48
49    long_description    ${description}: \
50        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.
51
52    name                gnss-sdr-devel
53    github.setup        gnss-sdr gnss-sdr df6bd17bd844cddf46ce3f7e2a86fcde4a5eb24b
54    version             20151025
55    checksums           rmd160 022cdccaf466d7c5cd43e4fd0ba201400eda9d0e \
56                        sha256 0808ecf6e17bf8e2b52f19bfd0c472f18c5a8718d5a665574c052c0a06452789
57
58    conflicts           gnss-sdr gnss-sdr-next
59
60    depends_lib-append  port:gnuradio-devel
61
62    require_active_variants port:gnuradio-devel uhd
63
64}
65
66subport gnss-sdr-next {
67    long_description    ${description}: \
68        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.
69
70    name                gnss-sdr-next
71    github.setup        gnss-sdr gnss-sdr d873760142da15c6738034e1e130ace1285eb451
72    version             20151027
73    checksums           rmd160 b7c15502b30416e1d41ac62eb3d2912ee3c2e3c4 \
74                        sha256 01e9cc9b32f9ae8e9c4f9249d64d6cca96b2f4ac701ae9831f1a897f97ce3bf9
75
76    conflicts           gnss-sdr gnss-sdr-devel
77
78    depends_lib-append  port:gnuradio-next
79
80    require_active_variants port:gnuradio-next uhd
81
82}
83
84# override githib PortGroup homepage setting
85
86homepage            http://gnss-sdr.org
87
88depends_build-append port:pkgconfig
89
90depends_lib-append  \
91    port:armadillo \
92    port:google-glog \
93    port:orc \
94    path:lib/libuhd.dylib:uhd \
95    port:py27-cheetah
96
97# release uses openssl while delve and next use gnutls;
98# next release update to just gnutls.
99
100if {${subport} eq "gnss-sdr"} {
101    depends_lib-append  path:lib/libssl.dylib:openssl
102} else {
103    depends_lib-append  port:gnutls
104}
105
106# require specific variants
107
108require_active_variants port:google-glog gflags
109
110# do VPATH (out of source tree) build
111
112cmake.out_of_source yes
113
114# remove top-level library path, such that internal libraries are used
115# instead of any already-installed ones.
116
117configure.ldflags-delete -L${prefix}/lib
118
119configure.args-append \
120    -DENABLE_PACKAGING=OFF \
121    -DENABLE_OWN_GLOG=OFF \
122    -DENABLE_GENERIC_ARCH=OFF
123
124# enable default variants: all except +docs, +debug, and +universal
125# do not enable +docs because it requires a non-standard variant for doxygen.
126
127default_variants +opencl
128
129# release and devel can use use gr-osmosdr, while next can't
130# (because gr-osmosdr can't use gnuradio-next)
131
132if {${subport} ne "gnss-sdr-next"} {
133    default_variants +osmosdr
134}
135
136variant docs description "Install ${name} documentation" {
137
138    depends_build-append \
139        port:doxygen
140
141    # for wasysym.sty
142
143    depends_build-append \
144        port:texlive-fonts-recommended
145
146    # require specific variant
147
148    require_active_variants port:doxygen latex
149
150    configure.args-append \
151        -DDOXYGEN_EXECUTABLE=${prefix}/bin/doxygen
152
153    # extra targets
154
155    build.target-append doc pdfmanual
156
157}
158
159if {![variant_isset docs]} {
160
161    configure.args-append \
162        -DDOXYGEN_EXECUTABLE=
163
164}
165
166variant opencl description "Install ${name} with support for building of processing blocks implemented with OpenCL (experimental)" {
167
168    configure.args-append \
169        -DENABLE_OPENCL=ON
170
171}
172
173if {![variant_isset opencl]} {
174
175    configure.args-append \
176        -DENABLE_OPENCL=OFF
177
178}
179
180variant 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." {
181
182    if {${subport} ne "gnss-sdr-next"} {
183
184        depends_build-append \
185            port:gr-osmosdr
186
187        configure.args-append \
188            -DENABLE_OSMOSDR=ON
189
190    } else {
191
192        ui_error "$subport variant +osmosdr is not viable because port:gr-osmosdr cannot use port:gnuradio-next."
193        error "unsupported variant"
194
195    }
196}
197
198if {![variant_isset osmosdr]} {
199    if {${subport} ne "gnss-sdr-next"} {
200        configure.args-append \
201            -DENABLE_OSMOSDR=OFF
202    }
203}
204
205variant array description "Install ${name} with support for CTTC's antenna array front-end as signal source (experimental)" {
206
207    configure.args-append \
208        -DENABLE_ARRAY=ON
209
210}
211
212if {![variant_isset array]} {
213
214    configure.args-append \
215        -DENABLE_ARRAY=OFF
216
217}
218
219variant gn3s description "Install ${name} with support for the GN3S dongle as signal source (experimental)" {
220
221    configure.args-append \
222        -DENABLE_GN3S=ON
223
224}
225
226if {![variant_isset gn3s]} {
227
228    configure.args-append \
229        -DENABLE_GN3S=OFF
230
231}
Note: See TracBrowser for help on using the repository browser.