[oe] [PATCH 2/2] om-gta01-gps: New recipe for the om-gta01 based GPS device.

Michael Lippautz michael.lippautz at gmail.com
Tue Feb 23 16:34:15 UTC 2010


* Re-add the GPS device that has been remove from the main gpsd recipe
---
 recipes/gpsd/files/om-gta01/gpsd-default |    6 +++-
 recipes/gpsd/om-gta01-gps_0.bb           |   31 ++++++++++++++++++++++++++++++
 2 files changed, 35 insertions(+), 2 deletions(-)
 create mode 100644 recipes/gpsd/om-gta01-gps_0.bb

diff --git a/recipes/gpsd/files/om-gta01/gpsd-default b/recipes/gpsd/files/om-gta01/gpsd-default
index abd3592..bf29ad8 100644
--- a/recipes/gpsd/files/om-gta01/gpsd-default
+++ b/recipes/gpsd/files/om-gta01/gpsd-default
@@ -1,3 +1,5 @@
 # If you must specify a non-NMEA driver, uncomment and modify the next line
-#GPSD_OPTS=
-GPS_DEV="/tmp/nmeaNP"
+GPSD_SOCKET="/var/run/gpsd.sock"
+GPSD_OPTIONS="" 
+GPS_DEVICES="/tmp/nmeaNP"
+
diff --git a/recipes/gpsd/om-gta01-gps_0.bb b/recipes/gpsd/om-gta01-gps_0.bb
new file mode 100644
index 0000000..fc2c674
--- /dev/null
+++ b/recipes/gpsd/om-gta01-gps_0.bb
@@ -0,0 +1,31 @@
+DESCRIPTION = "Package to get om-gta01 GPS hardware running"
+SECTION = "console/network"
+PRIORITY = "optional"
+LICENSE = "GPL"
+RDEPENDS_${PN} = "gpsd"
+PR="r0"
+
+SRC_URI = " \
+           file://om-gta01/restart_gllin.sh \
+           file://om-gta01/gpsd-default \
+           file://om-gta01/gps-hardware \
+"
+
+do_install() {
+	install -d ${D}${sysconfdir}/apm/resume.d
+	install -m 755 ${WORKDIR}/om-gta01/restart_gllin.sh ${D}/${sysconfdir}/apm/resume.d
+    install -d ${D}${sysconfdir}/init.d
+    install -m 755 ${WORKDIR}/om-gta01/gps-hardware ${D}${sysconfdir}/init.d
+    install -d ${D}/${sysconfdir}/default
+    install -m 0644 ${WORKDIR}/om-gta01/gpsd-default ${D}/${sysconfdir}/default/gpsd.default
+}
+
+pkg_postinst() {
+	update-alternatives --install ${sysconfdir}/default/gpsd gpsd-defaults ${sysconfdir}/default/gpsd.default 10
+}
+
+pkg_postrm() {	
+	update-alternatives --remove gpsd-defaults ${sysconfdir}/default/gpsd.default	
+}
+
+PACKAGE_ARCH_${PN} = "om-gta01"
-- 
1.6.4.4





More information about the Openembedded-devel mailing list