summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Klug <john.klug@multitech.com>2019-12-20 17:04:22 -0600
committerSerhii Kostiuk <serhii.o.kostiuk@globallogic.com>2020-05-20 19:50:22 +0300
commit82392959192122610dc200945f4a463744b158c4 (patch)
tree0333289280fddc5f8ede263410a296ee39e43c3b
parent17b8294287169d4089a23437c386c48e53829351 (diff)
downloadmeta-mlinux-82392959192122610dc200945f4a463744b158c4.tar.gz
meta-mlinux-82392959192122610dc200945f4a463744b158c4.tar.bz2
meta-mlinux-82392959192122610dc200945f4a463744b158c4.zip
Correct new gpsd_settime script in case status is missing from gpspipe output
-rwxr-xr-xrecipes-navigation/gpsd/gpsd/gpsd_settime.sh2
-rw-r--r--recipes-navigation/gpsd/gpsd_3.16.bb8
2 files changed, 7 insertions, 3 deletions
diff --git a/recipes-navigation/gpsd/gpsd/gpsd_settime.sh b/recipes-navigation/gpsd/gpsd/gpsd_settime.sh
index 578013b..e8e8f26 100755
--- a/recipes-navigation/gpsd/gpsd/gpsd_settime.sh
+++ b/recipes-navigation/gpsd/gpsd/gpsd_settime.sh
@@ -63,7 +63,7 @@ fi
) &
# Get the ISO8601 time from GPSD
-ISO8601=$(gpspipe -w | grep -m1 '{"class":"TPV","device":"/dev/gps0","status":.*,"time":"' | sed -e 's/.*,"time":"//' -e 's/Z",.*//')
+ISO8601=$(gpspipe -w | egrep -m1 '\{"class":"TPV","device":"/dev/gps0"(,"status":[0-9])*,"mode":3,"time":"' | sed -e 's/.*,"time":"//' -e 's/Z",.*//')
if (( ${#ISO8601} > 18 )) ; then
LG -p user.warn "Updating time to time, ${ISO8601}."
diff --git a/recipes-navigation/gpsd/gpsd_3.16.bb b/recipes-navigation/gpsd/gpsd_3.16.bb
index 1464981..26a8963 100644
--- a/recipes-navigation/gpsd/gpsd_3.16.bb
+++ b/recipes-navigation/gpsd/gpsd_3.16.bb
@@ -4,7 +4,7 @@ LICENSE = "BSD"
LIC_FILES_CHKSUM = "file://COPYING;md5=d217a23f408e91c94359447735bc1800"
DEPENDS = "dbus dbus-glib ncurses python libusb1 chrpath-replacement-native pps-tools"
PROVIDES = "virtual/gpsd"
-PR="m12"
+PR="m14"
EXTRANATIVEPATH += "chrpath-native"
@@ -22,6 +22,8 @@ SRC_URI = "${SAVANNAH_GNU_MIRROR}/${BPN}/${BP}.tar.gz \
file://gpsd \
file://gpsd_ubx_fixed.sh \
file://gpsd_ubx_settime.sh \
+ file://gpsd_settime.sh \
+ file://gpsd_fixed.sh \
file://gpsd.rules \
file://gpsd.service \
"
@@ -123,6 +125,8 @@ do_install_append() {
install -d ${D}${sbindir}
install -m 0755 ${WORKDIR}/gpsd_ubx_fixed.sh ${D}${sbindir}/gpsd_ubx_fixed
install -m 0755 ${WORKDIR}/gpsd_ubx_settime.sh ${D}${sbindir}/gpsd_ubx_settime
+ install -m 0755 ${WORKDIR}/gpsd_fixed.sh ${D}${sbindir}/gpsd_fixed
+ install -m 0755 ${WORKDIR}/gpsd_settime.sh ${D}${sbindir}/gpsd_settime
#support for udev
install -d ${D}/${sysconfdir}/udev/rules.d
@@ -169,7 +173,7 @@ PACKAGES =+ "libgps libgpsd python-pygps-dbg python-pygps gpsd-udev gpsd-conf gp
# FILES_${PN}-dev += "${libdir}/pkgconfdir/libgpsd.pc ${libdir}/pkgconfdir/libgps.pc \
# ${includedir}/gps.h ${includedir}/libgpsmm.h ${includedir}/gps"
-FILES_${PN} += "${sbindir}/gpsd_ubx_fixed ${sbindir}/gpsd_ubx_settime"
+FILES_${PN} += "${sbindir}/gpsd_*"
FILES_python-pygps-dbg += " ${libdir}/python*/site-packages/gps/.debug"