mirror of
https://github.com/openembedded/meta-openembedded.git
synced 2026-07-27 20:07:25 +00:00
gpsd: move systemd support from meta-systemd back to meta-oe
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
This commit is contained in:
@@ -7,7 +7,7 @@ PROVIDES = "virtual/gpsd"
|
|||||||
|
|
||||||
EXTRANATIVEPATH += "chrpath-native"
|
EXTRANATIVEPATH += "chrpath-native"
|
||||||
|
|
||||||
PR = "r3"
|
PR = "r6"
|
||||||
|
|
||||||
SRC_URI = "http://download.savannah.gnu.org/releases/${PN}/${P}.tar.gz \
|
SRC_URI = "http://download.savannah.gnu.org/releases/${PN}/${P}.tar.gz \
|
||||||
file://0002-SConstruct-respect-sysroot-also-in-SPLINTOPTS.patch \
|
file://0002-SConstruct-respect-sysroot-also-in-SPLINTOPTS.patch \
|
||||||
@@ -17,16 +17,17 @@ SRC_URI = "http://download.savannah.gnu.org/releases/${PN}/${P}.tar.gz \
|
|||||||
file://gpsd-default \
|
file://gpsd-default \
|
||||||
file://gpsd \
|
file://gpsd \
|
||||||
file://60-gpsd.rules \
|
file://60-gpsd.rules \
|
||||||
|
file://gpsd.service \
|
||||||
"
|
"
|
||||||
SRC_URI[md5sum] = "52d9785eaf1a51298bb8900dbde88f98"
|
SRC_URI[md5sum] = "52d9785eaf1a51298bb8900dbde88f98"
|
||||||
SRC_URI[sha256sum] = "7800c478ee9d7ca7a502b0f892828561b1fbf7bc69d9d38c447c82c3628302ac"
|
SRC_URI[sha256sum] = "7800c478ee9d7ca7a502b0f892828561b1fbf7bc69d9d38c447c82c3628302ac"
|
||||||
|
|
||||||
inherit scons update-rc.d python-dir pythonnative
|
inherit scons update-rc.d python-dir pythonnative systemd
|
||||||
|
|
||||||
INITSCRIPT_NAME = "gpsd"
|
INITSCRIPT_NAME = "gpsd"
|
||||||
INITSCRIPT_PARAMS = "defaults 35"
|
INITSCRIPT_PARAMS = "defaults 35"
|
||||||
|
|
||||||
SYSTEMD_OESCONS ??= "false"
|
SYSTEMD_OESCONS = "${@base_contains('DISTRO_FEATURES', 'systemd', 'true', 'false',d)}"
|
||||||
|
|
||||||
export STAGING_INCDIR
|
export STAGING_INCDIR
|
||||||
export STAGING_LIBDIR
|
export STAGING_LIBDIR
|
||||||
@@ -79,6 +80,11 @@ do_install_append() {
|
|||||||
#support for python
|
#support for python
|
||||||
install -d ${D}/${PYTHON_SITEPACKAGES_DIR}/gps
|
install -d ${D}/${PYTHON_SITEPACKAGES_DIR}/gps
|
||||||
install -m 755 ${S}/gps/*.py ${D}/${PYTHON_SITEPACKAGES_DIR}/gps
|
install -m 755 ${S}/gps/*.py ${D}/${PYTHON_SITEPACKAGES_DIR}/gps
|
||||||
|
|
||||||
|
#support for systemd
|
||||||
|
install -d ${D}${systemd_unitdir}/system/
|
||||||
|
install -m 0644 ${WORKDIR}/${PN}.service ${D}${systemd_unitdir}/system/${PN}.service
|
||||||
|
install -m 0644 ${S}/systemd/${PN}.socket ${D}${systemd_unitdir}/system/${PN}.socket
|
||||||
}
|
}
|
||||||
|
|
||||||
pkg_postinst_${PN}-conf() {
|
pkg_postinst_${PN}-conf() {
|
||||||
@@ -121,3 +127,8 @@ RDEPENDS_gps-utils = "python-pygps"
|
|||||||
DESCRIPTION_python-pygps = "Python bindings to gpsd"
|
DESCRIPTION_python-pygps = "Python bindings to gpsd"
|
||||||
FILES_python-pygps = "${PYTHON_SITEPACKAGES_DIR}/*"
|
FILES_python-pygps = "${PYTHON_SITEPACKAGES_DIR}/*"
|
||||||
RDEPENDS_python-pygps = "python-core python-curses gpsd python-json"
|
RDEPENDS_python-pygps = "python-core python-curses gpsd python-json"
|
||||||
|
|
||||||
|
RPROVIDES_${PN} += "${PN}-systemd"
|
||||||
|
RREPLACES_${PN} += "${PN}-systemd"
|
||||||
|
RCONFLICTS_${PN} += "${PN}-systemd"
|
||||||
|
SYSTEMD_SERVICE_${PN} = "${PN}.socket"
|
||||||
|
|||||||
@@ -1,20 +0,0 @@
|
|||||||
PRINC := "${@int(PRINC) + 2}"
|
|
||||||
|
|
||||||
inherit systemd
|
|
||||||
|
|
||||||
FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
|
|
||||||
|
|
||||||
SRC_URI += "file://gpsd.service"
|
|
||||||
|
|
||||||
RPROVIDES_${PN} += "${PN}-systemd"
|
|
||||||
RREPLACES_${PN} += "${PN}-systemd"
|
|
||||||
RCONFLICTS_${PN} += "${PN}-systemd"
|
|
||||||
SYSTEMD_SERVICE_${PN} = "${PN}.socket"
|
|
||||||
SYSTEMD_OESCONS = "true"
|
|
||||||
|
|
||||||
do_install_append() {
|
|
||||||
#support for systemd
|
|
||||||
install -d ${D}${systemd_unitdir}/system/
|
|
||||||
install -m 0644 ${WORKDIR}/${PN}.service ${D}${systemd_unitdir}/system/${PN}.service
|
|
||||||
install -m 0644 ${S}/systemd/${PN}.socket ${D}${systemd_unitdir}/system/${PN}.socket
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user