Commit | Line | Data |
---|---|---|
83aabfbc | 1 | ;;; GNU Guix --- Functional package management for GNU |
ce0614dd | 2 | ;;; Copyright © 2014, 2015 Ludovic Courtès <ludo@gnu.org> |
f13f02f8 | 3 | ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il> |
7b6eabc7 | 4 | ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr> |
53655964 | 5 | ;;; Copyright © 2018 Mathieu Othacehe <m.othacehe@gmail.com> |
74c65c9d | 6 | ;;; Copyright © 2020 Guillaume Le Vaillant <glv@posteo.net> |
859e042a | 7 | ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com> |
83aabfbc LC |
8 | ;;; |
9 | ;;; This file is part of GNU Guix. | |
10 | ;;; | |
11 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
12 | ;;; under the terms of the GNU General Public License as published by | |
13 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
14 | ;;; your option) any later version. | |
15 | ;;; | |
16 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
17 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
18 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
19 | ;;; GNU General Public License for more details. | |
20 | ;;; | |
21 | ;;; You should have received a copy of the GNU General Public License | |
22 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
23 | ||
24 | (define-module (gnu packages gps) | |
25 | #:use-module (guix packages) | |
26 | #:use-module (guix download) | |
3b239720 | 27 | #:use-module (guix git-download) |
83aabfbc | 28 | #:use-module (guix build-system gnu) |
74c65c9d | 29 | #:use-module (guix build-system scons) |
83aabfbc | 30 | #:use-module ((guix licenses) #:prefix license:) |
8ee8eb26 | 31 | #:use-module (guix utils) |
924b96db | 32 | #:use-module (gnu packages) |
8ee8eb26 | 33 | #:use-module (gnu packages algebra) |
ce0614dd | 34 | #:use-module (gnu packages base) |
83aabfbc | 35 | #:use-module (gnu packages compression) |
3b239720 | 36 | #:use-module (gnu packages docbook) |
74c65c9d | 37 | #:use-module (gnu packages glib) |
3b239720 | 38 | #:use-module (gnu packages gtk) |
74c65c9d GLV |
39 | #:use-module (gnu packages image) |
40 | #:use-module (gnu packages libusb) | |
41 | #:use-module (gnu packages linux) | |
42 | #:use-module (gnu packages ncurses) | |
43 | #:use-module (gnu packages pkg-config) | |
44 | #:use-module (gnu packages python) | |
8ee8eb26 | 45 | #:use-module (gnu packages python-xyz) |
cd0322a3 | 46 | #:use-module (gnu packages qt) |
74c65c9d GLV |
47 | #:use-module (gnu packages sqlite) |
48 | #:use-module (gnu packages xml)) | |
83aabfbc LC |
49 | |
50 | (define-public gpsbabel | |
51 | (package | |
52 | (name "gpsbabel") | |
924b96db | 53 | (version "1.5.4") |
83aabfbc LC |
54 | (source (origin |
55 | (method url-fetch) | |
56 | ;; XXX: Downloads from gpsbabel.org are hidden behind a POST, so | |
57 | ;; get it from elsewhere. | |
58 | (uri (string-append | |
59 | "mirror://debian/pool/main/g/gpsbabel/gpsbabel_" | |
60 | version ".orig.tar.gz")) | |
61 | (sha256 | |
62 | (base32 | |
924b96db MO |
63 | "19hykxhyl567gf8qcrl33qhv95w0g4vxw9r3h9b8d8plx9bnaf8l")) |
64 | (patches (search-patches | |
65 | "gpsbabel-minizip.patch" | |
66 | ;; XXX: Remove this patch on the next release. | |
67 | "gpsbabel-qstring.patch")) | |
03392caa | 68 | (modules '((guix build utils))) |
6d2ff645 TGR |
69 | (snippet |
70 | '(begin | |
71 | ;; Delete files under GPL-compatible licences but never used | |
72 | ;; on GNU systems, rather than bloating the LICENSE field. | |
924b96db MO |
73 | (delete-file "gui/serial_mac.cc") ; Apple MIT |
74 | (delete-file "mingw/include/ddk/hidsdi.h") ; public domain | |
6d2ff645 | 75 | #t)))) |
83aabfbc | 76 | (build-system gnu-build-system) |
924b96db | 77 | ;; TODO: "make doc" requires Docbook & co. |
83aabfbc | 78 | (arguments |
15354d86 | 79 | `(#:configure-flags |
cfad3def | 80 | '("--with-zlib=system") |
82350397 LC |
81 | ;; On i686, 'raymarine.test' fails because of a rounding error: |
82 | ;; <http://hydra.gnu.org/build/133040>. As a workaround, disable tests | |
83 | ;; on these platforms. | |
15354d86 DC |
84 | ;; FIXME: On x86_64 with -std=gnu++11 tests also fail due to rounding |
85 | ;; error. | |
86 | #:tests? #f)) | |
83aabfbc LC |
87 | (inputs |
88 | `(("expat" ,expat) | |
89 | ("zlib" ,zlib) | |
859e042a | 90 | ("qtbase" ,qtbase))) |
83aabfbc LC |
91 | (native-inputs |
92 | `(("which" ,which) | |
859e042a | 93 | ("qttools" ,qttools) |
83aabfbc | 94 | ("libxml2" ,libxml2))) ;'xmllint' needed for the KML tests |
facee794 | 95 | (home-page "https://www.gpsbabel.org/") |
83aabfbc LC |
96 | (synopsis "Convert and exchange data with GPS and map programs") |
97 | (description | |
98 | "GPSBabel converts waypoints, tracks, and routes between hundreds of | |
99 | popular GPS receivers and mapping programs. It contains extensive data | |
100 | manipulation abilities making it a convenient for server-side processing or as | |
101 | the back-end for other tools. It does not convert, transfer, send, or | |
102 | manipulate maps.") | |
6d2ff645 TGR |
103 | (license (list license:expat ; shapelib/*.[ch] |
104 | license:gpl2+)))) ; everything else | |
3b239720 LC |
105 | |
106 | (define-public gpscorrelate | |
107 | ;; This program is "lightly maintained", so to speak, so we end up taking it | |
108 | ;; directly from its Git repo. | |
109 | (let ((commit "365f6e1b3f")) | |
110 | (package | |
111 | (name "gpscorrelate") | |
112 | (version (string-append "1.6.1." commit)) | |
113 | (source (origin | |
114 | (method git-fetch) | |
115 | (uri (git-reference | |
2508b075 | 116 | (url "https://github.com/dfandrich/gpscorrelate") |
3b239720 | 117 | (commit commit))) |
87d868cc | 118 | (file-name (git-file-name name version)) |
3b239720 LC |
119 | (sha256 |
120 | (base32 | |
121 | "006a6l8p38a4h7y2959sqrmjjn29d8pd50zj9nypcp5ph18nybjb")))) | |
122 | (build-system gnu-build-system) | |
123 | (arguments | |
dc1d3cde KK |
124 | `(#:phases |
125 | (modify-phases %standard-phases | |
126 | (replace 'configure | |
127 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
128 | ;; This is a rudimentary build system. | |
129 | (substitute* "Makefile" | |
130 | (("prefix[[:blank:]]*=.*$") | |
131 | (string-append "prefix = " (assoc-ref outputs "out") | |
132 | "\n"))) | |
133 | #t))) | |
3b239720 LC |
134 | #:tests? #f)) |
135 | (inputs | |
136 | `(("gtk+" ,gtk+-2) | |
137 | ("libxml2" ,libxml2) | |
138 | ("exiv2" ,exiv2))) | |
139 | (native-inputs | |
140 | `(("pkg-config" ,pkg-config) | |
141 | ("docbook-xml" ,docbook-xml) | |
142 | ("docbook-xsl" ,docbook-xsl) | |
143 | ("libxslt" ,libxslt))) | |
2508b075 | 144 | (home-page "https://dfandrich.github.io/gpscorrelate/") |
3b239720 LC |
145 | (synopsis "GPS photo correlation tool to geo-localize images") |
146 | (description | |
147 | "GPS Correlate is a program to match a recorded GPS track with the EXIF | |
148 | tags in digital camera photos, and update the EXIF tags with the location that | |
149 | the photo was taken. It does this by using the timestamp in the photo and | |
150 | finding a data point in the GPS track that matches, or interpolating a point | |
151 | between two other data points.") | |
152 | (license license:gpl2+)))) | |
b200ecde EF |
153 | |
154 | (define-public gama | |
155 | (package | |
156 | (name "gama") | |
f13f02f8 | 157 | (version "2.08") |
b200ecde EF |
158 | (source |
159 | (origin | |
160 | (method url-fetch) | |
161 | (uri (string-append "mirror://gnu/gama/gama-" | |
162 | version ".tar.gz")) | |
163 | (sha256 | |
164 | (base32 | |
f13f02f8 | 165 | "0fic6a3a83hgj3gj85bin3wd6ghgi2qg76d6jfwckamab0hlv7wx")))) |
b200ecde EF |
166 | (build-system gnu-build-system) |
167 | (arguments '(#:parallel-tests? #f)) ; race condition | |
168 | (native-inputs | |
169 | `(("libxml2" ,libxml2))) | |
170 | (inputs | |
171 | `(("expat" ,expat) | |
172 | ("sqlite" ,sqlite))) | |
173 | (home-page "https://www.gnu.org/software/gama") | |
174 | (synopsis "Adjustment of geodetic networks") | |
175 | (description | |
176 | "GNU Gama is a program for the adjustment of geodetic networks. It is | |
177 | useful in measurements where Global Positioning System (GPS) is not available, | |
178 | such as underground. It features the ability to adjust in local Cartesian | |
179 | coordinates as well as partial support for adjustments in global coordinate systems.") | |
180 | (license license:gpl3+))) | |
53655964 MO |
181 | |
182 | (define-public gpxsee | |
183 | (package | |
184 | (name "gpxsee") | |
3437fe1f | 185 | (version "7.25") |
53655964 | 186 | (source (origin |
ed8a5516 LC |
187 | (method git-fetch) |
188 | (uri (git-reference | |
189 | (url "https://github.com/tumic0/GPXSee") | |
190 | (commit version))) | |
191 | (file-name (git-file-name name version)) | |
53655964 MO |
192 | (sha256 |
193 | (base32 | |
3437fe1f | 194 | "0lml3hz2zxljl9j5wnh7bn9bj8k9v3wf6bk3g77x9nnarsmw0fcx")))) |
53655964 MO |
195 | (build-system gnu-build-system) |
196 | (arguments | |
197 | '(#:phases | |
198 | (modify-phases %standard-phases | |
199 | (replace 'configure | |
200 | ;; Use lrelease to convert TS translation files into QM files. | |
201 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
202 | (for-each (lambda (file) | |
d64b79fa | 203 | (invoke "lrelease" file)) |
53655964 | 204 | (find-files "lang" "\\.ts")) |
53655964 MO |
205 | (invoke "qmake" |
206 | (string-append "PREFIX=" | |
286ef5d9 | 207 | (assoc-ref outputs "out")))))))) |
53655964 MO |
208 | (inputs |
209 | `(("qtbase" ,qtbase))) | |
210 | (native-inputs | |
211 | `(("qttools" ,qttools))) | |
286ef5d9 NK |
212 | (home-page "https://www.gpxsee.org") |
213 | (synopsis "GPS log file viewer and analyzer") | |
53655964 | 214 | (description |
cebfc269 TGR |
215 | "GPXSee is a Qt-based GPS log file viewer and analyzer that supports all |
216 | common GPS log file formats. It can display multiple tracks on various on- | |
217 | and off-line maps. You can easily add more maps and graph other captured data | |
218 | such as elevation, speed, heart rate, power, temperature, and gear shifts.") | |
53655964 | 219 | (license license:gpl3))) |
74c65c9d GLV |
220 | |
221 | (define-public gpsd | |
222 | (package | |
223 | (name "gpsd") | |
24f4263d | 224 | (version "3.20") |
74c65c9d GLV |
225 | (source |
226 | (origin | |
227 | (method url-fetch) | |
228 | (uri (string-append "https://download-mirror.savannah.gnu.org" | |
229 | "/releases/gpsd/gpsd-" version ".tar.gz")) | |
230 | (sha256 | |
24f4263d | 231 | (base32 "0l2yz0yw9sil82lh2l4swkkldgmhzhv588n5lcavib4f0q2phahp")))) |
74c65c9d GLV |
232 | (build-system scons-build-system) |
233 | (native-inputs | |
8ee8eb26 GLV |
234 | `(("bc" ,bc) |
235 | ("pkg-config" ,pkg-config))) | |
74c65c9d GLV |
236 | (inputs |
237 | `(("bluez" ,bluez) | |
238 | ("dbus" ,dbus) | |
24f4263d | 239 | ("gtk+" ,gtk+) |
74c65c9d GLV |
240 | ("libcap" ,libcap) |
241 | ("libusb" ,libusb) | |
8ee8eb26 GLV |
242 | ("ncurses" ,ncurses) |
243 | ("python" ,python) | |
244 | ("python-pycairo" ,python-pycairo) | |
245 | ("python-pygobject" ,python-pygobject) | |
246 | ("python-pyserial" ,python-pyserial) | |
247 | ("python-wrapper" ,python-wrapper) | |
248 | ("qtbase" ,qtbase))) | |
74c65c9d | 249 | (arguments |
8ee8eb26 GLV |
250 | `(#:scons-flags |
251 | (list (string-append "prefix=" %output) | |
252 | (let ((version ,(version-major+minor (package-version python)))) | |
253 | (string-append "python_libdir=" %output | |
254 | "/lib/python" version | |
255 | "/site-packages")) | |
256 | "qt_versioned=5") | |
74c65c9d GLV |
257 | #:phases |
258 | (modify-phases %standard-phases | |
8ee8eb26 GLV |
259 | (add-after 'unpack 'fix-build |
260 | (lambda* (#:key outputs #:allow-other-keys) | |
74c65c9d | 261 | (substitute* "SConstruct" |
8ee8eb26 GLV |
262 | (("envs = \\{\\}") |
263 | "envs = os.environ")) | |
264 | #t)) | |
265 | (add-after 'install 'wrap-python-scripts | |
266 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
267 | (let* ((out (assoc-ref outputs "out")) | |
268 | (pycairo (assoc-ref inputs "python-pycairo")) | |
269 | (pygobject (assoc-ref inputs "python-pygobject")) | |
270 | (pyserial (assoc-ref inputs "python-pyserial")) | |
271 | (sitedir (lambda (package) | |
272 | (string-append package | |
273 | "/lib/python" | |
274 | ,(version-major+minor | |
275 | (package-version python)) | |
276 | "/site-packages"))) | |
277 | (pythonpath (string-join (map sitedir | |
278 | (list out pycairo pygobject | |
279 | pyserial)) | |
280 | ":"))) | |
281 | (for-each (lambda (script) | |
282 | (wrap-program (string-append out "/bin/" script) | |
283 | `("PYTHONPATH" ":" prefix (,pythonpath)))) | |
284 | '("gegps" "gpscat" "gpsfake" "gpsprof" | |
285 | "ubxtool" "xgps" "xgpsspeed" "zerk"))) | |
74c65c9d GLV |
286 | #t))))) |
287 | (synopsis "GPS service daemon") | |
288 | (description | |
289 | "@code{gpsd} is a service daemon that monitors one or more GPSes or AIS | |
290 | receivers attached to a host computer through serial or USB ports, making all | |
291 | data on the location/course/velocity of the sensors available to be queried on | |
292 | TCP port 2947 of the host computer.") | |
293 | (home-page "https://gpsd.gitlab.io/gpsd/") | |
294 | (license license:bsd-2))) |