summaryrefslogtreecommitdiff
path: root/gpsd.c
diff options
context:
space:
mode:
authorGary E. Miller <gem@rellim.com>2018-02-13 14:33:02 -0800
committerGary E. Miller <gem@rellim.com>2018-02-13 14:33:02 -0800
commit8138b291d064af5dc194d089ae99edcdf9fa540c (patch)
tree02017a9ca64b15dfdea201408cf96e6c5070a80e /gpsd.c
parenta34a766c689d2910935f26b9e4f9d4801903623b (diff)
downloadgpsd-8138b291d064af5dc194d089ae99edcdf9fa540c.tar.gz
isfinite(): Another try at getting Ubuntu to see isfinite()
Their man page says _POSIX_C_SOURCE >= 200112L should work. It did not.
Diffstat (limited to 'gpsd.c')
-rw-r--r--gpsd.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/gpsd.c b/gpsd.c
index a6251b93..8ec8b571 100644
--- a/gpsd.c
+++ b/gpsd.c
@@ -9,7 +9,8 @@
#ifdef __linux__
/* FreeBSD chokes on this */
/* nice() needs _XOPEN_SOURCE, 500 means X/Open 1995 */
-#define _XOPEN_SOURCE 500
+/* Ubuntu isfinite() needs _XOPEN_SOURCE, 600 means X/Open 2004 */
+#define _XOPEN_SOURCE 600
/* setgroups() needs _DEFAULT_SOURCE or _BSD_SOURCE (glibc-dependent) */
#define _DEFAULT_SOURCE
#define _BSD_SOURCE
@@ -20,9 +21,6 @@
/* strlcpy() needs _DARWIN_C_SOURCE */
#define _DARWIN_C_SOURCE
-/* some distros don't include isfinite() without next line */
-#define _POSIX_C_SOURCE 200112L
-
#include <sys/stat.h>
#include <sys/types.h>
#include <sys/time.h> /* for select() */