diff options
| author | Alistair Francis <alistair@alistair23.me> | 2019-06-25 15:07:00 +0000 |
|---|---|---|
| committer | Khem Raj <raj.khem@gmail.com> | 2019-06-25 14:21:48 -0700 |
| commit | bcee75b765a9d75209ce6ce173023998e3981e52 (patch) | |
| tree | a4204575c6f4acca073b3dd22f4f62080b5e57ea /meta-oe/recipes-navigation/gpsd/gpsd_3.18.1.bb | |
| parent | 50727a227b866f26dc381dff5aff6d21a904e522 (diff) | |
| download | meta-openembedded-bcee75b765a9d75209ce6ce173023998e3981e52.tar.gz | |
gpsd: Upgrade from 3.17 to 3.18.1
Signed-off-by: Alistair Francis <alistair@alistair23.me>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-oe/recipes-navigation/gpsd/gpsd_3.18.1.bb')
| -rw-r--r-- | meta-oe/recipes-navigation/gpsd/gpsd_3.18.1.bb | 142 |
1 files changed, 142 insertions, 0 deletions
diff --git a/meta-oe/recipes-navigation/gpsd/gpsd_3.18.1.bb b/meta-oe/recipes-navigation/gpsd/gpsd_3.18.1.bb new file mode 100644 index 0000000000..22097e3aa4 --- /dev/null +++ b/meta-oe/recipes-navigation/gpsd/gpsd_3.18.1.bb | |||
| @@ -0,0 +1,142 @@ | |||
| 1 | SUMMARY = "A TCP/IP Daemon simplifying the communication with GPS devices" | ||
| 2 | SECTION = "console/network" | ||
| 3 | LICENSE = "BSD" | ||
| 4 | LIC_FILES_CHKSUM = "file://COPYING;md5=d217a23f408e91c94359447735bc1800" | ||
| 5 | DEPENDS = "dbus ncurses python libusb1 chrpath-replacement-native pps-tools" | ||
| 6 | PROVIDES = "virtual/gpsd" | ||
| 7 | |||
| 8 | # SConstruct in gpsd does not yet support Python 3 | ||
| 9 | DEPENDS += "python-scons-native" | ||
| 10 | DEPENDS_remove = "python3-scons-native" | ||
| 11 | |||
| 12 | EXTRANATIVEPATH += "chrpath-native" | ||
| 13 | |||
| 14 | SRC_URI = "${SAVANNAH_GNU_MIRROR}/${BPN}/${BP}.tar.gz \ | ||
| 15 | file://0001-SConstruct-prefix-includepy-with-sysroot-and-drop-sy.patch \ | ||
| 16 | file://0002-include-sys-ttydefaults.h.patch \ | ||
| 17 | file://0003-SConstruct-disable-html-and-man-docs-building-becaus.patch \ | ||
| 18 | " | ||
| 19 | SRC_URI[md5sum] = "3b11f26b295010666b1767b308f90bc5" | ||
| 20 | SRC_URI[sha256sum] = "5cb1e6d880ec9a52c62492dd0e3d77451b7c7ad625895bd652f6354215aec23e" | ||
| 21 | |||
| 22 | inherit scons update-rc.d python-dir pythonnative systemd bluetooth update-alternatives | ||
| 23 | |||
| 24 | INITSCRIPT_PACKAGES = "gpsd-conf" | ||
| 25 | INITSCRIPT_NAME = "gpsd" | ||
| 26 | INITSCRIPT_PARAMS = "defaults 35" | ||
| 27 | |||
| 28 | SYSTEMD_OESCONS = "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false',d)}" | ||
| 29 | |||
| 30 | export STAGING_INCDIR | ||
| 31 | export STAGING_LIBDIR | ||
| 32 | |||
| 33 | PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)}" | ||
| 34 | PACKAGECONFIG[bluez] = "bluez='true',bluez='false',${BLUEZ}" | ||
| 35 | PACKAGECONFIG[qt] = "qt='yes' qt_versioned=5,qt='no',qtbase" | ||
| 36 | EXTRA_OESCONS = " \ | ||
| 37 | sysroot=${STAGING_DIR_TARGET} \ | ||
| 38 | libQgpsmm='false' \ | ||
| 39 | debug='true' \ | ||
| 40 | strip='false' \ | ||
| 41 | chrpath='yes' \ | ||
| 42 | systemd='${SYSTEMD_OESCONS}' \ | ||
| 43 | libdir='${libdir}' \ | ||
| 44 | ${PACKAGECONFIG_CONFARGS} \ | ||
| 45 | " | ||
| 46 | # this cannot be used, because then chrpath is not found and only static lib is built | ||
| 47 | # target=${HOST_SYS} | ||
| 48 | |||
| 49 | do_compile_prepend() { | ||
| 50 | export PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" | ||
| 51 | export PKG_CONFIG="PKG_CONFIG_SYSROOT_DIR=\"${PKG_CONFIG_SYSROOT_DIR}\" pkg-config" | ||
| 52 | export STAGING_PREFIX="${STAGING_DIR_HOST}/${prefix}" | ||
| 53 | export LINKFLAGS="${LDFLAGS}" | ||
| 54 | } | ||
| 55 | |||
| 56 | do_install() { | ||
| 57 | export PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" | ||
| 58 | export PKG_CONFIG="PKG_CONFIG_SYSROOT_DIR=\"${PKG_CONFIG_SYSROOT_DIR}\" pkg-config" | ||
| 59 | export STAGING_PREFIX="${STAGING_DIR_HOST}/${prefix}" | ||
| 60 | export LINKFLAGS="${LDFLAGS}" | ||
| 61 | |||
| 62 | export DESTDIR="${D}" | ||
| 63 | # prefix is used for RPATH and DESTDIR/prefix for instalation | ||
| 64 | ${STAGING_BINDIR_NATIVE}/scons prefix=${prefix} python_libdir=${libdir} install ${EXTRA_OESCONS} || \ | ||
| 65 | bbfatal "scons install execution failed." | ||
| 66 | } | ||
| 67 | |||
| 68 | do_install_append() { | ||
| 69 | install -d ${D}/${sysconfdir}/init.d | ||
| 70 | install -m 0755 ${S}/packaging/deb/etc_init.d_gpsd ${D}/${sysconfdir}/init.d/gpsd | ||
| 71 | install -d ${D}/${sysconfdir}/default | ||
| 72 | install -m 0644 ${S}/packaging/deb/etc_default_gpsd ${D}/${sysconfdir}/default/gpsd.default | ||
| 73 | |||
| 74 | #support for udev | ||
| 75 | install -d ${D}/${sysconfdir}/udev/rules.d | ||
| 76 | install -m 0644 ${S}/gpsd.rules ${D}/${sysconfdir}/udev/rules.d/ | ||
| 77 | install -d ${D}${base_libdir}/udev/ | ||
| 78 | install -m 0755 ${S}/gpsd.hotplug ${D}${base_libdir}/udev/ | ||
| 79 | |||
| 80 | #support for python | ||
| 81 | install -d ${D}/${PYTHON_SITEPACKAGES_DIR}/gps | ||
| 82 | install -m 755 ${S}/gps/*.py ${D}/${PYTHON_SITEPACKAGES_DIR}/gps | ||
| 83 | |||
| 84 | #support for systemd | ||
| 85 | install -d ${D}${systemd_unitdir}/system/ | ||
| 86 | install -m 0644 ${S}/systemd/${BPN}.service ${D}${systemd_unitdir}/system/${BPN}.service | ||
| 87 | install -m 0644 ${S}/systemd/${BPN}ctl@.service ${D}${systemd_unitdir}/system/${BPN}ctl@.service | ||
| 88 | install -m 0644 ${S}/systemd/${BPN}.socket ${D}${systemd_unitdir}/system/${BPN}.socket | ||
| 89 | } | ||
| 90 | |||
| 91 | PACKAGES =+ "libgps libgpsd python-pygps gpsd-udev gpsd-conf gpsd-gpsctl gps-utils" | ||
| 92 | |||
| 93 | RPROVIDES_${PN}-dbg += "python-pygps-dbg" | ||
| 94 | |||
| 95 | FILES_${PN}-dev += "${libdir}/pkgconfdir/libgpsd.pc ${libdir}/pkgconfdir/libgps.pc \ | ||
| 96 | ${libdir}/libQgpsmm.prl" | ||
| 97 | |||
| 98 | RDEPENDS_${PN} = "gpsd-gpsctl" | ||
| 99 | RRECOMMENDS_${PN} = "gpsd-conf gpsd-udev gpsd-machine-conf" | ||
| 100 | |||
| 101 | SUMMARY_gpsd-udev = "udev relevant files to use gpsd hotplugging" | ||
| 102 | FILES_gpsd-udev = "${base_libdir}/udev ${sysconfdir}/udev/*" | ||
| 103 | RDEPENDS_gpsd-udev += "udev gpsd-conf" | ||
| 104 | |||
| 105 | SUMMARY_libgpsd = "C service library used for communicating with gpsd" | ||
| 106 | FILES_libgpsd = "${libdir}/libgpsd.so.*" | ||
| 107 | |||
| 108 | SUMMARY_libgps = "C service library used for communicating with gpsd" | ||
| 109 | FILES_libgps = "${libdir}/libgps.so.*" | ||
| 110 | |||
| 111 | SUMMARY_gpsd-conf = "gpsd configuration files and init scripts" | ||
| 112 | FILES_gpsd-conf = "${sysconfdir}" | ||
| 113 | CONFFILES_gpsd-conf = "${sysconfdir}/default/gpsd.default" | ||
| 114 | |||
| 115 | SUMMARY_gpsd-gpsctl = "Tool for tweaking GPS modes" | ||
| 116 | FILES_gpsd-gpsctl = "${bindir}/gpsctl" | ||
| 117 | |||
| 118 | SUMMARY_gps-utils = "Utils used for simulating, monitoring,... a GPS" | ||
| 119 | # Python files are required for gps/fake, required for gpsfake. | ||
| 120 | FILES_gps-utils = "${bindir}/* ${libdir}/gps/*.py ${libdir}/gps/*.so" | ||
| 121 | RDEPENDS_gps-utils = "python-pygps" | ||
| 122 | |||
| 123 | SUMMARY_python-pygps = "Python bindings to gpsd" | ||
| 124 | FILES_python-pygps = "${PYTHON_SITEPACKAGES_DIR}/* ${libdir}/gps/*.py ${libdir}/*.egg-info" | ||
| 125 | RDEPENDS_python-pygps = " \ | ||
| 126 | python-core \ | ||
| 127 | python-io \ | ||
| 128 | python-threading \ | ||
| 129 | python-terminal \ | ||
| 130 | python-curses \ | ||
| 131 | gpsd \ | ||
| 132 | python-json" | ||
| 133 | |||
| 134 | RPROVIDES_${PN} += "${PN}-systemd" | ||
| 135 | RREPLACES_${PN} += "${PN}-systemd" | ||
| 136 | RCONFLICTS_${PN} += "${PN}-systemd" | ||
| 137 | SYSTEMD_SERVICE_${PN} = "${BPN}.socket ${BPN}ctl@.service" | ||
| 138 | |||
| 139 | |||
| 140 | ALTERNATIVE_${PN} = "gpsd-defaults" | ||
| 141 | ALTERNATIVE_LINK_NAME[gpsd-defaults] = "${sysconfdir}/default/gpsd" | ||
| 142 | ALTERNATIVE_TARGET[gpsd-defaults] = "${sysconfdir}/default/gpsd.default" | ||
