Skip to contentSkip to conversation

Bump gpsd from version 2.95 to version 3.7

PATCH Superseded spdawson at gmail.com 2 participants 8 messages Jul 23, 2012 – Jul 24, 2012

lore
Share & tools
lore
#0 lore raw

PATCH v3 1/1 Bump gpsd from version 2.95 to version 3.7

From: Simon Dawson <[email protected]>

---
v3: Add license information, and staging installation commands. Handle bluetooth support correctly.
v2: Remove spurious host-python dependency, as suggested by Thomas Petazzoni.

 package/gpsd/Config.in                             |   22 ++-
 package/gpsd/gpsd-fix-acs_map-compile-errors.patch |   29 +++
 package/gpsd/gpsd-fix-libgpsmm.patch               |   23 ---
 package/gpsd/gpsd-navcom.patch                     |   47 -----
 package/gpsd/gpsd.mk                               |  191 ++++++++++++--------
 5 files changed, 164 insertions(+), 148 deletions(-)
 create mode 100644 package/gpsd/gpsd-fix-acs_map-compile-errors.patch
 delete mode 100644 package/gpsd/gpsd-fix-libgpsmm.patch
 delete mode 100644 package/gpsd/gpsd-navcom.patch
package/gpsd/Config.in +15 -7
index 16635dc..18e21e5 100644
@@ -38,10 +38,6 @@ config BR2_PACKAGE_GPSD_NTP_SHM
 config BR2_PACKAGE_GPSD_PPS
 	bool "PPS time syncing support"
 
-config BR2_PACKAGE_GPSD_PPS_ON_CTS
-	bool "PPS pulse on CTS rather than DCD"
-	depends on BR2_PACKAGE_GPSD_PPS
-
 config BR2_PACKAGE_GPSD_USER
 	bool "GPSD privilege revocation user"
 config BR2_PACKAGE_GPSD_USER_VALUE
@@ -85,9 +81,6 @@ config BR2_PACKAGE_GPSD_CONTROLSEND
 	bool "allow gpsctl/gpsmon to change device settings"
 	default y
 
-config BR2_PACKAGE_GPSD_RAW
-	bool "enable raw measurement processing"
-
 config BR2_PACKAGE_GPSD_SQUELCH
 	bool "squelch gpsd_report and gpsd_hexdump to save cpu"
 
@@ -116,6 +109,11 @@ config BR2_PACKAGE_GPSD_EVERMORE
 	help
 	  EverMore binary support
 
+config BR2_PACKAGE_GPSD_FURY
+	bool "Fury"
+	help
+	  Jackson Labs Fury and Firefly support
+
 config BR2_PACKAGE_GPSD_FV18
 	bool "FV-18"
 	help
@@ -131,6 +129,11 @@ config BR2_PACKAGE_GPSD_GARMIN_SIMPLE_TXT
 	help
 	  Garmin Simple Text support
 
+config BR2_PACKAGE_GPSD_GEOSTAR
+	bool "Geostar"
+	help
+	  Geostar Protocol support
+
 config BR2_PACKAGE_GPSD_GPSCLOCK
 	bool "GPSClock"
 	help
@@ -162,6 +165,11 @@ config BR2_PACKAGE_GPSD_NAVCOM
 	help
 	  Navcom binary support
 
+config BR2_PACKAGE_GPSD_NMEA2000
+	bool "nmea2000"
+	help
+	  NMEA2000/CAN support
+
 config BR2_PACKAGE_GPSD_OCEANSERVER
 	bool "OceanServer"
 	help
package/gpsd/gpsd-fix-acs_map-compile-errors.patch new file +29 -0
new file mode 100644
index 0000000..14d9287
@@ -0,0 +1,29 @@
+Hack gpsd to prevent undefined references to acs_map from ncurses.
+
+Signed-off-by: Simon Dawson <[email protected]>
+diff -Nurp a/gpsmon.c b/gpsmon.c
+--- a/gpsmon.c	2012-05-18 09:45:37.000000000 +0100
++++ b/gpsmon.c	2012-06-07 12:41:31.257807969 +0100
+@@ -24,6 +24,9 @@
+ #include <unistd.h>
+ #endif /* S_SPLINT_S */
+ 
++/* Ugly hack to prevent undefined reference to acs_map */
++unsigned long acs_map[128];
++
+ #include "gpsd_config.h"
+ #ifdef HAVE_BLUEZ
+ #include <bluetooth/bluetooth.h>
+diff -Nurp a/monitor_nmea.c b/monitor_nmea.c
+--- a/monitor_nmea.c	2011-11-22 08:49:33.000000000 +0000
++++ b/monitor_nmea.c	2012-06-07 12:41:37.081807709 +0100
+@@ -15,6 +15,9 @@
+ #include <unistd.h>
+ #endif /* S_SPLINT_S */
+ 
++/* Ugly hack to prevent undefined reference to acs_map */
++unsigned long acs_map[128];
++
+ #include "gpsd.h"
+ #include "gpsmon.h"
+ #include "gpsdclient.h"
package/gpsd/gpsd-fix-libgpsmm.patch deleted +0 -23
deleted file mode 100644
index 893965e..0000000
@@ -1,23 +0,0 @@
-diff -Nura gpsd-2.95.orig/Makefile.in gpsd-2.95.x/Makefile.in
---- gpsd-2.95.orig/Makefile.in	2010-07-13 19:48:24.000000000 -0300
-+++ gpsd-2.95.x/Makefile.in	2010-07-27 17:40:28.902568874 -0300
-@@ -546,7 +546,7 @@
- libgps_VERSION__REVISION = 0
- libgps_VERSION_AGE = 0
- libgps_VERSION_NUMBER = $(libgps_VERSION_AGE):$(libgps_VERSION__REVISION):$(libgps_VERSION_AGE)
--libgps_la_LDFLAGS = -version-number $(libgps_VERSION_CURRENT):$(libgps_VERSION__REVISION):$(libgps_VERSION_AGE)
-+libgps_la_LDFLAGS = -version-number $(libgps_VERSION_CURRENT):$(libgps_VERSION__REVISION):$(libgps_VERSION_AGE) $(LDFLAGS)
- lib_LTLIBRARIES = libgps.la libgpsd.la
- libgps_SONAME = $(shell expr $(libgps_VERSION_CURRENT) - $(libgps_VERSION_AGE))
- libgps_VERSION = $(libgps_SONAME).$(libgps_VERSION_AGE).$(libgps_VERSION__REVISION)
-@@ -612,8 +612,8 @@
- libgpsd_la_SOURCES = $(libgpsd_c_sources) $(libgpsd_h_sources) \
- 				driver_rtcm2.h packet_states.h
- 
-- at LIBGPSMM_ENABLE_FALSE@libgps_la_LINK = /bin/sh ./libtool --tag=CC --mode=link gcc $(libgps_la_LDFLAGS) -o $@
-- at LIBGPSMM_ENABLE_TRUE@libgps_la_LINK = /bin/sh ./libtool --tag=CXX --mode=link g++ $(libgps_la_LDFLAGS) -o $@
-+ at LIBGPSMM_ENABLE_FALSE@libgps_la_LINK = /bin/sh ./libtool --tag=CC --mode=link $(CC) $(libgps_la_LDFLAGS) -o $@
-+ at LIBGPSMM_ENABLE_TRUE@libgps_la_LINK = /bin/sh ./libtool --tag=CXX --mode=link $(CXX) $(libgps_la_LDFLAGS) -o $@
- nodist_libgpsd_la_SOURCES = packet_names.h ais_json.i
- libgps_la_LIBADD = $(LIBM) $(LIBC) $(LIBNSL) $(LIBSOCKET) $(LIBPTHREAD)
- libgpsd_la_LIBADD = $(LIBM) $(LIBC) $(LIBNSL) $(LIBSOCKET) $(LIBPTHREAD) $(BLUEZ_LIBS) libgps.la
package/gpsd/gpsd-navcom.patch deleted +0 -47

47 lines not on this page · raw message

package/gpsd/gpsd.mk +120 -71

303 lines not on this page · raw message

Signature · 1 line
1.7.9.5
#1 lore raw

PATCH v3 1/1 Bump gpsd from version 2.95 to version 3.7

Le Mon, 23 Jul 2012 20:29:36 +0100,
spdawson at gmail.com a ?crit :

Quoted 3 lines

From: Simon Dawson <[email protected]>

Applied, thanks.

I have just moved the HOST_SCONS definition out to the scons.mk file, and named it just SCONS, just like we already have AUTOMAKE, AUTOCONF.

Best regards,

Thomas

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
#2 lore raw

PATCH v3 1/1 Bump gpsd from version 2.95 to version 3.7

In reply to spdawson at gmail.com

Hello Simon,

Le Mon, 23 Jul 2012 20:29:36 +0100,
spdawson at gmail.com a ?crit :

Quoted 1 line
 package/gpsd/gpsd-fix-acs_map-compile-errors.patch |   29 +++

This is apparently not fixing everything:

/home/thomas/projets/buildroot/output/host/usr/bin/arm-linux-gnueabi-gcc -o gpsmon.o -c -pipe -Os -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -Wextra -Wall -Wno-uninitialized -Wno-missing-field-initializers -Wcast-align -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith -Wreturn-type -O2 -I/home/thomas/projets/buildroot/output/host/usr/arm-unknown-linux-gnueabi/sysroot/usr/include/libusb-1.0 -I/home/thomas/projets/buildroot/output/host/usr/include -I/home/thomas/projets/buildroot/output/host/usr/include/ncurses gpsmon.c In file included from gpsmon.h:11:0,

                 from gpsmon.c:36:

/home/thomas/projets/buildroot/output/host/usr/include/ncurses/curses.h:231:35: error: conflicting types for 'acs_map' gpsmon.c:28:15: note: previous declaration of 'acs_map' was here
scons: *** [gpsmon.o] Error 1
scons: building terminated because of errors.
make: *** [/home/thomas/projets/buildroot/output/build/gpsd-3.7/.stamp_built] Erreur 2

My defconfig is:

BR2_arm=y
BR2_cortex_a8=y
BR2_TOOLCHAIN_EXTERNAL=y BR2_TOOLCHAIN_EXTERNAL_LINARO_2012_02=y BR2_TOOLCHAIN_EXTERNAL_PREINSTALLED=y BR2_TOOLCHAIN_EXTERNAL_PATH="/home/thomas/x-tools/linaro-2012.02/" BR2_PACKAGE_DBUS=y
BR2_PACKAGE_DBUS_GLIB=y
BR2_PACKAGE_GPSD=y
BR2_PACKAGE_GPSD_AIVDM=y
BR2_PACKAGE_GPSD_GARMIN=y
BR2_PACKAGE_GPSD_GEOSTAR=y
BR2_PACKAGE_GPSD_ITRAX=y
BR2_PACKAGE_GPSD_NAVCOM=y BR2_PACKAGE_GPSD_OCEANSERVER=y BR2_PACKAGE_GPSD_ONCORE=y
BR2_PACKAGE_GPSD_RTCM104V3=y
BR2_PACKAGE_GPSD_SIRF=y
BR2_PACKAGE_GPSD_TRIMBLE_TSIP=y BR2_PACKAGE_GPSD_TRIPMATE=y
BR2_PACKAGE_PHP=y
BR2_PACKAGE_LIBUSB=y
BR2_PACKAGE_NCURSES=y
BR2_PACKAGE_RADVD=y

Can you have a look into this?

Thanks!

Thomas

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
#3 lore raw

PATCH v3 1/1 Bump gpsd from version 2.95 to version 3.7

In reply to spdawson at gmail.com

Le Mon, 23 Jul 2012 20:29:36 +0100,
spdawson at gmail.com a ?crit :

Quoted 5 lines
 package/gpsd/Config.in                             |   22 ++-
 package/gpsd/gpsd-fix-acs_map-compile-errors.patch |   29 +++
 package/gpsd/gpsd-fix-libgpsmm.patch               |   23 ---
 package/gpsd/gpsd-navcom.patch                     |   47 -----
 package/gpsd/gpsd.mk                               |  191 ++++++++++++--------

Other than the ncurses issue I already posted, it is also causing other build issues:

(1)

gpsd.c: In function 'main':
gpsd.c:1852:12: error: 'struct gps_context_t' has no member named 'pps_hook'

See
http://autobuild.buildroot.org/results/434fd6beca8349bf66b6615fd83bdce8be3ef590/build-end.log
and
http://autobuild.buildroot.org/results/434fd6beca8349bf66b6615fd83bdce8be3ef590/defconfig.

(2)

gpsutils.c:26: fatal error: QDateTime: No such file or directory compilation terminated.

See
http://autobuild.buildroot.org/results/c76888749337788c9ae9a04499f1fc1e1c5a2e81/build-end.log
and
http://autobuild.buildroot.org/results/c76888749337788c9ae9a04499f1fc1e1c5a2e81/defconfig.

(3) The same ncurses issue

See
http://autobuild.buildroot.org/results/40b7b67a679a91f65fec113ed0b5e737bd20558e/build-end.log
and
http://autobuild.buildroot.org/results/40b7b67a679a91f65fec113ed0b5e737bd20558e/defconfig.

(4) Maybe a host Python version problem

/home/peko/scratch/build/gpsd-3.7/SConstruct:369: Warning: 'with' will become a reserved keyword in Python 2.6
File "/home/peko/scratch/build/gpsd-3.7/SConstruct", line 369

with open("xmltest.xml", "w") as ofp:

^

SyntaxError: invalid syntax

See
http://autobuild.buildroot.org/results/5020a09f093412c3d725d8ae457d68ed72dcbf8e/build-end.log
and
http://autobuild.buildroot.org/results/5020a09f093412c3d725d8ae457d68ed72dcbf8e/defconfig.

Can you look into these issues?

Thomas Petazzoni

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
#4 lore raw

PATCH v3 1/1 Bump gpsd from version 2.95 to version 3.7

Another build issue:

(5)

gpsd.o: In function `onsig':
gpsd.c:(.text+0x8): undefined reference to `_mcount'
gpsd.o: In function `adjust_max_fd':
gpsd.c:(.text+0x38): undefined reference to `_mcount'
gpsd.o: In function `rstrip':
gpsd.c:(.text+0xe0): undefined reference to `_mcount'
gpsd.o: In function `find_device':
gpsd.c:(.text+0x160): undefined reference to `_mcount'
gpsd.o: In function `snarfline':
gpsd.c:(.text+0x204): undefined reference to _mcount' gpsd.o:gpsd.c:(.text+0x2ec): more undefined references to _mcount' follow
collect2: ld returned 1 exit status
scons: *** [gpsd] Error 1
scons: building terminated because of errors.
make: *** [/home/peko/scratch/build/gpsd-3.7/.stamp_built] Error 2

See
http://autobuild.buildroot.org/results/be707893f4bf0e7e964d183e4a655c5bb72d1889/build-end.log
and
http://autobuild.buildroot.org/results/be707893f4bf0e7e964d183e4a655c5bb72d1889/defconfig.

It happens when BR2_PACKAGE_GPSD_PROFILING is enabled. I don't know if uClibc has the necessary infrastructure to support profiling.

Best regards,

Thomas

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
#5 lore raw

PATCH v3 1/1 Bump gpsd from version 2.95 to version 3.7

Hi Thomas; thanks for testing this.

I've reproduced the profiling problem with uClibc (Buildroot toolchain). But I haven't managed to reproduce the other build problems yet (using Linaro 2012.02 toolchain). I wonder if it might be better to revert this for the time being; what do you think?

Simon.

#6 lore raw

PATCH v3 1/1 Bump gpsd from version 2.95 to version 3.7

Le Tue, 24 Jul 2012 09:23:42 +0100,
Simon Dawson <[email protected]> a ?crit :

Quoted 4 lines

I've reproduced the profiling problem with uClibc (Buildroot toolchain). But I haven't managed to reproduce the other build problems yet (using Linaro 2012.02 toolchain). I wonder if it might be better to revert this for the time being; what do you think?

Well, let's try to fix the problems for now :-)

Problem (1) appears when PPS support is enabled. I think it should appear with all toolchains.

Problem (2) appears when Qt is available.

I have no idea for problem (3), but I think it should easily be reproducible.

Problem (4) is due to the fact that the gcc14 build machine has Python 2.5 installed. First option: the SConstruct file should be patched to avoid using the "with" Python thing, that has been introduced in Python 2.6. Second option: we merge the patches from Samuel Martin that checks whether the version of the host Python is good enough or not, and if not, builds its own host Python version. Considering that the patch to apply on SConstruct is fairly small, I think option 1) is easy.

Thomas

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
#7 lore raw

PATCH v3 1/1 Bump gpsd from version 2.95 to version 3.7

Hi Thomas,

Quoted 1 line · Thomas Petazzoni

Well, let's try to fix the problems for now :-)

Okay; I'll carry on looking into the build problems then. I admire your optimism!

Simon