diff options
Diffstat (limited to 'community/gpsdrive')
-rw-r--r-- | community/gpsdrive/PKGBUILD | 15 | ||||
-rw-r--r-- | community/gpsdrive/gpsd-2.96.patch | 44 |
2 files changed, 55 insertions, 4 deletions
diff --git a/community/gpsdrive/PKGBUILD b/community/gpsdrive/PKGBUILD index f821235b1..e95ef92be 100644 --- a/community/gpsdrive/PKGBUILD +++ b/community/gpsdrive/PKGBUILD @@ -1,11 +1,11 @@ -# $Id: PKGBUILD 41051 2011-03-03 15:12:22Z tdziedzic $ +# $Id: PKGBUILD 45236 2011-04-18 13:25:52Z spupykin $ # Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com> # Contributor: Tom Newsom <Jeepster@gmx.co.uk> # Maintainer: damir <damir@archlinux.org> pkgname=gpsdrive pkgver=2.11 -pkgrel=5 +pkgrel=7 pkgdesc="A car (bike, ship, plane) navigation system" arch=("i686" "x86_64") url="http://www.gpsdrive.de/" @@ -16,8 +16,10 @@ depends=('gtk2' 'gpsd' 'libxml2' 'curl' 'python2' 'boost-libs' 'gdal' 'mapnik' ' ) # already in core ('sqlite3') makedepends=('cmake>=2.4.4' 'boost' 'cfitsio') install="gpsdrive.install" -source=("http://www.gpsdrive.de/packages/${pkgname}-${pkgver}.tar.gz") -md5sums=('6eeeca8e5c647115bea836d1f8fb6e0c') +source=("http://www.gpsdrive.de/packages/${pkgname}-${pkgver}.tar.gz" + "gpsd-2.96.patch") +md5sums=('6eeeca8e5c647115bea836d1f8fb6e0c' + '5769e12c6d8932fb721212434c64f505') build() { cd "$srcdir" @@ -57,6 +59,11 @@ build() { -DWITH_DBUS=OFF \ -DLIBGPS_OLD=OFF \ "$srcdir/gpsdrive-$pkgver" + (cd "$srcdir/gpsdrive-$pkgver" && patch -p1 <$srcdir/gpsd-2.96.patch) make +} + +package() { + cd "$srcdir/build" make DESTDIR="$pkgdir" install } diff --git a/community/gpsdrive/gpsd-2.96.patch b/community/gpsdrive/gpsd-2.96.patch new file mode 100644 index 000000000..bc6c7475f --- /dev/null +++ b/community/gpsdrive/gpsd-2.96.patch @@ -0,0 +1,44 @@ +diff -wbBur gpsdrive-2.11/src/gps_handler.c gpsdrive-2.11.my/src/gps_handler.c +--- gpsdrive-2.11/src/gps_handler.c 2010-06-24 19:53:32.000000000 +0000 ++++ gpsdrive-2.11.my/src/gps_handler.c 2011-04-18 13:21:33.000000000 +0000 +@@ -264,7 +264,8 @@ + #define GPS_TIMER 500 + + static gint gps_timeout_source = 0; +-static struct gps_data_t *gpsdata; ++static struct gps_data_t __gd; ++static struct gps_data_t *gpsdata = &__gd; + + /* SYMBOLS USED IN LIBGPS: + * +@@ -410,9 +411,10 @@ + */ + gps_query (gpsdata, "oys\n"); + #else +- if (gps_waiting(gpsdata)) ++ if (gps_waiting(gpsdata, 1000000)) + { +- gps_poll (gpsdata); ++ gps_read (gpsdata); ++ gps_hook_cb(gpsdata, NULL); + } + #endif + +@@ -447,7 +449,7 @@ + } + + /* try to open connection */ +- gpsdata = gps_open (local_config.gpsd_server, local_config.gpsd_port); ++ gpsdata = gps_open (local_config.gpsd_server, local_config.gpsd_port, gpsdata) ? NULL : &__gd; + if (!gpsdata) + { + g_print ("Can't connect to gps daemon on %s:%s, disabling GPS support!\n", +@@ -466,7 +468,7 @@ + gps_sats = g_new (gps_satellite_struct, MAXCHANNELS); + + /* set hook function to handle gps data */ +- gps_set_raw_hook (gpsdata, (gpointer) gps_hook_cb); ++// gps_set_raw_hook (gpsdata, (gpointer) gps_hook_cb); + + #ifndef LIBGPS_OLD + /* enable watch mode to get data stream from gpsd */ |