[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gpsd-dev] Build fix for nptshm=False
From: |
José Miguel Gonçalves |
Subject: |
[gpsd-dev] Build fix for nptshm=False |
Date: |
Sat, 14 Apr 2012 20:23:03 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:11.0) Gecko/20120329 Thunderbird/11.0.1 |
Latest git head does not build if ntpshm=False.
This patch fixes it:
diff --git a/gpsd.h-tail b/gpsd.h-tail
index 1c51846..82385e6 100644
--- a/gpsd.h-tail
+++ b/gpsd.h-tail
@@ -217,12 +217,12 @@ struct gps_context_t {
/* timekeeping */
time_t start_time; /* local time of daemon startup */
int leap_seconds; /* Unix seconds to UTC (GPS-UTC
offset) */
- int leap_notify; /* notification state from
subframe */
unsigned short gps_week; /* GPS week, actually 10 bits */
double gps_tow; /* GPS time of week, actually
19 bits */
int century; /* for NMEA-only devices
without ZDA */
int rollovers; /* rollovers since start of run */
#ifdef NTPSHM_ENABLE
+ int leap_notify; /* notification state from
subframe */
bool enable_ntpshm;
/* we need the volatile here to tell the C compiler not to
* 'optimize' as 'dead code' the writes to SHM */
diff --git a/libgpsd_core.c b/libgpsd_core.c
index 93cb330..efe83b9 100644
--- a/libgpsd_core.c
+++ b/libgpsd_core.c
@@ -103,12 +103,12 @@ void gps_context_init(struct gps_context_t *context)
.fixcnt = 0,
.start_time = 0,
.leap_seconds = 0,
- .leap_notify = LEAP_NOWARNING,
.gps_week = 0,
.gps_tow = 0,
.century = 0,
.rollovers = 0,
#ifdef NTPSHM_ENABLE
+ .leap_notify = LEAP_NOWARNING,
.enable_ntpshm = false,
.shmTime = {0},
.shmTimeInuse = {0},
José Gonçalves
- [gpsd-dev] Build fix for nptshm=False,
José Miguel Gonçalves <=