Files
meta-openembedded/meta-oe/recipes-support/rng-tools/rng-tools_4.bb
Gary Thomas e38e5e2dc7 rng-tools: Fixes for latest OE layouts
The current recipe has a few installation errors:
  * The manipulation of configurable paths drops a '/'
  * The init script defaults are placed in the wrong file
  * Finer control over init script start/stop
  * The default device is non-standard

This patch fixes these little nits and makes the package usable again.

Based on the original patch:
http://patchwork.openembedded.org/patch/41049/

Signed-off-by: Gary Thomas <gary@mlbassoc.com>
Signed-off-by: Ting Liu <ting.liu@freescale.com>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2015-02-12 19:33:45 +01:00

37 lines
1.4 KiB
BlitzBasic

SUMMARY = "Random number generator daemon"
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
DEPENDS_append_libc-uclibc = " argp-standalone"
SRC_URI = "http://heanet.dl.sourceforge.net/sourceforge/gkernel/${BP}.tar.gz \
file://init \
file://default"
SRC_URI[md5sum] = "ae89dbfcf08bdfbea19066cfbf599127"
SRC_URI[sha256sum] = "b71bdfd4222c05e8316001556be90e1606f2a1bac3efde60153bd84e873cc195"
# As the recipe doesn't inherit systemd.bbclass, we need to set this variable
# manually to avoid unnecessary postinst/preinst generated.
python () {
if not bb.utils.contains('DISTRO_FEATURES', 'sysvinit', True, False, d):
d.setVar("INHIBIT_UPDATERCD_BBCLASS", "1")
}
inherit autotools update-rc.d
do_install_append() {
# Only install the init script when 'sysvinit' is in DISTRO_FEATURES.
if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
install -d "${D}${sysconfdir}/init.d"
install -m 0755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/rng-tools
sed -i -e 's,/etc/,${sysconfdir}/,' -e 's,/usr/sbin/,${sbindir}/,' \
${D}${sysconfdir}/init.d/rng-tools
install -d "${D}${sysconfdir}/default"
install -m 0644 ${WORKDIR}/default ${D}${sysconfdir}/rng-tools
fi
}
INITSCRIPT_NAME = "rng-tools"
INITSCRIPT_PARAMS = "start 30 S . stop 30 0 6 1 ."