diff options
author | Jeff Garrett <jeff@jgarrett.org> | 2008-01-25 01:39:18 -0600 |
---|---|---|
committer | Jeff Garrett <jeff@jgarrett.org> | 2008-01-25 01:39:18 -0600 |
commit | 4ee12124d237033146d77df458e55394d88c9e2a (patch) | |
tree | d59d4774affad0cf1fdab933eef36b1d422e52db | |
parent | e74c7775e9f80dc3138e570ae1b0e25364afd270 (diff) |
Include gpsd_config.h before gps.h
Compile fix, gps.h is not guaranteed to include it
-rw-r--r-- | configure.ac | 1 | ||||
-rw-r--r-- | src/gpsclient.c | 5 |
2 files changed, 6 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index 63b11b5..c09e9e9 100644 --- a/configure.ac +++ b/configure.ac @@ -115,6 +115,7 @@ AC_ARG_WITH(gpsd, CPPFLAGS="$CPPFLAGS -I${GPSD_PREFIX}/include" AC_CHECK_HEADERS(gps.h, , AC_MSG_ERROR([GPSD not found. Use --with-gpsd=prefix to specify the location of GPSD.])) +AC_CHECK_HEADERS(gpsd_config.h) AC_SUBST(GPSD_PREFIX) GPSD_LIBS="-L${GPSD_PREFIX}/lib -lgps" diff --git a/src/gpsclient.c b/src/gpsclient.c index 7121fc3..4c67b41 100644 --- a/src/gpsclient.c +++ b/src/gpsclient.c @@ -27,8 +27,13 @@ Purpose of gpsclient.c: */ #define HAVE_GPSD // XXX: this should come from configure.ac +#include "config.h" #include <gtk/gtk.h> + +#ifdef HAVE_GPSD_CONFIG_H +#include <gpsd_config.h> +#endif #include <gps.h> #include "main.h" #include "gpsclient.h" |