summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGary E. Miller <gem@rellim.com>2018-11-21 13:42:56 -0800
committerGary E. Miller <gem@rellim.com>2018-11-21 13:42:56 -0800
commit0cee473cfdf69d0286b6a45bbf72d9fe925e0ad6 (patch)
tree1bfeecc135bce83623d4f0808b5cd25744669e6d
parent0a0fa20a52b4a6be516500885e80c75b27448b07 (diff)
downloadgpsd-0cee473cfdf69d0286b6a45bbf72d9fe925e0ad6.tar.gz
gpsrinex: Ubuntu needs to be told time is past 2001.
-rw-r--r--gpsrinex.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/gpsrinex.c b/gpsrinex.c
index 60430957..14348f7d 100644
--- a/gpsrinex.c
+++ b/gpsrinex.c
@@ -59,6 +59,14 @@
*
*/
+#ifdef __linux__
+/* isfinite() needs _POSIX_C_SOURCE >= 200112L
+ * isnan(+Inf) is false, isfinite(+Inf) is false
+ * use isfinite() to make sure a float is valid
+ */
+#define _POSIX_C_SOURCE 200112L
+#endif /* __linux__ */
+
#ifndef _XOPEN_SOURCE
/* need >= 500 for strdup() */
#define _XOPEN_SOURCE 500