[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gpsd-dev] regresssion from 2011: git head fails to build on NetBSD

From: Greg Troxel
Subject: [gpsd-dev] regresssion from 2011: git head fails to build on NetBSD
Date: Fri, 25 Oct 2013 20:13:38 -0400
User-agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/23.4 (berkeley-unix)

I have been distracted with many things for longer than I realized.  I'm
catching up to the autoconf->scons change, and found several regressions
when building on NetBSD 6 (it used to build find in the 2.96 days).

(Thanks to Gary for provoking this by way of the GR301-W bulk order.)

1) endian.h is unconditionally included without testing for where it is.
On NetBSD it's sys/endian.h.  AFAICT POSIX does not specify this, so a
configure-time test is necessary.  Is the current code tested on any

2) gpsd.h uses va_list without having included stdarg.h.  It seems
that's required by POSIX but I'm not 100% sure.  Adding stdarg.h allows
the compile to succeed.

3) curses/curses_dll.h was not found, even though it's in $prefix, and
I was unable to find a --with-ncurses=prefix argument to scons from
reading the help output (to cause the corresponding -I and -L/-R

(that's as far as I got)

The following patches of course should not be applied, but are

commit 2e6953b52c7c9d49f7785c144cc777f21dea1ed3
Author: Greg Troxel <address@hidden>
Date:   Fri Oct 25 20:02:33 2013 -0400

    XXX: stdarg

diff --git a/gpsd.h-tail b/gpsd.h-tail
index 72bcf7e..2ef1f3b 100644
--- a/gpsd.h-tail
+++ b/gpsd.h-tail
@@ -905,6 +905,8 @@ extern void libgps_dump_state(struct gps_data_t *);
 # define libgps_debug_trace(args) /address@hidden@*/do { } while (0)
 #endif /* LIBGPS_DEBUG */
+#include <stdarg.h>
 void gpsd_labeled_report(const int, const int,
                         const char *, const char *, va_list);
 # if __GNUC__ >= 3 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 7)

commit 25381095c0a9f0bb8fb84a7961026bac7137fb9d
Author: Greg Troxel <address@hidden>
Date:   Fri Oct 25 19:58:38 2013 -0400

    XXX: patch endian.h for NetBSD

diff --git a/SConstruct b/SConstruct
index 8cdb5d1..99e2622 100644
--- a/SConstruct
+++ b/SConstruct
@@ -613,7 +613,7 @@ confdefs.append('''
 #ifdef __LITTLE_ENDIAN__
-#include <endian.h>
+#include <sys/endian.h>

Attachment: pgpRjSbH4aKND.pgp
Description: PGP signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]