[merkaartor] 02/05: Add patch to fix libgps22 compatibility.

Sebastiaan Couwenberg sebastic at moszumanska.debian.org
Sun Nov 1 16:09:14 UTC 2015


This is an automated email from the git hooks/post-receive script.

sebastic pushed a commit to branch master
in repository merkaartor.

commit b73541b50feccd81536283209d384bfb271a0e29
Author: Bas Couwenberg <sebastic at xs4all.nl>
Date:   Sun Nov 1 16:06:21 2015 +0100

    Add patch to fix libgps22 compatibility.
---
 debian/changelog              |  1 +
 debian/patches/libgps22.patch | 25 +++++++++++++++++++++++++
 debian/patches/series         |  1 +
 3 files changed, 27 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index 4307190..e6fc255 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,7 @@
 merkaartor (0.18.2-3) UNRELEASED; urgency=medium
 
   * Add upstream metadata.
+  * Add patch to fix libgps22 compatibility.
 
  -- Bas Couwenberg <sebastic at debian.org>  Sun, 01 Nov 2015 12:33:20 +0100
 
diff --git a/debian/patches/libgps22.patch b/debian/patches/libgps22.patch
new file mode 100644
index 0000000..bf737b6
--- /dev/null
+++ b/debian/patches/libgps22.patch
@@ -0,0 +1,25 @@
+Description: Fix gpsdata handling for gpsd >= 3.12 (libgps22 | GPSD_API_MAJOR_VERSION 6)
+Author: Bas Couwenberg <sebastic at debian.org>
+Bug: https://github.com/openstreetmap/merkaartor/issues/76
+Forwarded: https://github.com/openstreetmap/merkaartor/pull/77
+
+--- a/src/GPS/qgpsdevice.cpp
++++ b/src/GPS/qgpsdevice.cpp
+@@ -1056,10 +1056,17 @@ void QGPSDDevice::onDataAvailable()
+         satArray[i][0] = satArray[i][1] = satArray[i][2] = 0;
+     for (int i=0; i<num_sat; ++i)
+     {
++#if GPSD_API_MAJOR_VERSION > 5
++        int id = gpsdata->skyview[i].PRN;
++        satArray[id][0] = gpsdata->skyview[i].elevation;
++        satArray[id][1] = gpsdata->skyview[i].azimuth;
++        satArray[id][2] = gpsdata->skyview[i].ss;
++#else
+         int id = gpsdata->PRN[i];
+         satArray[id][0] = gpsdata->elevation[i];
+         satArray[id][1] = gpsdata->azimuth[i];
+         satArray[id][2] = gpsdata->ss[i];
++#endif
+     }
+     setNumSatellites(num_sat);
+ 
diff --git a/debian/patches/series b/debian/patches/series
index 6bfadc5..c395140 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -8,3 +8,4 @@ various-typos.patch
 hardening-buildflags.patch
 desktop-keywords.patch
 qmake-config-nostrip.patch
+libgps22.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-grass/merkaartor.git



More information about the Pkg-grass-devel mailing list