<div dir="ltr"><div>1. Does this really need to be in core? Who is the target audience and use cases that aren&#39;t served by existing options?<br></div><div>2. There are no tests or image configurations for this. How will this be checked?</div><div>3. The amount of patches is alarming. Can you get them upstream first please?</div><div><br></div><div>Alex<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, 31 Jan 2020 at 10:32, Khem Raj &lt;<a href="mailto:raj.khem@gmail.com">raj.khem@gmail.com</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">* Another init system, very small in size with application life<br>
  cycle management<br>
* Add runit-services recipe for additional runit services from void linux<br>
* socklog is a system/kernel logger<br>
* Add socklog-services to provide additional logging services<br>
<br>
* disable the chkshsgr tests in socklog<br>
<br>
Running the chkhsgr test during cross compile fails<br>
<br>
./chkshsgr || ( cat warn-shsgr; exit 1 )<br>
Oops. Your getgroups() returned 0, and setgroups() failed; this means<br>
that I can&#39;t reliably do my shsgr test. Please either ``make&#39;&#39; as root<br>
or ``make&#39;&#39; while you&#39;re in one or more supplementary groups.<br>
<br>
All OE based targets have working getgroups()/setgroups()<br>
implementation, so its a safe assumption and therefore make the test<br>
to be a dummy<br>
<br>
Signed-off-by: Khem Raj &lt;<a href="mailto:raj.khem@gmail.com" target="_blank">raj.khem@gmail.com</a>&gt;<br>
---<br>
 meta/conf/distro/include/maintainers.inc      |   2 +<br>
 meta/conf/layer.conf                          |   1 +<br>
 meta/recipes-core/runit/<a href="http://runit-serialgetty.bb" rel="noreferrer" target="_blank">runit-serialgetty.bb</a>  |  43 ++++++++<br>
 .../runit/runit-serialgetty/finish            |   2 +<br>
 meta/recipes-core/runit/runit-serialgetty/run |   2 +<br>
 meta/recipes-core/runit/<a href="http://runit-services.bb" rel="noreferrer" target="_blank">runit-services.bb</a>     |  50 +++++++++<br>
 ...y-for-services-on-Debian-is-etc-servi.diff |  87 +++++++++++++++<br>
 ...t-nosync-file-to-make-sync-on-shutdow.diff |  95 ++++++++++++++++<br>
 ...03-utmpset.c-mixes-int32_t-and-time_t.diff |  57 ++++++++++<br>
 ...-t-use-static-to-link-runit-runit-ini.diff |  30 ++++++<br>
 .../0005-patch-etc-runit-2-for-FHS.patch      |  17 +++<br>
 ...0006-make-buildsystem-respect-CFLAGS.patch |  21 ++++<br>
 .../runit/0007-move-communication-files.patch | 102 ++++++++++++++++++<br>
 .../runit/0008-emulate-sysv-runlevel-5.patch  |  20 ++++<br>
 .../runit/0009-fix-error-in-manpage.patch     |  23 ++++<br>
 meta/recipes-core/runit/runit/clearmem.patch  |  22 ++++<br>
 meta/recipes-core/runit/runit/cross.patch     |  50 +++++++++<br>
 ...h-disable-chkshgrp-test-that-fails-i.patch |  19 ++++<br>
 ...h-fix-spin-lock-on-systems-with-poor.patch |  20 ++++<br>
 ...h-make-build-system-print-compilatio.patch |  15 +++<br>
 meta/recipes-core/runit/runit/svlogd.patch    |  19 ++++<br>
 meta/recipes-core/runit/<a href="http://runit_2.1.2.bb" rel="noreferrer" target="_blank">runit_2.1.2.bb</a>        |  68 ++++++++++++<br>
 meta/recipes-core/runit/<a href="http://socklog-services.bb" rel="noreferrer" target="_blank">socklog-services.bb</a>   |  23 ++++<br>
 ...-options-to-cp-to-ensure-proper-mods.patch |  33 ++++++<br>
 meta/recipes-core/runit/socklog/cross.patch   |  58 ++++++++++<br>
 meta/recipes-core/runit/<a href="http://socklog_2.1.0.bb" rel="noreferrer" target="_blank">socklog_2.1.0.bb</a>      |  32 ++++++<br>
 26 files changed, 911 insertions(+)<br>
 create mode 100644 meta/recipes-core/runit/<a href="http://runit-serialgetty.bb" rel="noreferrer" target="_blank">runit-serialgetty.bb</a><br>
 create mode 100644 meta/recipes-core/runit/runit-serialgetty/finish<br>
 create mode 100644 meta/recipes-core/runit/runit-serialgetty/run<br>
 create mode 100644 meta/recipes-core/runit/<a href="http://runit-services.bb" rel="noreferrer" target="_blank">runit-services.bb</a><br>
 create mode 100644 meta/recipes-core/runit/runit/0001-default-directory-for-services-on-Debian-is-etc-servi.diff<br>
 create mode 100644 meta/recipes-core/runit/runit/0002-support-etc-runit-nosync-file-to-make-sync-on-shutdow.diff<br>
 create mode 100644 meta/recipes-core/runit/runit/0003-utmpset.c-mixes-int32_t-and-time_t.diff<br>
 create mode 100644 meta/recipes-core/runit/runit/0004-src-Makefile-don-t-use-static-to-link-runit-runit-ini.diff<br>
 create mode 100644 meta/recipes-core/runit/runit/0005-patch-etc-runit-2-for-FHS.patch<br>
 create mode 100644 meta/recipes-core/runit/runit/0006-make-buildsystem-respect-CFLAGS.patch<br>
 create mode 100644 meta/recipes-core/runit/runit/0007-move-communication-files.patch<br>
 create mode 100644 meta/recipes-core/runit/runit/0008-emulate-sysv-runlevel-5.patch<br>
 create mode 100644 meta/recipes-core/runit/runit/0009-fix-error-in-manpage.patch<br>
 create mode 100644 meta/recipes-core/runit/runit/clearmem.patch<br>
 create mode 100644 meta/recipes-core/runit/runit/cross.patch<br>
 create mode 100644 meta/recipes-core/runit/runit/patch-disable-chkshgrp-test-that-fails-i.patch<br>
 create mode 100644 meta/recipes-core/runit/runit/patch-fix-spin-lock-on-systems-with-poor.patch<br>
 create mode 100644 meta/recipes-core/runit/runit/patch-make-build-system-print-compilatio.patch<br>
 create mode 100644 meta/recipes-core/runit/runit/svlogd.patch<br>
 create mode 100644 meta/recipes-core/runit/<a href="http://runit_2.1.2.bb" rel="noreferrer" target="_blank">runit_2.1.2.bb</a><br>
 create mode 100644 meta/recipes-core/runit/<a href="http://socklog-services.bb" rel="noreferrer" target="_blank">socklog-services.bb</a><br>
 create mode 100644 meta/recipes-core/runit/socklog-services/0001-Use-options-to-cp-to-ensure-proper-mods.patch<br>
 create mode 100644 meta/recipes-core/runit/socklog/cross.patch<br>
 create mode 100644 meta/recipes-core/runit/<a href="http://socklog_2.1.0.bb" rel="noreferrer" target="_blank">socklog_2.1.0.bb</a><br>
<br>
diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc<br>
index a80e85a2f6..5e79dc3892 100644<br>
--- a/meta/conf/distro/include/maintainers.inc<br>
+++ b/meta/conf/distro/include/maintainers.inc<br>
@@ -616,6 +616,8 @@ RECIPE_MAINTAINER_pn-rsync = &quot;Yi Zhao &lt;<a href="mailto:yi.zhao@windriver.com" target="_blank">yi.zhao@windriver.com</a>&gt;&quot;<br>
 RECIPE_MAINTAINER_pn-rt-tests = &quot;Alexander Kanavin &lt;<a href="mailto:alex.kanavin@gmail.com" target="_blank">alex.kanavin@gmail.com</a>&gt;&quot;<br>
 RECIPE_MAINTAINER_pn-ruby = &quot;Ross Burton &lt;<a href="mailto:ross.burton@intel.com" target="_blank">ross.burton@intel.com</a>&gt;&quot;<br>
 RECIPE_MAINTAINER_pn-run-postinsts = &quot;Ross Burton &lt;<a href="mailto:ross.burton@intel.com" target="_blank">ross.burton@intel.com</a>&gt;&quot;<br>
+RECIPE_MAINTAINER_pn-runit = &quot;Khem Raj &lt;<a href="mailto:raj.khem@gmail.com" target="_blank">raj.khem@gmail.com</a>&gt;&quot;<br>
+RECIPE_MAINTAINER_pn-runit-serialgetty = &quot;Khem Raj &lt;<a href="mailto:raj.khem@gmail.com" target="_blank">raj.khem@gmail.com</a>&gt;&quot;<br>
 RECIPE_MAINTAINER_pn-rxvt-unicode = &quot;Armin Kuster &lt;<a href="mailto:akuster808@gmail.com" target="_blank">akuster808@gmail.com</a>&gt;&quot;<br>
 RECIPE_MAINTAINER_pn-sato-screenshot = &quot;Ross Burton &lt;<a href="mailto:ross.burton@intel.com" target="_blank">ross.burton@intel.com</a>&gt;&quot;<br>
 RECIPE_MAINTAINER_pn-sbc = &quot;Tanu Kaskinen &lt;<a href="mailto:tanuk@iki.fi" target="_blank">tanuk@iki.fi</a>&gt;&quot;<br>
diff --git a/meta/conf/layer.conf b/meta/conf/layer.conf<br>
index fcdf9ae5a3..07d9a9e32d 100644<br>
--- a/meta/conf/layer.conf<br>
+++ b/meta/conf/layer.conf<br>
@@ -35,6 +35,7 @@ SIGGEN_EXCLUDERECIPES_ABISAFE += &quot; \<br>
   keymaps \<br>
   udev-extraconf \<br>
   packagegroup-x11-xserver \<br>
+  runit-serialgetty \<br>
   systemd-serialgetty \<br>
   initscripts \<br>
   shadow \<br>
diff --git a/meta/recipes-core/runit/<a href="http://runit-serialgetty.bb" rel="noreferrer" target="_blank">runit-serialgetty.bb</a> b/meta/recipes-core/runit/<a href="http://runit-serialgetty.bb" rel="noreferrer" target="_blank">runit-serialgetty.bb</a><br>
new file mode 100644<br>
index 0000000000..780a74bafa<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/<a href="http://runit-serialgetty.bb" rel="noreferrer" target="_blank">runit-serialgetty.bb</a><br>
@@ -0,0 +1,43 @@<br>
+# Copyright (C) 2017 Khem Raj &lt;<a href="mailto:raj.khem@gmail.com" target="_blank">raj.khem@gmail.com</a>&gt;<br>
+# Released under the MIT license (see COPYING.MIT for the terms)<br>
+<br>
+DESCRIPTION = &quot;Serial terminal support for runit&quot;<br>
+<br>
+SECTION = &quot;base utils&quot;<br>
+LICENSE = &quot;MIT&quot;<br>
+LIC_FILES_CHKSUM = &quot;file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420&quot;<br>
+<br>
+INHIBIT_DEFAULT_DEPS = &quot;1&quot;<br>
+<br>
+SRC_URI = &quot;\<br>
+           file://run \<br>
+           file://finish \<br>
+&quot;<br>
+<br>
+S = &quot;${WORKDIR}&quot;<br>
+<br>
+SERIAL_CONSOLES ??= &quot;115200;ttyS0&quot;<br>
+<br>
+do_install() {<br>
+       install -d ${D}${sysconfdir}/service ${D}${sysconfdir}/runit/runsvdir/default<br>
+       tmp=&quot;${SERIAL_CONSOLES}&quot;<br>
+       for i in $tmp<br>
+       do<br>
+               baudrate=`echo $i | sed &#39;s/\;.*//&#39;`<br>
+               ttydev=`echo $i | sed -e &#39;s/^[0-9]*\;//&#39; -e &#39;s/\;.*//&#39;`<br>
+               install -d ${D}${sysconfdir}/sv/getty-${ttydev}<br>
+               install -m 755 ${WORKDIR}/run ${D}${sysconfdir}/sv/getty-${ttydev}<br>
+               install -m 755 ${WORKDIR}/finish ${D}${sysconfdir}/sv/getty-${ttydev}<br>
+               sed -i -e s/\@BAUDRATE\@/$baudrate/g ${D}${sysconfdir}/sv/getty-${ttydev}/run<br>
+               sed -i -e s/\@BAUDRATE\@/$baudrate/g ${D}${sysconfdir}/sv/getty-${ttydev}/finish<br>
+               sed -i -e s/\@TTY\@/$ttydev/g ${D}${sysconfdir}/sv/getty-${ttydev}/run<br>
+               sed -i -e s/\@TTY\@/$ttydev/g ${D}${sysconfdir}/sv/getty-${ttydev}/finish<br>
+               ln -s ${localstatedir}/run/sv.getty-${ttydev} ${D}${sysconfdir}/sv/getty-${ttydev}/supervise<br>
+               ln -s ${sysconfdir}/sv/getty-${ttydev} ${D}${sysconfdir}/service/getty-${ttydev}<br>
+               ln -s ${sysconfdir}/sv/getty-${ttydev} ${D}${sysconfdir}/runit/runsvdir/default/getty-${ttydev}<br>
+       done<br>
+}<br>
+# Since SERIAL_CONSOLES is likely to be set from the machine configuration<br>
+PACKAGE_ARCH = &quot;${MACHINE_ARCH}&quot;<br>
+<br>
+FILES_${PN} = &quot;${sysconfdir}&quot;<br>
diff --git a/meta/recipes-core/runit/runit-serialgetty/finish b/meta/recipes-core/runit/runit-serialgetty/finish<br>
new file mode 100644<br>
index 0000000000..860c07d64d<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit-serialgetty/finish<br>
@@ -0,0 +1,2 @@<br>
+#!/bin/sh<br>
+exec utmpset -w @TTY@<br>
diff --git a/meta/recipes-core/runit/runit-serialgetty/run b/meta/recipes-core/runit/runit-serialgetty/run<br>
new file mode 100644<br>
index 0000000000..2070fbd711<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit-serialgetty/run<br>
@@ -0,0 +1,2 @@<br>
+#!/bin/sh<br>
+exec /sbin/getty @BAUDRATE@ @TTY@ vt102<br>
diff --git a/meta/recipes-core/runit/<a href="http://runit-services.bb" rel="noreferrer" target="_blank">runit-services.bb</a> b/meta/recipes-core/runit/<a href="http://runit-services.bb" rel="noreferrer" target="_blank">runit-services.bb</a><br>
new file mode 100644<br>
index 0000000000..d24ed592dc<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/<a href="http://runit-services.bb" rel="noreferrer" target="_blank">runit-services.bb</a><br>
@@ -0,0 +1,50 @@<br>
+# Copyright (C) 2017 Khem Raj &lt;<a href="mailto:raj.khem@gmail.com" target="_blank">raj.khem@gmail.com</a>&gt;<br>
+# Released under the MIT license (see COPYING.MIT for the terms)<br>
+<br>
+DESCRIPTION = &quot;Additional runit scripts for OE based systems&quot;<br>
+HOMEPAGE = &quot;<a href="https://github.com/YoeDistro/oe-runit" rel="noreferrer" target="_blank">https://github.com/YoeDistro/oe-runit</a>&quot;<br>
+LICENSE = &quot;PD&quot;<br>
+LIC_FILES_CHKSUM = &quot;file://README.md;beginline=41;endline=48;md5=f2f8535b84b11359cc7757b009cfd646&quot;<br>
+SECTION = &quot;base&quot;<br>
+<br>
+PV = &quot;20180623+git${SRCPV}&quot;<br>
+<br>
+SRCREV = &quot;8d5db5c26670e49524f33800aaf0337466495c84&quot;<br>
+SRC_URI = &quot;git://<a href="http://github.com/YoeDistro/oe-runit;branch=oe/master" rel="noreferrer" target="_blank">github.com/YoeDistro/oe-runit;branch=oe/master</a> \<br>
+&quot;<br>
+<br>
+S = &quot;${WORKDIR}/git&quot;<br>
+<br>
+EXTRA_OEMAKE = &quot;PREFIX=${exec_prefix}&quot;<br>
+<br>
+do_install() {<br>
+       oe_runmake DESTDIR=${D} install<br>
+       install -d ${D}${base_bindir} ${D}${sysconfdir}/runit/runsvdir<br>
+       for f in shutdown halt reboot poweroff<br>
+       do<br>
+               ln -sf ${bindir}/$f ${D}${base_bindir}/$f<br>
+       done<br>
+}<br>
+<br>
+pkg_postinst_ontarget_${PN} () {<br>
+        # Enable default services:<br>
+        #       - agetty-tty[1-4] (default)<br>
+        #       - udevd (default)<br>
+        #       - sulogin (single)<br>
+        mkdir -p $D/etc/runit/runsvdir/single<br>
+        ln -sf /etc/sv/sulogin $D/etc/runit/runsvdir/single<br>
+<br>
+        mkdir -p $D/etc/runit/runsvdir/default<br>
+        if [ ! -e $D/etc/runit/runsvdir/current ]; then<br>
+               ln -sf default $D/etc/runit/runsvdir/current<br>
+       fi<br>
+        if [ -e $D/etc/sv/udevd/run ]; then<br>
+               ln -sf /etc/sv/udevd $D/etc/runit/runsvdir/default<br>
+       fi<br>
+}<br>
+<br>
+RDEPENDS_${PN} = &quot;runit findutils util-linux-fsck coreutils&quot;<br>
+<br>
+PACKAGES =+ &quot;${PN}-dracut&quot;<br>
+<br>
+FILES_${PN}-dracut = &quot;${nonarch_libdir}/dracut&quot;<br>
diff --git a/meta/recipes-core/runit/runit/0001-default-directory-for-services-on-Debian-is-etc-servi.diff b/meta/recipes-core/runit/runit/0001-default-directory-for-services-on-Debian-is-etc-servi.diff<br>
new file mode 100644<br>
index 0000000000..afc1bc5564<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/0001-default-directory-for-services-on-Debian-is-etc-servi.diff<br>
@@ -0,0 +1,87 @@<br>
+From d99515f6c8427e5f1c8f252532df8858bdef1007 Mon Sep 17 00:00:00 2001<br>
+From: Gerrit Pape &lt;<a href="mailto:pape@smarden.org" target="_blank">pape@smarden.org</a>&gt;<br>
+Date: Wed, 7 May 2008 23:51:16 +0000<br>
+Subject: [PATCH] default directory for services on Debian is /etc/service/,<br>
+ not /service/<br>
+<br>
+---<br>
+ runit-2.1.2/man/runsv.8      | 4 ++--<br>
+ runit-2.1.2/man/runsvchdir.8 | 4 ++--<br>
+ runit-2.1.2/man/sv.8         | 4 ++--<br>
+ runit-2.1.2/src/sv.c         | 2 +-<br>
+ 4 files changed, 7 insertions(+), 7 deletions(-)<br>
+<br>
+diff --git a/runit-2.1.2/man/runsv.8 b/runit-2.1.2/man/runsv.8<br>
+index 7c5abfc..75bc73a 100644<br>
+--- a/runit-2.1.2/man/runsv.8<br>
++++ b/runit-2.1.2/man/runsv.8<br>
+@@ -157,9 +157,9 @@ This command is ignored if it is given to<br>
+ .IR service /log/supervise/control.<br>
+ .P<br>
+ Example: to send a TERM signal to the socklog-unix service, either do<br>
+-  # sv term /service/socklog-unix<br>
++  # sv term /etc/service/socklog-unix<br>
+  or<br>
+-  # printf t &gt;/service/socklog-unix/supervise/control<br>
++  # printf t &gt;/etc/service/socklog-unix/supervise/control<br>
+ .P<br>
+ .BR printf (1)<br>
+ usually blocks if no<br>
+diff --git a/runit-2.1.2/man/runsvchdir.8 b/runit-2.1.2/man/runsvchdir.8<br>
+index f7f94dc..a5fc180 100644<br>
+--- a/runit-2.1.2/man/runsvchdir.8<br>
++++ b/runit-2.1.2/man/runsvchdir.8<br>
+@@ -27,13 +27,13 @@ with a symlink pointing to<br>
+ .IR dir .<br>
+ .P<br>
+ Normally <br>
+-.I /service<br>
++.I /etc/service<br>
+ is a symlink to<br>
+ .IR current ,<br>
+ and<br>
+ .BR runsvdir (8)<br>
+ is running<br>
+-.IR /service/ .<br>
++.IR /etc/service/ .<br>
+ .SH EXIT CODES<br>
+ .B runsvchdir<br>
+ prints an error message and exits 111 on error.<br>
+diff --git a/runit-2.1.2/man/sv.8 b/runit-2.1.2/man/sv.8<br>
+index 7ed9852..fa56443 100644<br>
+--- a/runit-2.1.2/man/sv.8<br>
++++ b/runit-2.1.2/man/sv.8<br>
+@@ -30,7 +30,7 @@ If<br>
+ .I service<br>
+ doesn&#39;t start with a dot or slash and doesn&#39;t end with a slash, it is<br>
+ searched in the default services directory<br>
+-.IR /service/ ,<br>
++.IR /etc/service/ ,<br>
+ otherwise relative to the current directory.<br>
+ .P<br>
+ .I command<br>
+@@ -232,7 +232,7 @@ This option implies<br>
+ .TP<br>
+ .B SVDIR<br>
+ The environment variable $SVDIR overrides the default services directory<br>
+-.IR /service/ .<br>
++.IR /etc/service/ .<br>
+ .TP<br>
+ .B SVWAIT<br>
+ The environment variable $SVWAIT overrides the default 7 seconds to wait<br>
+diff --git a/runit-2.1.2/src/sv.c b/runit-2.1.2/src/sv.c<br>
+index 0125795..887e9d1 100644<br>
+--- a/runit-2.1.2/src/sv.c<br>
++++ b/runit-2.1.2/src/sv.c<br>
+@@ -32,7 +32,7 @@<br>
+ char *progname;<br>
+ char *action;<br>
+ char *acts;<br>
+-char *varservice =&quot;/service/&quot;;<br>
++char *varservice =&quot;/etc/service/&quot;;<br>
+ char **service;<br>
+ char **servicex;<br>
+ unsigned int services;<br>
+-- <br>
+2.0.1<br>
+<br>
diff --git a/meta/recipes-core/runit/runit/0002-support-etc-runit-nosync-file-to-make-sync-on-shutdow.diff b/meta/recipes-core/runit/runit/0002-support-etc-runit-nosync-file-to-make-sync-on-shutdow.diff<br>
new file mode 100644<br>
index 0000000000..91f9e947e1<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/0002-support-etc-runit-nosync-file-to-make-sync-on-shutdow.diff<br>
@@ -0,0 +1,95 @@<br>
+From aed8774b9aa813cbb3e8b732f6f7ae132f86c82b Mon Sep 17 00:00:00 2001<br>
+From: Andras Korn &lt;<a href="mailto:korn-debbugs@elan.rulez.org" target="_blank">korn-debbugs@elan.rulez.org</a>&gt;<br>
+Date: Thu, 6 Dec 2012 16:57:06 +0100<br>
+Subject: [PATCH] support /etc/runit/nosync file to make sync on<br>
+ shutdown/reboot optional<br>
+<br>
+<a href="https://bugs.debian.org/695281" rel="noreferrer" target="_blank">https://bugs.debian.org/695281</a><br>
+---<br>
+ runit-2.1.2/doc/runit.8.html |  2 ++<br>
+ runit-2.1.2/man/runit.8      |  5 +++++<br>
+ runit-2.1.2/src/runit.c      | 15 ++++++++++-----<br>
+ runit-2.1.2/src/runit.h      |  1 +<br>
+ 4 files changed, 18 insertions(+), 5 deletions(-)<br>
+<br>
+--- a/runit-2.1.2/doc/runit.8.html<br>
++++ b/runit-2.1.2/doc/runit.8.html<br>
+@@ -34,6 +34,8 @@ stage 2 if it is running, and runs &lt;i&gt;/e<br>
+ and possibly halt or reboot the system are done here. If stage 3 returns,<br>
+ &lt;b&gt;runit&lt;/b&gt; checks if the file &lt;i&gt;/etc/runit/reboot&lt;/i&gt; exists and has the execute by<br>
+ owner permission set. If so, the system is rebooted, it&amp;rsquo;s halted otherwise.<br>
++If &lt;i&gt;/etc/runit/nosync&lt;/i&gt; exists, &lt;b&gt;runit&lt;/b&gt; doesn&amp;rsquo;t invoke<br>
++sync(). This is useful in vservers.<br>
+ <br>
+ &lt;h2&gt;&lt;a name=&#39;sect6&#39;&gt;Ctrl-alt-del&lt;/a&gt;&lt;/h2&gt;<br>
+ If &lt;b&gt;runit&lt;/b&gt; receives the ctrl-alt-del keyboard request and the file<br>
+--- a/runit-2.1.2/man/runit.8<br>
++++ b/runit-2.1.2/man/runit.8<br>
+@@ -48,6 +48,11 @@ checks if the file<br>
+ .I /etc/runit/reboot<br>
+ exists and has the execute by owner permission set.<br>
+ If so, the system is rebooted, it&#39;s halted otherwise.<br>
++If<br>
++.I /etc/runit/nosync<br>
++exists,<br>
++.B runit<br>
++doesn&#39;t invoke sync(). This is useful in vservers.<br>
+ .SH CTRL-ALT-DEL<br>
+ If<br>
+ .B runit<br>
+--- a/runit-2.1.2/src/runit.c<br>
++++ b/runit-2.1.2/src/runit.c<br>
+@@ -41,6 +41,11 @@ void sig_int_handler (void) {<br>
+ }<br>
+ void sig_child_handler (void) { write(selfpipe[1], &quot;&quot;, 1); }<br>
+ <br>
++void sync_if_needed() {<br>
++  struct stat s;<br>
++  if (stat(NOSYNC, &amp;s) == -1) sync();<br>
++}<br>
++<br>
+ int main (int argc, const char * const *argv, char * const *envp) {<br>
+   const char * prog[2];<br>
+   int pid, pid2;<br>
+@@ -305,28 +310,28 @@ int main (int argc, const char * const *<br>
+   case -1:<br>
+   if ((stat(REBOOT, &amp;s) != -1) &amp;&amp; (s.st_mode &amp; S_IXUSR)) {<br>
+     strerr_warn2(INFO, &quot;system reboot.&quot;, 0);<br>
+-    sync();<br>
++    sync_if_needed();<br>
+     reboot_system(RB_AUTOBOOT);<br>
+   }<br>
+   else {<br>
+ #ifdef RB_POWER_OFF<br>
+     strerr_warn2(INFO, &quot;power off...&quot;, 0);<br>
+-    sync();<br>
++    sync_if_needed();<br>
+     reboot_system(RB_POWER_OFF);<br>
+     sleep(2);<br>
+ #endif<br>
+ #ifdef RB_HALT_SYSTEM<br>
+     strerr_warn2(INFO, &quot;system halt.&quot;, 0);<br>
+-    sync();<br>
++    sync_if_needed();<br>
+     reboot_system(RB_HALT_SYSTEM);<br>
+ #else<br>
+ #ifdef RB_HALT<br>
+     strerr_warn2(INFO, &quot;system halt.&quot;, 0);<br>
+-    sync();<br>
++    sync_if_needed();<br>
+     reboot_system(RB_HALT);<br>
+ #else<br>
+     strerr_warn2(INFO, &quot;system reboot.&quot;, 0);<br>
+-    sync();<br>
++    sync_if_needed();<br>
+     reboot_system(RB_AUTOBOOT);<br>
+ #endif<br>
+ #endif<br>
+--- a/runit-2.1.2/src/runit.h<br>
++++ b/runit-2.1.2/src/runit.h<br>
+@@ -1,4 +1,5 @@<br>
+ #define RUNIT &quot;/sbin/runit&quot;<br>
+ #define STOPIT &quot;/etc/runit/stopit&quot;<br>
+ #define REBOOT &quot;/etc/runit/reboot&quot;<br>
++#define NOSYNC &quot;/run/runit.nosync&quot;<br>
+ #define CTRLALTDEL &quot;/etc/runit/ctrlaltdel&quot;<br>
diff --git a/meta/recipes-core/runit/runit/0003-utmpset.c-mixes-int32_t-and-time_t.diff b/meta/recipes-core/runit/runit/0003-utmpset.c-mixes-int32_t-and-time_t.diff<br>
new file mode 100644<br>
index 0000000000..6b21bbb40e<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/0003-utmpset.c-mixes-int32_t-and-time_t.diff<br>
@@ -0,0 +1,57 @@<br>
+From 20a0afcd367666efc17c59cf121a0d991ff1bd09 Mon Sep 17 00:00:00 2001<br>
+From: Gerrit Pape &lt;<a href="mailto:pape@smarden.org" target="_blank">pape@smarden.org</a>&gt;<br>
+Date: Thu, 31 Jul 2014 12:25:49 +0000<br>
+Subject: [PATCH] utmpset.c: mixes &quot;int32_t *&quot; and &quot;time_t *&quot;<br>
+<br>
+Don&#39;t pass int32_t to time(), thx Lorenzo Beretta,<br>
+<a href="https://bugs.debian.org/754849" rel="noreferrer" target="_blank">https://bugs.debian.org/754849</a><br>
+---<br>
+ runit-2.1.2/src/utmpset.c | 8 ++++++--<br>
+ 1 file changed, 6 insertions(+), 2 deletions(-)<br>
+<br>
+diff --git a/runit-2.1.2/src/utmpset.c b/runit-2.1.2/src/utmpset.c<br>
+index eea41a5..2e8a525 100644<br>
+--- a/runit-2.1.2/src/utmpset.c<br>
++++ b/runit-2.1.2/src/utmpset.c<br>
+@@ -24,6 +24,7 @@ void usage(void) { strerr_die4x(1, &quot;usage: &quot;, progname, USAGE, &quot;\n&quot;); }<br>
+ int utmp_logout(const char *line) {<br>
+   int fd;<br>
+   uw_tmp ut;<br>
++  time_t t;<br>
+   int ok =-1;<br>
+ <br>
+   if ((fd =open(UW_TMP_UFILE, O_RDWR, 0)) &lt; 0)<br>
+@@ -35,7 +36,8 @@ int utmp_logout(const char *line) {<br>
+     if (!ut.ut_name[0] || (str_diff(ut.ut_line, line) != 0)) continue;<br>
+     memset(ut.ut_name, 0, sizeof ut.ut_name);<br>
+     memset(ut.ut_host, 0, sizeof ut.ut_host);<br>
+-    if (time(&amp;ut.ut_time) == -1) break;<br>
++    if (time(&amp;t) == -1) break;<br>
++    ut.ut_time = t;<br>
+ #ifdef DEAD_PROCESS<br>
+     ut.ut_type =DEAD_PROCESS;<br>
+ #endif<br>
+@@ -52,6 +54,7 @@ int wtmp_logout(const char *line) {<br>
+   int len;<br>
+   struct stat st;<br>
+   uw_tmp ut;<br>
++  time_t t;<br>
+ <br>
+   if ((fd = open_append(UW_TMP_WFILE)) == -1)<br>
+     strerr_die4sys(111, FATAL, &quot;unable to open &quot;, UW_TMP_WFILE, &quot;: &quot;);<br>
+@@ -65,10 +68,11 @@ int wtmp_logout(const char *line) {<br>
+   memset(&amp;ut, 0, sizeof(uw_tmp));<br>
+   if ((len =str_len(line)) &gt; sizeof ut.ut_line) len =sizeof ut.ut_line -2;<br>
+   byte_copy(ut.ut_line, len, line);<br>
+-  if (time(&amp;ut.ut_time) == -1) {<br>
++  if (time(&amp;t) == -1) {<br>
+     close(fd);<br>
+     return(-1);<br>
+   }<br>
++  ut.ut_time = t;<br>
+ #ifdef DEAD_PROCESS<br>
+   ut.ut_type =DEAD_PROCESS;<br>
+ #endif<br>
+-- <br>
+2.0.1<br>
+<br>
diff --git a/meta/recipes-core/runit/runit/0004-src-Makefile-don-t-use-static-to-link-runit-runit-ini.diff b/meta/recipes-core/runit/runit/0004-src-Makefile-don-t-use-static-to-link-runit-runit-ini.diff<br>
new file mode 100644<br>
index 0000000000..c2cdfc8881<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/0004-src-Makefile-don-t-use-static-to-link-runit-runit-ini.diff<br>
@@ -0,0 +1,30 @@<br>
+From 77d0f60701a401ea0de0925d9422c78fb560b4f6 Mon Sep 17 00:00:00 2001<br>
+From: Gerrit Pape &lt;<a href="mailto:pape@smarden.org" target="_blank">pape@smarden.org</a>&gt;<br>
+Date: Thu, 31 Jul 2014 12:54:32 +0000<br>
+Subject: [PATCH] src/Makefile: don&#39;t use -static to link runit, runit-init on<br>
+ Debian<br>
+<br>
+---<br>
+ runit-2.1.2/src/Makefile | 4 ++--<br>
+ 1 file changed, 2 insertions(+), 2 deletions(-)<br>
+<br>
+diff --git a/runit-2.1.2/src/Makefile b/runit-2.1.2/src/Makefile<br>
+index d9624de..507a419 100644<br>
+--- a/runit-2.1.2/src/Makefile<br>
++++ b/runit-2.1.2/src/Makefile<br>
+@@ -6,10 +6,10 @@ check: $(IT)<br>
+       ./check-local $(IT)<br>
+ <br>
+ runit: load runit.o unix.a byte.a<br>
+-      ./load runit unix.a byte.a -static<br>
++      ./load runit unix.a byte.a<br>
+ <br>
+ runit-init: load runit-init.o unix.a byte.a<br>
+-      ./load runit-init unix.a byte.a -static<br>
++      ./load runit-init unix.a byte.a<br>
+ <br>
+ runsv: load runsv.o unix.a byte.a time.a<br>
+       ./load runsv unix.a byte.a time.a<br>
+-- <br>
+2.0.1<br>
+<br>
diff --git a/meta/recipes-core/runit/runit/0005-patch-etc-runit-2-for-FHS.patch b/meta/recipes-core/runit/runit/0005-patch-etc-runit-2-for-FHS.patch<br>
new file mode 100644<br>
index 0000000000..8bcfe8801c<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/0005-patch-etc-runit-2-for-FHS.patch<br>
@@ -0,0 +1,17 @@<br>
+Description: Make /etc/runit/2 respect FHS<br>
+ On Debian system services directory is /etc/service, not /service.<br>
+Author: Dmitry Bogatov &lt;<a href="mailto:KAction@gnu.org" target="_blank">KAction@gnu.org</a>&gt;<br>
+Last-Update: 2016-05-31<br>
+---<br>
+This patch header follows DEP-3: <a href="http://dep.debian.net/deps/dep3/" rel="noreferrer" target="_blank">http://dep.debian.net/deps/dep3/</a><br>
+--- a/runit-2.1.2/etc/2<br>
++++ b/runit-2.1.2/etc/2<br>
+@@ -1,6 +1,6 @@<br>
+ #!/bin/sh<br>
+ <br>
+-PATH=/command:/usr/local/bin:/usr/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/X11R6/bin<br>
++PATH=/usr/local/bin:/usr/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/X11R6/bin<br>
+ <br>
+ exec env - PATH=$PATH \<br>
+-runsvdir -P /service &#39;log: ...........................................................................................................................................................................................................................................................................................................................................................................................................&#39;<br>
++runsvdir -P /etc/service &#39;log: ...........................................................................................................................................................................................................................................................................................................................................................................................................&#39;<br>
diff --git a/meta/recipes-core/runit/runit/0006-make-buildsystem-respect-CFLAGS.patch b/meta/recipes-core/runit/runit/0006-make-buildsystem-respect-CFLAGS.patch<br>
new file mode 100644<br>
index 0000000000..269d79a49b<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/0006-make-buildsystem-respect-CFLAGS.patch<br>
@@ -0,0 +1,21 @@<br>
+Description: Make buildsystem respect dpkg-buildflags<br>
+Author: Dmitry Bogatov &lt;<a href="mailto:KAction@gnu.org" target="_blank">KAction@gnu.org</a>&gt;<br>
+Last-Update: 2016-06-01<br>
+---<br>
+This patch header follows DEP-3: <a href="http://dep.debian.net/deps/dep3/" rel="noreferrer" target="_blank">http://dep.debian.net/deps/dep3/</a><br>
+--- a/runit-2.1.2/src/print-cc.sh<br>
++++ b/runit-2.1.2/src/print-cc.sh<br>
+@@ -2,4 +2,4 @@ cc=&quot;`head -n1 conf-cc`&quot;<br>
+ systype=&quot;`cat systype`&quot;<br>
+ <br>
+ cat warn-auto.sh<br>
+-echo exec &quot;$cc&quot; &#39;-c ${1+&quot;$@&quot;}&#39;<br>
++echo exec &quot;$cc&quot; &quot;$CPPFLAGS&quot; &quot;$CFLAGS&quot; &#39;-c ${1+&quot;$@&quot;}&#39;<br>
+--- a/runit-2.1.2/src/print-ld.sh<br>
++++ b/runit-2.1.2/src/print-ld.sh<br>
+@@ -3,4 +3,4 @@ systype=&quot;`cat systype`&quot;<br>
+ <br>
+ cat warn-auto.sh<br>
+ echo &#39;main=&quot;$1&quot;; shift&#39;<br>
+-echo exec &quot;$ld&quot; &#39;-o &quot;$main&quot; &quot;$main&quot;.o ${1+&quot;$@&quot;}&#39;<br>
++echo exec &quot;$ld&quot; &quot;$LDFLAGS&quot; &#39;-o &quot;$main&quot; &quot;$main&quot;.o ${1+&quot;$@&quot;}&#39;<br>
diff --git a/meta/recipes-core/runit/runit/0007-move-communication-files.patch b/meta/recipes-core/runit/runit/0007-move-communication-files.patch<br>
new file mode 100644<br>
index 0000000000..bfcbac8015<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/0007-move-communication-files.patch<br>
@@ -0,0 +1,102 @@<br>
+Description: Move communication files under /run<br>
+ Runit by default uses files /etc/runit/stop and /etc/runit/reboot.<br>
+ This configuration will not work when /etc is mounted read-only,<br>
+ as such this patch renames this files into /run/runit.stop and<br>
+ /run/runit.reboot<br>
+Author: Dmitry Bogatov &lt;<a href="mailto:KAction@gnu.org" target="_blank">KAction@gnu.org</a>&gt;<br>
+Last-Update: 2016-06-02<br>
+---<br>
+This patch header follows DEP-3: <a href="http://dep.debian.net/deps/dep3/" rel="noreferrer" target="_blank">http://dep.debian.net/deps/dep3/</a><br>
+--- a/runit-2.1.2/etc/debian/1<br>
++++ b/runit-2.1.2/etc/debian/1<br>
+@@ -6,5 +6,5 @@ PATH=/command:/sbin:/bin:/usr/sbin:/usr/<br>
+ /etc/init.d/rcS<br>
+ /etc/init.d/rmnologin<br>
+ <br>
+-touch /etc/runit/stopit<br>
+-chmod 0 /etc/runit/stopit<br>
++touch /run/runit.stopit<br>
++chmod 0 /run/runit.stopit<br>
+--- a/runit-2.1.2/etc/debian/3<br>
++++ b/runit-2.1.2/etc/debian/3<br>
+@@ -4,7 +4,7 @@ exec 2&gt;&amp;1<br>
+ PATH=/command:/sbin:/bin:/usr/sbin:/usr/bin<br>
+ <br>
+ LAST=0<br>
+-test -x /etc/runit/reboot &amp;&amp; LAST=6<br>
++test -x /run/runit.reboot &amp;&amp; LAST=6<br>
+ <br>
+ echo &#39;Waiting for services to stop...&#39;<br>
+ sv -w196 force-stop /service/*<br>
+--- a/runit-2.1.2/etc/debian/ctrlaltdel<br>
++++ b/runit-2.1.2/etc/debian/ctrlaltdel<br>
+@@ -4,6 +4,6 @@ PATH=/bin:/usr/bin<br>
+ MSG=&quot;System is going down in 14 seconds...&quot;<br>
+ <br>
+ # echo &#39;disabled.&#39; ; exit<br>
+-touch /etc/runit/stopit<br>
+-chmod 100 /etc/runit/stopit &amp;&amp; echo &quot;$MSG&quot; | wall<br>
++touch /etc/runit.stopit<br>
++chmod 100 /etc/runit.stopit &amp;&amp; echo &quot;$MSG&quot; | wall<br>
+ /bin/sleep 14<br>
+--- a/runit-2.1.2/man/runit-init.8<br>
++++ b/runit-2.1.2/man/runit-init.8<br>
+@@ -26,9 +26,9 @@ To signal<br>
+ the system halt request,<br>
+ .B runit-init<br>
+ removes all permissions of the file<br>
+-.I /etc/runit/reboot<br>
++.I /run/runit.reboot<br>
+ (chmod 0), and sets the execute by owner permission of the file<br>
+-.I /etc/runit/stopit<br>
++.I /run/runit.stopit<br>
+ (chmod 100).<br>
+ Then a CONT signal is sent to<br>
+ .BR runit (8).<br>
+@@ -40,9 +40,9 @@ To signal<br>
+ the system reboot request,<br>
+ .B runit-init<br>
+ sets the execute by owner permission of the files<br>
+-.I /etc/runit/reboot<br>
++.I /run/runit.reboot<br>
+ and<br>
+-.I /etc/runit/stopit<br>
++.I /run/runit.stopit<br>
+ (chmod 100). Then a CONT signal is sent to<br>
+ .BR runit (8).<br>
+ .SH EXIT CODES<br>
+--- a/runit-2.1.2/man/runit.8<br>
++++ b/runit-2.1.2/man/runit.8<br>
+@@ -45,11 +45,11 @@ done here.<br>
+ If stage 3 returns,<br>
+ .B runit<br>
+ checks if the file<br>
+-.I /etc/runit/reboot<br>
++.I /run/runit.reboot<br>
+ exists and has the execute by owner permission set.<br>
+ If so, the system is rebooted, it&#39;s halted otherwise.<br>
+ If<br>
+-.I /etc/runit/nosync<br>
++.I /run/runit.nosync<br>
+ exists,<br>
+ .B runit<br>
+ doesn&#39;t invoke sync(). This is useful in vservers.<br>
+@@ -70,7 +70,7 @@ only accepts signals in stage 2.<br>
+ If<br>
+ .B runit<br>
+ receives a CONT signal and the file<br>
+-.I /etc/runit/stopit<br>
++.I /run/runit.stopit<br>
+ exists and has the execute by owner permission set,<br>
+ .B runit<br>
+ is told to shutdown the system.<br>
+--- a/runit-2.1.2/src/runit.h<br>
++++ b/runit-2.1.2/src/runit.h<br>
+@@ -1,5 +1,5 @@<br>
+ #define RUNIT &quot;/sbin/runit&quot;<br>
+-#define STOPIT &quot;/etc/runit/stopit&quot;<br>
+-#define REBOOT &quot;/etc/runit/reboot&quot;<br>
++#define STOPIT &quot;/run/runit.stopit&quot;<br>
++#define REBOOT &quot;/run/runit.reboot&quot;<br>
+ #define NOSYNC &quot;/run/runit.nosync&quot;<br>
+ #define CTRLALTDEL &quot;/etc/runit/ctrlaltdel&quot;<br>
diff --git a/meta/recipes-core/runit/runit/0008-emulate-sysv-runlevel-5.patch b/meta/recipes-core/runit/runit/0008-emulate-sysv-runlevel-5.patch<br>
new file mode 100644<br>
index 0000000000..0d370c8fe7<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/0008-emulate-sysv-runlevel-5.patch<br>
@@ -0,0 +1,20 @@<br>
+Description: Emulalate sysv runlevel 5 by default<br>
+ Currently, not many daemons in Debian provides proper runscripts, so<br>
+ if user switches to runit, she will on next reboot, that none of daemons,<br>
+ including essential, like cron, are started.<br>
+ .<br>
+ This patch starts them in sysv-init style -- unmanaged, in background.<br>
+ It is sub-par solution, but allows one-by-one transition.<br>
+Author: Dmitry Bogatov<br>
+Forwarded: not-needed<br>
+Last-Update: 2016-06-09<br>
+---<br>
+This patch header follows DEP-3: <a href="http://dep.debian.net/deps/dep3/" rel="noreferrer" target="_blank">http://dep.debian.net/deps/dep3/</a><br>
+--- a/runit-2.1.2/etc/debian/1<br>
++++ b/runit-2.1.2/etc/debian/1<br>
+@@ -8,3 +8,5 @@ PATH=/command:/sbin:/bin:/usr/sbin:/usr/<br>
+ <br>
+ touch /run/runit.stopit<br>
+ chmod 0 /run/runit.stopit<br>
++<br>
++[ -e /etc/runit/no-emulate-sysv ] || /etc/init.d/rc 5<br>
diff --git a/meta/recipes-core/runit/runit/0009-fix-error-in-manpage.patch b/meta/recipes-core/runit/runit/0009-fix-error-in-manpage.patch<br>
new file mode 100644<br>
index 0000000000..5803b0a387<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/0009-fix-error-in-manpage.patch<br>
@@ -0,0 +1,23 @@<br>
+Description: Fix factual error in manpage.<br>
+ Log ./finish script is not actually invoked. It is not clear, whether this<br>
+ limitation is worth lifting.<br>
+Author: Dmitry Bogatov &lt;<a href="mailto:KAction@gnu.org" target="_blank">KAction@gnu.org</a>&gt;<br>
+Forwarded: no<br>
+Last-Update: 2016-08-31<br>
+---<br>
+This patch header follows DEP-3: <a href="http://dep.debian.net/deps/dep3/" rel="noreferrer" target="_blank">http://dep.debian.net/deps/dep3/</a><br>
+--- a/runit-2.1.2/man/runsv.8<br>
++++ b/runit-2.1.2/man/runsv.8<br>
+@@ -54,10 +54,8 @@ and<br>
+ .IR service /finish&#39;s<br>
+ standard output to the pipe, switches to the directory<br>
+ .IR service /log<br>
+-and starts ./run (and ./finish) exactly as described above for the<br>
+-.I service<br>
+-directory.<br>
+-The standard input of the log service is redirected to read from the pipe.<br>
++and starts ./run script. The standard input of the log service<br>
++is redirected to read from the pipe.<br>
+ .P<br>
+ .B runsv<br>
+ maintains status information in a binary format (compatible to the<br>
diff --git a/meta/recipes-core/runit/runit/clearmem.patch b/meta/recipes-core/runit/runit/clearmem.patch<br>
new file mode 100644<br>
index 0000000000..3fa28a7006<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/clearmem.patch<br>
@@ -0,0 +1,22 @@<br>
+fix segfault in svlogd discovered on armv7hf-musl.<br>
+<br>
+Code in svlogd.c allocates some memory at startup which is<br>
+not zeroed, and other code was using those garbage values.<br>
+I have no idea why this has never caused a problem before, but<br>
+for me, svlogd consistently segfaults on armv7hf-musl when<br>
+it is called by socklog.<br>
+<br>
+Upstream-Status: Pending<br>
+Author: Christopher Brannon &lt;<a href="mailto:chris@the-brannons.com" target="_blank">chris@the-brannons.com</a>&gt;<br>
+<br>
+diff -Naur runit-2.1.2/src/svlogd.c runit-2.1.2/src/svlogd.c<br>
+--- runit-2.1.2/src/svlogd.c   2014-08-10 11:22:34.000000000 -0700<br>
++++ runit-2.1.2/src/svlogd.c   2018-03-03 03:28:08.243085845 -0800<br>
+@@ -705,6 +705,7 @@<br>
+   coe(fdwdir);<br>
+   dir =(struct logdir*)alloc(dirn *sizeof(struct logdir));<br>
+   if (! dir) die_nomem();<br>
++  memset(dir, 0, dirn * sizeof(struct logdir));<br>
+   for (i =0; i &lt; dirn; ++i) {<br>
+     dir[i].fddir =-1; dir[i].fdcur =-1;<br>
+     dir[i].btmp =(char*)alloc(buflen *sizeof(char));<br>
diff --git a/meta/recipes-core/runit/runit/cross.patch b/meta/recipes-core/runit/runit/cross.patch<br>
new file mode 100644<br>
index 0000000000..3a9dcd8afe<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/cross.patch<br>
@@ -0,0 +1,50 @@<br>
+chskshsgr must be built for the host.<br>
+<br>
+Index: runit-2.1.2/src/Makefile<br>
+===================================================================<br>
+--- runit-2.1.2.orig/src/Makefile<br>
++++ runit-2.1.2/src/Makefile<br>
+@@ -170,11 +170,11 @@ byte_diff.o: byte.h byte_diff.c compile<br>
+ byte_rchr.o: byte.h byte_rchr.c compile<br>
+       ./compile byte_rchr.c<br>
+ <br>
+-chkshsgr: chkshsgr.o load<br>
+-      ./load chkshsgr <br>
++chkshsgr: chkshsgr.o loadhost<br>
++      ./loadhost chkshsgr<br>
+ <br>
+-chkshsgr.o: chkshsgr.c compile<br>
+-      ./compile chkshsgr.c<br>
++chkshsgr.o: chkshsgr.c compilehost<br>
++      ./compilehost chkshsgr.c<br>
+ <br>
+ choose: choose.sh warn-auto.sh<br>
+       rm -f choose<br>
+@@ -185,6 +185,11 @@ choose: choose.sh warn-auto.sh<br>
+ coe.o: coe.c coe.h compile<br>
+       ./compile coe.c<br>
+ <br>
++compilehost:<br>
++      cat warn-auto.sh &gt; compilehost<br>
++      @echo &#39;exec ${BUILD_CC} ${BUILD_CFLAGS} -c $${1+&quot;$$@&quot;}&#39; &gt;&gt; compilehost<br>
++      chmod 555 compilehost<br>
++<br>
+ compile: conf-cc print-cc.sh systype warn-auto.sh<br>
+       rm -f compile<br>
+       sh print-cc.sh &gt; compile<br>
+@@ -246,6 +251,15 @@ iopause.h: choose compile iopause.h1 iop<br>
+ iopause.o: compile iopause.c iopause.h select.h tai.h taia.h uint64.h<br>
+       ./compile iopause.c<br>
+ <br>
++loadhost:<br>
++      rm -f loadhost<br>
++      @echo &gt; loadhost<br>
++      @echo &#39;systype=&quot;`cat systype`&quot;&#39; &gt;&gt; loadhost<br>
++      @echo &#39;cat warn-auto.sh&#39; &gt;&gt; loadhost<br>
++      @echo &#39;main=&quot;$$1&quot;; shift&#39; &gt;&gt; loadhost<br>
++      @echo &#39;exec ${BUILD_CC} ${BUILD_LDFLAGS}  -o &quot;$$main&quot; &quot;$$main&quot;.o $${1+&quot;$$@&quot;}&#39; &gt;&gt; loadhost<br>
++      chmod 555 loadhost<br>
++<br>
+ load: conf-ld print-ld.sh systype warn-auto.sh<br>
+       rm -f load<br>
+       sh print-ld.sh &gt; load<br>
diff --git a/meta/recipes-core/runit/runit/patch-disable-chkshgrp-test-that-fails-i.patch b/meta/recipes-core/runit/runit/patch-disable-chkshgrp-test-that-fails-i.patch<br>
new file mode 100644<br>
index 0000000000..6753dff4ef<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/patch-disable-chkshgrp-test-that-fails-i.patch<br>
@@ -0,0 +1,19 @@<br>
+From: Dmitry Bogatov &lt;<a href="mailto:KAction@gnu.org" target="_blank">KAction@gnu.org</a>&gt;<br>
+Date: Sun, 13 May 2018 10:38:20 +0300<br>
+X-Dgit-Generated: 2.1.2-14 2c8a08023e964bf54344e7030573ef7ad6881880<br>
+Subject: [PATCH] Disable chkshgrp test, that fails in whalebuilder<br>
+<br>
+Upstream-Status: Pending<br>
+<br>
+---<br>
+<br>
+--- runit-2.1.2.orig/runit-2.1.2/src/Makefile<br>
++++ runit-2.1.2/runit-2.1.2/src/Makefile<br>
+@@ -234,7 +234,6 @@ hassgprm.h: choose compile hassgprm.h1 h<br>
+ <br>
+ hasshsgr.h: chkshsgr choose compile hasshsgr.h1 hasshsgr.h2 load \<br>
+ tryshsgr.c warn-shsgr<br>
+-      ./chkshsgr || ( cat warn-shsgr; exit 1 )<br>
+       ./choose clr tryshsgr hasshsgr.h1 hasshsgr.h2 &gt; hasshsgr.h<br>
+ <br>
+ haswaitp.h: choose compile haswaitp.h1 haswaitp.h2 load trywaitp.c<br>
diff --git a/meta/recipes-core/runit/runit/patch-fix-spin-lock-on-systems-with-poor.patch b/meta/recipes-core/runit/runit/patch-fix-spin-lock-on-systems-with-poor.patch<br>
new file mode 100644<br>
index 0000000000..6f15e92779<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/patch-fix-spin-lock-on-systems-with-poor.patch<br>
@@ -0,0 +1,20 @@<br>
+From: Dmitry Bogatov &lt;<a href="mailto:KAction@gnu.org" target="_blank">KAction@gnu.org</a>&gt;<br>
+Date: Mon, 28 May 2018 21:46:39 +0300<br>
+X-Dgit-Generated: 2.1.2-15 7791b76917a00ca44e3a5c297675214a40f7f215<br>
+Subject: [PATCH] Fix spin lock on systems with poor clock<br>
+<br>
+Upstream-Status: Pending<br>
+<br>
+---<br>
+<br>
+--- runit-2.1.2.orig/runit-2.1.2/src/svlogd.c<br>
++++ runit-2.1.2/runit-2.1.2/src/svlogd.c<br>
+@@ -234,7 +234,7 @@ void rmoldest(struct logdir *ld) {<br>
+         if (unlink(f-&gt;d_name) == -1)<br>
+           warn2(&quot;unable to unlink processor leftover&quot;, f-&gt;d_name);<br>
+       }<br>
+-      else {<br>
++      else if (f-&gt;d_name[26] != &#39;u&#39;) {<br>
+         ++n;<br>
+         if (str_diff(f-&gt;d_name, oldest) &lt; 0) byte_copy(oldest, 27, f-&gt;d_name);<br>
+       }<br>
diff --git a/meta/recipes-core/runit/runit/patch-make-build-system-print-compilatio.patch b/meta/recipes-core/runit/runit/patch-make-build-system-print-compilatio.patch<br>
new file mode 100644<br>
index 0000000000..f62dfa36d3<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/patch-make-build-system-print-compilatio.patch<br>
@@ -0,0 +1,15 @@<br>
+From: Dmitry Bogatov &lt;<a href="mailto:KAction@gnu.org" target="_blank">KAction@gnu.org</a>&gt;<br>
+Date: Tue, 10 Apr 2018 20:08:14 +0300<br>
+X-Dgit-Generated: 2.1.2-10 9187ce34534181446afc87277ec0d460e5575f9c<br>
+Subject: [PATCH] Make build system print compilation commands<br>
+<br>
+Upstream-Status: Pending<br>
+<br>
+---<br>
+<br>
+--- runit-2.1.2.orig/runit-2.1.2/src/warn-auto.sh<br>
++++ runit-2.1.2/runit-2.1.2/src/warn-auto.sh<br>
+@@ -1,2 +1,2 @@<br>
+-#!/bin/sh<br>
++#!/bin/sh -x<br>
+ # WARNING: This file was auto-generated. Do not edit!<br>
diff --git a/meta/recipes-core/runit/runit/svlogd.patch b/meta/recipes-core/runit/runit/svlogd.patch<br>
new file mode 100644<br>
index 0000000000..468fdb2ae4<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/runit/svlogd.patch<br>
@@ -0,0 +1,19 @@<br>
+Initialize all fields of sockaddr_in.<br>
+<a href="http://skarnet.org/cgi-bin/archive.cgi?2:mss:1163:201602:gpiglpbjdemlioaeabbn" rel="noreferrer" target="_blank">http://skarnet.org/cgi-bin/archive.cgi?2:mss:1163:201602:gpiglpbjdemlioaeabbn</a><br>
+<br>
+set all fields of sockaddr_in in svlogd.<br>
+<br>
+Upstream-Status: Submitted<br>
+<br>
+Author: Leah Neukirchen &lt;<a href="mailto:leah@vuxu.org" target="_blank">leah@vuxu.org</a>&gt;<br>
+<br>
+--- runit-2.1.2/src/svlogd.c 2014-08-10 15:22:34.000000000 -0300<br>
++++ runit-2.1.2/src/svlogd.c 2016-02-04 22:53:52.910965361 -0300<br>
+@@ -430,6 +430,7 @@<br>
+   ld-&gt;name =(char*)fn;<br>
+   ld-&gt;ppid =0;<br>
+   ld-&gt;match =&#39;+&#39;;<br>
++  ld-&gt;udpaddr.sin_family =AF_INET;<br>
+   ld-&gt;udpaddr.sin_port =0;<br>
+   ld-&gt;udponly =0;<br>
+   while (! stralloc_copys(&amp;ld-&gt;prefix, &quot;&quot;)) pause_nomem();<br>
diff --git a/meta/recipes-core/runit/<a href="http://runit_2.1.2.bb" rel="noreferrer" target="_blank">runit_2.1.2.bb</a> b/meta/recipes-core/runit/<a href="http://runit_2.1.2.bb" rel="noreferrer" target="_blank">runit_2.1.2.bb</a><br>
new file mode 100644<br>
index 0000000000..affb309be1<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/<a href="http://runit_2.1.2.bb" rel="noreferrer" target="_blank">runit_2.1.2.bb</a><br>
@@ -0,0 +1,68 @@<br>
+# Copyright (C) 2017 Khem Raj &lt;<a href="mailto:raj.khem@gmail.com" target="_blank">raj.khem@gmail.com</a>&gt;<br>
+# Released under the MIT license (see COPYING.MIT for the terms)<br>
+<br>
+DESCRIPTION = &quot;A UNIX init scheme with service supervision&quot;<br>
+HOMEPAGE = &quot;<a href="http://smarden.org/runit/" rel="noreferrer" target="_blank">http://smarden.org/runit/</a>&quot;<br>
+LICENSE = &quot;BSD-3-Clause&quot;<br>
+SECTION = &quot;base&quot;<br>
+<br>
+LIC_FILES_CHKSUM = &quot;file://package/COPYING;md5=c9e8a560732fc8b860b6a91341cc603b&quot;<br>
+<br>
+inherit update-alternatives<br>
+<br>
+SRC_URI = &quot;<a href="http://smarden.org/$%7BBPN%7D/$%7BBP%7D.tar.gz" rel="noreferrer" target="_blank">http://smarden.org/${BPN}/${BP}.tar.gz</a> \<br>
+           file://0001-default-directory-for-services-on-Debian-is-etc-servi.diff;striplevel=2 \<br>
+           file://0002-support-etc-runit-nosync-file-to-make-sync-on-shutdow.diff;striplevel=2 \<br>
+           file://0003-utmpset.c-mixes-int32_t-and-time_t.diff;striplevel=2 \<br>
+           file://0004-src-Makefile-don-t-use-static-to-link-runit-runit-ini.diff;striplevel=2 \<br>
+           file://0005-patch-etc-runit-2-for-FHS.patch;striplevel=2 \<br>
+           file://0006-make-buildsystem-respect-CFLAGS.patch;striplevel=2 \<br>
+           file://0007-move-communication-files.patch;striplevel=2 \<br>
+           file://0008-emulate-sysv-runlevel-5.patch;striplevel=2 \<br>
+           file://0009-fix-error-in-manpage.patch;striplevel=2 \<br>
+           file://patch-make-build-system-print-compilatio.patch;striplevel=2 \<br>
+           file://patch-disable-chkshgrp-test-that-fails-i.patch;striplevel=2 \<br>
+           file://patch-fix-spin-lock-on-systems-with-poor.patch;striplevel=2 \<br>
+           file://cross.patch \<br>
+           file://clearmem.patch \<br>
+           file://svlogd.patch \<br>
+&quot;<br>
+<br>
+SRC_URI[md5sum] = &quot;6c985fbfe3a34608eb3c53dc719172c4&quot;<br>
+SRC_URI[sha256sum] = &quot;6fd0160cb0cf1207de4e66754b6d39750cff14bb0aa66ab49490992c0c47ba18&quot;<br>
+<br>
+S = &quot;${WORKDIR}/admin/${BPN}-${PV}&quot;<br>
+<br>
+do_compile() {<br>
+       cd ${S}/src<br>
+       sed -e &#39;s,sbin/runit,usr/bin/runit,g&#39; -i ${S}/src/runit.h<br>
+       echo &quot;$CC -D_GNU_SOURCE $CFLAGS&quot; &gt;conf-cc<br>
+       echo &quot;$CC $LDFLAGS -Wl,-z -Wl,noexecstack&quot; &gt;conf-ld<br>
+       # change type short to gid_t for getgroups(2) and setgroups(2)<br>
+       sed -i -e &#39;s:short x\[4\];$:gid_t x[4];:&#39; ${S}/src/chkshsgr.c<br>
+       oe_runmake<br>
+<br>
+}<br>
+<br>
+do_install() {<br>
+       cd ${S}/src<br>
+       install -d ${D}${bindir}<br>
+       for f in chpst runit runit-init runsv runsvchdir runsvdir \<br>
+               sv svlogd utmpset; do<br>
+               install -m 0755 $f ${D}${bindir}<br>
+       done<br>
+       install -d ${D}${sysconfdir}/runit<br>
+       for f in 1 2 3 ctrlaltdel; do<br>
+               install -m 0755 ${S}/etc/debian/$f ${D}${sysconfdir}/runit/$f<br>
+       done<br>
+       sed -e &#39;s,rmnologin,rmnologin.sh,g&#39; -i ${D}${sysconfdir}/runit/1<br>
+       ln -s ${localstatedir}/run/runit.stopit ${D}${sysconfdir}/runit/stopit<br>
+        rm -rf ${D}${sysconfdir}/runit/{1,2,3,stopit,ctrlaltdel}<br>
+}<br>
+<br>
+RDEPENDS_${PN} += &quot;runit-serialgetty socklog socklog-services&quot;<br>
+<br>
+ALTERNATIVE_${PN} = &quot;init&quot;<br>
+ALTERNATIVE_TARGET[init] = &quot;${bindir}/runit-init&quot;<br>
+ALTERNATIVE_LINK_NAME[init] = &quot;${base_sbindir}/init&quot;<br>
+ALTERNATIVE_PRIORITY[init] ?= &quot;300&quot;<br>
diff --git a/meta/recipes-core/runit/<a href="http://socklog-services.bb" rel="noreferrer" target="_blank">socklog-services.bb</a> b/meta/recipes-core/runit/<a href="http://socklog-services.bb" rel="noreferrer" target="_blank">socklog-services.bb</a><br>
new file mode 100644<br>
index 0000000000..795bf8f390<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/<a href="http://socklog-services.bb" rel="noreferrer" target="_blank">socklog-services.bb</a><br>
@@ -0,0 +1,23 @@<br>
+# Copyright (C) 2017 Khem Raj &lt;<a href="mailto:raj.khem@gmail.com" target="_blank">raj.khem@gmail.com</a>&gt;<br>
+# Released under the MIT license (see COPYING.MIT for the terms)<br>
+<br>
+DESCRIPTION = &quot;Additional socklog configurations from Void Distro&quot;<br>
+HOMEPAGE = &quot;<a href="https://github.com/void-linux/void-socklog" rel="noreferrer" target="_blank">https://github.com/void-linux/void-socklog</a>&quot;<br>
+LICENSE = &quot;PD&quot;<br>
+LIC_FILES_CHKSUM = &quot;file://nanoklogd.c;beginline=3;endline=6;md5=8c10698c7abd64f01ac4245e2b11ab64&quot;<br>
+SECTION = &quot;base&quot;<br>
+<br>
+PV = &quot;20150726+git${SRCPV}&quot;<br>
+<br>
+SRCREV = &quot;e6b8b91dcd38ebcfbb0d41753d814edf78b06989&quot;<br>
+SRC_URI = &quot;git://<a href="http://github.com/void-linux/socklog-void" rel="noreferrer" target="_blank">github.com/void-linux/socklog-void</a> \<br>
+           file://0001-Use-options-to-cp-to-ensure-proper-mods.patch \<br>
+&quot;<br>
+<br>
+S = &quot;${WORKDIR}/git&quot;<br>
+<br>
+EXTRA_OEMAKE = &quot;PREFIX=${exec_prefix}&quot;<br>
+<br>
+do_install() {<br>
+       oe_runmake DESTDIR=${D} install<br>
+}<br>
diff --git a/meta/recipes-core/runit/socklog-services/0001-Use-options-to-cp-to-ensure-proper-mods.patch b/meta/recipes-core/runit/socklog-services/0001-Use-options-to-cp-to-ensure-proper-mods.patch<br>
new file mode 100644<br>
index 0000000000..edd5bae2ef<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/socklog-services/0001-Use-options-to-cp-to-ensure-proper-mods.patch<br>
@@ -0,0 +1,33 @@<br>
+From b1f46a4d7273ba9b446527dc3f50aa4c318acdd3 Mon Sep 17 00:00:00 2001<br>
+From: Khem Raj &lt;<a href="mailto:raj.khem@gmail.com" target="_blank">raj.khem@gmail.com</a>&gt;<br>
+Date: Fri, 4 Jan 2019 18:15:18 -0800<br>
+Subject: [PATCH] Use options to cp to ensure proper mods<br>
+<br>
+This ensures that permissions are in line when using staged installed in<br>
+OE e.g.<br>
+<br>
+Upstream-Status: Pending<br>
+<br>
+Signed-off-by: Khem Raj &lt;<a href="mailto:raj.khem@gmail.com" target="_blank">raj.khem@gmail.com</a>&gt;<br>
+---<br>
+ Makefile | 4 ++--<br>
+ 1 file changed, 2 insertions(+), 2 deletions(-)<br>
+<br>
+diff --git a/Makefile b/Makefile<br>
+index 4f96b6e..4889229 100644<br>
+--- a/Makefile<br>
++++ b/Makefile<br>
+@@ -5,8 +5,8 @@ install: all<br>
+       install -Dm755 svlogtail ${DESTDIR}/usr/bin/svlogtail<br>
+       install -Dm755 syslog-stripdate ${DESTDIR}/usr/bin/syslog-stripdate<br>
+       mkdir -p ${DESTDIR}/etc ${DESTDIR}/var/log<br>
+-      cp -a sv ${DESTDIR}/etc<br>
+-      cp -a socklog ${DESTDIR}/var/log<br>
++      cp -R --no-dereference --preserve=mode,links sv ${DESTDIR}/etc<br>
++      cp -R --no-dereference --preserve=mode,links socklog ${DESTDIR}/var/log<br>
+ <br>
+ clean:<br>
+       rm -f nanoklogd<br>
+-- <br>
+2.20.1<br>
+<br>
diff --git a/meta/recipes-core/runit/socklog/cross.patch b/meta/recipes-core/runit/socklog/cross.patch<br>
new file mode 100644<br>
index 0000000000..bc0385f54e<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/socklog/cross.patch<br>
@@ -0,0 +1,58 @@<br>
+chskshsgr must be built for the host. <br>
+<br>
+Original at: <a href="https://github.com/void-linux/void-packages/blob/master/srcpkgs/socklog/patches/cross.patch" rel="noreferrer" target="_blank">https://github.com/void-linux/void-packages/blob/master/srcpkgs/socklog/patches/cross.patch</a><br>
+<br>
+Upstream-Status: Inappropriate [Cross-compile Specific]<br>
+Signed-off-by: Khem Raj &lt;<a href="mailto:raj.khem@gmail.com" target="_blank">raj.khem@gmail.com</a>&gt;<br>
+<br>
+--- a/src/Makefile<br>
++++ b/src/Makefile<br>
+@@ -117,11 +117,11 @@ byte_rchr.o: byte.h byte_rchr.c compile<br>
+ byte_zero.o: byte.h byte_zero.c compile<br>
+       ./compile byte_zero.c<br>
+ <br>
+-chkshsgr: chkshsgr.o load<br>
+-      ./load chkshsgr <br>
++chkshsgr: chkshsgr.o loadhost<br>
++      ./loadhost chkshsgr<br>
+ <br>
+-chkshsgr.o: chkshsgr.c compile<br>
+-      ./compile chkshsgr.c<br>
++chkshsgr.o: chkshsgr.c compilehost<br>
++      ./compilehost chkshsgr.c<br>
+ <br>
+ choose: choose.sh warn-auto.sh<br>
+       rm -f choose<br>
+@@ -137,6 +137,11 @@ compile: conf-cc print-cc.sh systype war<br>
+       sh print-cc.sh &gt; compile<br>
+       chmod 555 compile<br>
+ <br>
++compilehost:<br>
++      cat warn-auto.sh &gt; compilehost<br>
++      @echo &#39;gcc -c $${1+&quot;$$@&quot;}&#39; &gt;&gt; compilehost<br>
++      chmod 555 compilehost<br>
++<br>
+ direntry.h: choose compile direntry.h1 direntry.h2 trydrent.c<br>
+       ./choose c trydrent direntry.h1 direntry.h2 &gt; direntry.h<br>
+ <br>
+@@ -198,6 +203,15 @@ load: conf-ld print-ld.sh systype warn-a<br>
+       sh print-ld.sh &gt; load<br>
+       chmod 555 load<br>
+ <br>
++loadhost:<br>
++      rm -f loadhost<br>
++      @echo &gt; loadhost<br>
++      @echo &#39;systype=&quot;`cat systype`&quot;&#39; &gt;&gt; loadhost<br>
++      @echo &#39;cat warn-auto.sh&#39; &gt;&gt; loadhost<br>
++      @echo &#39;main=&quot;$$1&quot;; shift&#39; &gt;&gt; loadhost<br>
++      @echo &#39;gcc -o &quot;$$main&quot; &quot;$$main&quot;.o $${1+&quot;$$@&quot;}&#39; &gt;&gt; loadhost<br>
++      chmod 555 loadhost<br>
++<br>
+ lock_ex.o: compile hasflock.h lock.h lock_ex.c<br>
+       ./compile lock_ex.c<br>
+ <br>
+@@ -410,4 +424,3 @@ wait_nohang.o: compile haswaitp.h wait_n<br>
+ <br>
+ wait_pid.o: compile error.h haswaitp.h wait_pid.c<br>
+       ./compile wait_pid.c<br>
+-<br>
diff --git a/meta/recipes-core/runit/<a href="http://socklog_2.1.0.bb" rel="noreferrer" target="_blank">socklog_2.1.0.bb</a> b/meta/recipes-core/runit/<a href="http://socklog_2.1.0.bb" rel="noreferrer" target="_blank">socklog_2.1.0.bb</a><br>
new file mode 100644<br>
index 0000000000..fc3fbd9826<br>
--- /dev/null<br>
+++ b/meta/recipes-core/runit/<a href="http://socklog_2.1.0.bb" rel="noreferrer" target="_blank">socklog_2.1.0.bb</a><br>
@@ -0,0 +1,32 @@<br>
+# Copyright (C) 2018 Khem Raj &lt;<a href="mailto:raj.khem@gmail.com" target="_blank">raj.khem@gmail.com</a>&gt;<br>
+# Released under the MIT license (see COPYING.MIT for the terms)<br>
+<br>
+SUMMARY = &quot;Small and secure syslogd replacement for use with runit&quot;<br>
+HOMEPAGE = &quot;<a href="http://smarden.org/socklog/" rel="noreferrer" target="_blank">http://smarden.org/socklog/</a>&quot;<br>
+LICENSE = &quot;BSD-3-Clause&quot;<br>
+SECTION = &quot;base&quot;<br>
+<br>
+LIC_FILES_CHKSUM = &quot;file://package/COPYING;md5=c7a77593c4b489904800014396f3f742&quot;<br>
+SRC_URI = &quot;<a href="http://smarden.org/$%7BBPN%7D/$%7BBP%7D.tar.gz" rel="noreferrer" target="_blank">http://smarden.org/${BPN}/${BP}.tar.gz</a> \<br>
+           file://cross.patch \<br>
+&quot;<br>
+SRC_URI[md5sum] = &quot;5d0e8e28c9329ad3af982c5241df9ff1&quot;<br>
+SRC_URI[sha256sum] = &quot;aa869a787ee004da4e5509b5a0031bcc17a4ab4ac650c2ce8d4e488123acb455&quot;<br>
+<br>
+S = &quot;${WORKDIR}/admin/${BPN}-${PV}&quot;<br>
+<br>
+do_compile() {<br>
+       cd ${S}/src<br>
+       echo &quot;$CC -D_GNU_SOURCE $CFLAGS&quot; &gt;conf-cc<br>
+       echo &quot;$CC $LDFLAGS -Wl,-z -Wl,noexecstack&quot; &gt;conf-ld<br>
+       echo &quot;int main() { return 0; }&quot; &gt;${S}/src/chkshsgr.c<br>
+       oe_runmake<br>
+}<br>
+<br>
+do_install() {<br>
+       cd ${S}/src<br>
+       install -d ${D}${bindir}<br>
+       for f in socklog socklog-conf socklog-check uncat tryto; do<br>
+               install -m 0755 $f ${D}${bindir}<br>
+       done<br>
+}<br>
-- <br>
2.25.0<br>
<br>
-- <br>
_______________________________________________<br>
Openembedded-core mailing list<br>
<a href="mailto:Openembedded-core@lists.openembedded.org" target="_blank">Openembedded-core@lists.openembedded.org</a><br>
<a href="http://lists.openembedded.org/mailman/listinfo/openembedded-core" rel="noreferrer" target="_blank">http://lists.openembedded.org/mailman/listinfo/openembedded-core</a><br>
</blockquote></div>