]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
ttyrun: add new recipe
authorRoss Burton <ross.burton@arm.com>
Fri, 6 Oct 2023 11:21:59 +0000 (12:21 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 9 Oct 2023 14:50:43 +0000 (15:50 +0100)
ttyrun is a small tool from IBM's s390-tools package to run a command
if the specified TTY is present, and hang if not.

This is useful so that you can list all of the potential terminals in
inittab and not have getty quiting instantly when a device isn't
present, resulting in the "respawning too fast" errors.

Note that DISTRELEASE has to be set as otherwise "build$(DATE)" is used,
which is non-reproducible.

Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/conf/distro/include/maintainers.inc
meta/recipes-core/ttyrun/ttyrun_2.29.0.bb [new file with mode: 0644]

index dcc507bb982eb8219133e494b8a7bc21e8e96af4..b2579fc44c303ce69ef79a18dc5887a6b109656c 100644 (file)
@@ -810,6 +810,7 @@ RECIPE_MAINTAINER:pn-texinfo-dummy-native = "Anuj Mittal <anuj.mittal@intel.com>
 RECIPE_MAINTAINER:pn-tiff = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER:pn-time = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER:pn-ttf-bitstream-vera = "Anuj Mittal <anuj.mittal@intel.com>"
+RECIPE_MAINTAINER:pn-ttyrun = "Ross Burton <ross.burton@arm.com>"
 RECIPE_MAINTAINER:pn-tzcode-native = "Unassigned <unassigned@yoctoproject.org>"
 RECIPE_MAINTAINER:pn-tzdata = "Unassigned <unassigned@yoctoproject.org>"
 RECIPE_MAINTAINER:pn-u-boot = "Marek Vasut <marek.vasut@gmail.com>"
diff --git a/meta/recipes-core/ttyrun/ttyrun_2.29.0.bb b/meta/recipes-core/ttyrun/ttyrun_2.29.0.bb
new file mode 100644 (file)
index 0000000..e0956b9
--- /dev/null
@@ -0,0 +1,33 @@
+SUMMARY = "Start the program if the specified terminal device is available."
+DESCRIPTION = "ttyrun is typically used to prevent a respawn through the \
+init(8) program when a terminal is not available."
+HOMEPAGE = "https://github.com/ibm-s390-linux/s390-tools"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=f5118f167b055bfd7c3450803f1847af"
+
+SRC_URI = "git://github.com/ibm-s390-linux/s390-tools;protocol=https;branch=master"
+SRCREV = "d9ce54dee3ac3827e76624352293a83eb05c727e"
+
+S = "${WORKDIR}/git"
+
+EXTRA_OEMAKE = "\
+    V=1 \
+    CC="${CC}" \
+    DISTRELEASE=${PR} \
+    "
+
+# We just want ttyrun and not the rest of s390-utils
+
+do_configure() {
+    oe_runmake -C ${S}/iucvterm/src clean
+}
+
+do_compile() {
+    oe_runmake -C ${S}/iucvterm/src ttyrun
+}
+
+do_install() {
+    install -d ${D}${sbindir}
+    install ${S}/iucvterm/src/ttyrun ${D}${sbindir}
+}