mirror of
https://git.yoctoproject.org/poky
synced 2026-03-11 01:39:40 +01:00
We've been removing PR values from recipes at upgrade time for a while. In general anyone maintaining a binary distro would end up having to curate these themselves so the values in OE-Core aren't really that useful anymore. In many ways it makes sense to clear out the remaining ones (which are mostly for 'config' recipes that are unlikely to increase in PV) and leave a clean slate for anyone implementing a binary distro config. References are left in meta-selftest since the tests there do involve them and their removal upon upgrade. (From OE-Core rev: d4c346e8ab8f3cae25d1b01c7331ed9f6d4f96ef) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
38 lines
1.3 KiB
BlitzBasic
38 lines
1.3 KiB
BlitzBasic
SUMMARY = "Provider of the machine specific securetty file"
|
|
SECTION = "base utils"
|
|
LICENSE = "MIT"
|
|
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
|
|
|
|
INHIBIT_DEFAULT_DEPS = "1"
|
|
|
|
|
|
SRC_URI = "file://securetty"
|
|
|
|
S = "${WORKDIR}"
|
|
|
|
# Since SERIAL_CONSOLES is likely to be set from the machine configuration
|
|
PACKAGE_ARCH = "${MACHINE_ARCH}"
|
|
|
|
do_install () {
|
|
# Ensure we add a suitable securetty file to the package that has
|
|
# most common embedded TTYs defined.
|
|
install -d ${D}${sysconfdir}
|
|
install -m 0400 ${WORKDIR}/securetty ${D}${sysconfdir}/securetty
|
|
if [ ! -z "${SERIAL_CONSOLES}" ]; then
|
|
# Our SERIAL_CONSOLES contains a baud rate and sometimes extra
|
|
# options as well. The following pearl :) takes that and converts
|
|
# it into newline-separated tty's and appends them into
|
|
# securetty. So if a machine has a weird looking console device
|
|
# node (e.g. ttyAMA0) that securetty does not know, it will get
|
|
# appended to securetty and root logins will be allowed on that
|
|
# console.
|
|
tmp="${SERIAL_CONSOLES}"
|
|
for entry in $tmp ; do
|
|
ttydev=`echo "$entry" | sed -e 's/^[0-9]*\;//' -e 's/\;.*//'`
|
|
if ! grep -q $ttydev ${D}${sysconfdir}/securetty; then
|
|
echo $ttydev >> ${D}${sysconfdir}/securetty
|
|
fi
|
|
done
|
|
fi
|
|
}
|