summaryrefslogtreecommitdiff
path: root/driver_zodiac.c
diff options
context:
space:
mode:
authorGary E. Miller <gem@rellim.com>2016-09-07 03:13:03 +0100
committerGary E. Miller <gem@rellim.com>2016-09-07 03:13:03 +0100
commitcb216cd0ad6f6f0cc51596ead6720082386c84c9 (patch)
tree7ab4796ea00f125c9f8525e70acaed333aa1b53c /driver_zodiac.c
parent5269af1e7b46e5cfa6b17ccf9a40aa1efd0a6cc6 (diff)
downloadgpsd-cb216cd0ad6f6f0cc51596ead6720082386c84c9.tar.gz
Shield FreeBSD from standards compliance.
gpsd now compiles, and runs scons check, with no warnings on FreeBSD.
Diffstat (limited to 'driver_zodiac.c')
-rw-r--r--driver_zodiac.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/driver_zodiac.c b/driver_zodiac.c
index e1ce407e..11a53ed8 100644
--- a/driver_zodiac.c
+++ b/driver_zodiac.c
@@ -10,11 +10,16 @@
* BSD terms apply: see the file COPYING in the distribution root for details.
*/
+#ifdef __linux__
+/* FreeBSD chokes on this */
+/* if we insist on C99, then we need this to get M_LN2 from math.h */
/* if we insisnt on C99, then we need this to get M_LN2 from math.h */
/* 500 means X/Open 1995 */
#define _XOPEN_SOURCE 500
/* round() needs _POSIX_C_SOURCE >= 200112L */
#define _POSIX_C_SOURCE 200112L
+#endif /* __linux__ */
+
#include <stdio.h>
#include <stdbool.h>