summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-navigation/gpsd/gpsd_3.7.bb
diff options
context:
space:
mode:
authorDenis 'GNUtoo' Carikli <GNUtoo@no-log.org>2012-08-07 11:08:50 +0200
committerMartin Jansa <Martin.Jansa@gmail.com>2012-08-20 10:02:09 +0200
commit334b5198e12e95f69af4772c0c2f8e512d63451b (patch)
tree9e49c0acbb06b0c5ea5dc4cd17fe366f8e1204fe /meta-oe/recipes-navigation/gpsd/gpsd_3.7.bb
parent5fd2b71ccab54b0717ebed21869754de16bd3608 (diff)
downloadmeta-openembedded-334b5198e12e95f69af4772c0c2f8e512d63451b.tar.gz
gpsd: update to 3.7, drop older 3.5 and git recipe
Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@no-log.org> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Diffstat (limited to 'meta-oe/recipes-navigation/gpsd/gpsd_3.7.bb')
-rw-r--r--meta-oe/recipes-navigation/gpsd/gpsd_3.7.bb121
1 files changed, 121 insertions, 0 deletions
diff --git a/meta-oe/recipes-navigation/gpsd/gpsd_3.7.bb b/meta-oe/recipes-navigation/gpsd/gpsd_3.7.bb
new file mode 100644
index 0000000000..e8f4cada0a
--- /dev/null
+++ b/meta-oe/recipes-navigation/gpsd/gpsd_3.7.bb
@@ -0,0 +1,121 @@
1DESCRIPTION = "A TCP/IP Daemon simplifying the communication with GPS devices"
2SECTION = "console/network"
3LICENSE = "BSD"
4LIC_FILES_CHKSUM = "file://COPYING;md5=d217a23f408e91c94359447735bc1800"
5DEPENDS = "dbus dbus-glib ncurses python libusb1 chrpath-native"
6PROVIDES = "virtual/gpsd"
7
8PR = "r0"
9
10SRC_URI = "http://download.savannah.gnu.org/releases/${PN}/${P}.tar.gz \
11 file://0002-SConstruct-respect-sysroot-also-in-SPLINTOPTS.patch \
12 file://0004-SConstruct-remove-rpath.patch \
13 file://0001-SConstruct-prefix-includepy-with-sysroot-and-drop-sy.patch \
14 file://0001-SConstruct-disable-html-and-man-docs-building-becaus.patch \
15 file://gpsd-default \
16 file://gpsd \
17 file://60-gpsd.rules \
18"
19SRC_URI[md5sum] = "52d9785eaf1a51298bb8900dbde88f98"
20SRC_URI[sha256sum] = "7800c478ee9d7ca7a502b0f892828561b1fbf7bc69d9d38c447c82c3628302ac"
21
22inherit scons update-rc.d python-dir pythonnative
23
24INITSCRIPT_NAME = "gpsd"
25INITSCRIPT_PARAMS = "defaults 35"
26
27SYSTEMD_OESCONS ??= "false"
28
29export STAGING_INCDIR
30export STAGING_LIBDIR
31
32EXTRA_OESCONS = " \
33 sysroot=${STAGING_DIR_TARGET} \
34 libQgpsmm='false' \
35 debug='true' \
36 strip='false' \
37 systemd='${SYSTEMD_OESCONS}' \
38"
39# this cannot be used, because then chrpath is not found and only static lib is built
40# target=${HOST_SYS}
41
42do_compile_prepend() {
43 export PKG_CONFIG_PATH="${PKG_CONFIG_PATH}"
44 export PKG_CONFIG="PKG_CONFIG_SYSROOT_DIR=\"${PKG_CONFIG_SYSROOT_DIR}\" pkg-config"
45 export STAGING_PREFIX="${STAGING_DIR_HOST}/${prefix}"
46
47 export BUILD_SYS="${BUILD_SYS}"
48 export HOST_SYS="${HOST_SYS}"
49}
50
51do_install() {
52 export PKG_CONFIG_PATH="${PKG_CONFIG_PATH}"
53 export PKG_CONFIG="PKG_CONFIG_SYSROOT_DIR=\"${PKG_CONFIG_SYSROOT_DIR}\" pkg-config"
54 export STAGING_PREFIX="${STAGING_DIR_HOST}/${prefix}"
55
56 export BUILD_SYS="${BUILD_SYS}"
57 export HOST_SYS="${HOST_SYS}"
58
59 export DESTDIR="${D}"
60 # prefix is used for RPATH and DESTDIR/prefix for instalation
61 ${STAGING_BINDIR_NATIVE}/scons prefix=${prefix} install ${EXTRA_OESCONS}|| \
62 bbfatal "scons install execution failed."
63}
64
65do_install_append() {
66 install -d ${D}/${sysconfdir}/init.d
67 install -m 0755 ${WORKDIR}/gpsd ${D}/${sysconfdir}/init.d/
68 install -d ${D}/${sysconfdir}/default
69 install -m 0644 ${WORKDIR}/gpsd-default ${D}/${sysconfdir}/default/gpsd.default
70
71 #support for udev
72 install -d ${D}/${sysconfdir}/udev/rules.d
73 install -m 0644 ${WORKDIR}/60-gpsd.rules ${D}/${sysconfdir}/udev/rules.d
74 install -d ${D}${base_libdir}/udev/
75 install -m 0755 ${S}/gpsd.hotplug ${D}${base_libdir}/udev/
76
77 #support for python
78 install -d ${D}/${PYTHON_SITEPACKAGES_DIR}/gps
79 install -m 755 ${S}/gps/*.py ${D}/${PYTHON_SITEPACKAGES_DIR}/gps
80}
81
82pkg_postinst_${PN}-conf() {
83 update-alternatives --install ${sysconfdir}/default/gpsd gpsd-defaults ${sysconfdir}/default/gpsd.default 10
84}
85
86pkg_postrm_${PN}-conf() {
87 update-alternatives --remove gpsd-defaults ${sysconfdir}/default/gpsd.default
88}
89
90PACKAGES =+ "libgps libgpsd python-pygps-dbg python-pygps gpsd-udev gpsd-conf gpsd-gpsctl gps-utils"
91
92FILES_gpsd-dev += "${libdir}/pkgconfdir/libgpsd.pc ${libdir}/pkgconfdir/libgps.pc"
93
94FILES_python-pygps-dbg += " ${libdir}/python*/site-packages/gps/.debug"
95
96RDEPENDS_${PN} = "gpsd-gpsctl"
97RRECOMMENDS_${PN} = "gpsd-conf gpsd-udev"
98
99DESCRIPTION_gpsd-udev = "udev relevant files to use gpsd hotplugging"
100FILES_gpsd-udev = "${base_libdir}/udev ${sysconfdir}/udev/*"
101RDEPENDS_gpsd-udev += "udev gpsd-conf"
102
103DESCRIPTION_libgpsd = "C service library used for communicating with gpsd"
104FILES_libgpsd = "${libdir}/libgpsd.so.*"
105
106DESCRIPTION_libgps = "C service library used for communicating with gpsd"
107FILES_libgps = "${libdir}/libgps.so.*"
108
109DESCRIPTION_gpsd-conf = "gpsd configuration files and init scripts"
110FILES_gpsd-conf = "${sysconfdir}"
111
112DESCRIPTION_gpsd-gpsctl = "Tool for tweaking GPS modes"
113FILES_gpsd-gpsctl = "${bindir}/gpsctl"
114
115DESCRIPTION_gps-utils = "Utils used for simulating, monitoring,... a GPS"
116FILES_gps-utils = "${bindir}/*"
117RDEPENDS_gps-utils = "python-pygps"
118
119DESCRIPTION_python-pygps = "Python bindings to gpsd"
120FILES_python-pygps = "${PYTHON_SITEPACKAGES_DIR}/*"
121RDEPENDS_python-pygps = "python-core python-curses gpsd python-json"