git: 3cb0fc7db427 - main - astro/foxtrotgps: fix build with new gpsd
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 14 Mar 2022 00:32:43 UTC
The branch main has been updated by swills:
URL: https://cgit.FreeBSD.org/ports/commit/?id=3cb0fc7db427ed8f2abefaa5ad0f6ae0d9bfb1c4
commit 3cb0fc7db427ed8f2abefaa5ad0f6ae0d9bfb1c4
Author: Steve Wills <swills@FreeBSD.org>
AuthorDate: 2022-03-14 00:16:08 +0000
Commit: Steve Wills <swills@FreeBSD.org>
CommitDate: 2022-03-14 00:31:48 +0000
astro/foxtrotgps: fix build with new gpsd
PR: 258110
Approved by: crwhipp@gmail.com (maintainer)
---
astro/foxtrotgps/Makefile | 1 +
astro/foxtrotgps/files/patch-src_gps__functions.c | 15 ++++++++++++---
2 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/astro/foxtrotgps/Makefile b/astro/foxtrotgps/Makefile
index 1de6e505a57b..478a8604ee22 100644
--- a/astro/foxtrotgps/Makefile
+++ b/astro/foxtrotgps/Makefile
@@ -2,6 +2,7 @@
PORTNAME= foxtrotgps
PORTVERSION= 1.2.2
+PORTREVISION= 1
CATEGORIES= astro geography
MASTER_SITES= http://www.foxtrotgps.org/releases/
diff --git a/astro/foxtrotgps/files/patch-src_gps__functions.c b/astro/foxtrotgps/files/patch-src_gps__functions.c
index 9b41464e09cc..c292f3f582b6 100644
--- a/astro/foxtrotgps/files/patch-src_gps__functions.c
+++ b/astro/foxtrotgps/files/patch-src_gps__functions.c
@@ -1,6 +1,6 @@
---- src/gps_functions.c.orig 2020-03-05 17:21:38 UTC
+--- src/gps_functions.c.orig 2019-07-10 05:35:12 UTC
+++ src/gps_functions.c
-@@ -735,6 +735,11 @@ cb_gpsd_io_error(GIOChannel *src, GIOCondition conditi
+@@ -729,6 +729,11 @@ cb_gpsd_io_error(GIOChannel *src, GIOCondition conditi
}
@@ -12,7 +12,7 @@
static gboolean
cb_gpsd_data(GIOChannel *src, GIOCondition condition, gpointer data)
-@@ -755,7 +760,7 @@ cb_gpsd_data(GIOChannel *src, GIOCondition condition,
+@@ -753,12 +758,16 @@ cb_gpsd_data(GIOChannel *src, GIOCondition condition,
{
gpsdata->satellites_used = libgps_gpsdata.satellites_used;
gpsdata->hdop = libgps_gpsdata.dop.hdop;
@@ -21,3 +21,12 @@
if (isnan(gpsdata->fix.time))
{
gpsdata->fix.time = (time_t) 0;
+ }
++#if GPSD_API_MAJOR_VERSION >= 10
++ gpsdata->valid = (libgps_gpsdata.fix.status != STATUS_UNK);
++#else
+ gpsdata->valid = (libgps_gpsdata.status != STATUS_NO_FIX);
++#endif
+ if (gpsdata->valid)
+ {
+ gpsdata->seen_valid = TRUE;