diff options
author | Patrick Williams <patrick@stwcx.xyz> | 2016-08-17 22:31:25 +0300 |
---|---|---|
committer | Patrick Williams <patrick@stwcx.xyz> | 2016-08-22 19:43:26 +0300 |
commit | 60f9d69e016b11c468c98ea75ba0a60c44afbbc4 (patch) | |
tree | ecb49581a9e41a37943c22cd9ef3f63451b20ee7 /import-layers/yocto-poky/meta/recipes-core/busybox | |
parent | e18c61205e0234b03697129c20cc69c9b3940efc (diff) | |
download | openbmc-60f9d69e016b11c468c98ea75ba0a60c44afbbc4.tar.xz |
yocto-poky: Move to import-layers subdir
We are going to import additional layers, so create a subdir to
hold all of the layers that we import with git-subtree.
Change-Id: I6f732153a22be8ca663035c518837e3cc5ec0799
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Diffstat (limited to 'import-layers/yocto-poky/meta/recipes-core/busybox')
46 files changed, 3094 insertions, 0 deletions
diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox.inc b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox.inc new file mode 100644 index 000000000..5e91a263d --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox.inc @@ -0,0 +1,429 @@ +SUMMARY = "Tiny versions of many common UNIX utilities in a single small executable" +DESCRIPTION = "BusyBox combines tiny versions of many common UNIX utilities into a single small executable. It provides minimalist replacements for most of the utilities you usually find in GNU fileutils, shellutils, etc. The utilities in BusyBox generally have fewer options than their full-featured GNU cousins; however, the options that are included provide the expected functionality and behave very much like their GNU counterparts. BusyBox provides a fairly complete POSIX environment for any small or embedded system." +HOMEPAGE = "http://www.busybox.net" +BUGTRACKER = "https://bugs.busybox.net/" + +DEPENDS += "kern-tools-native" + +# bzip2 applet in busybox is based on lightly-modified bzip2 source +# the GPL is version 2 only +LICENSE = "GPLv2 & bzip2" +LIC_FILES_CHKSUM = "file://LICENSE;md5=de10de48642ab74318e893a61105afbb" + +SECTION = "base" + +# Whether to split the suid apps into a seperate binary +BUSYBOX_SPLIT_SUID ?= "1" + +export EXTRA_CFLAGS = "${CFLAGS}" +export EXTRA_LDFLAGS = "${LDFLAGS}" + +# We don't want '-e MAKEFLAGS=' in EXTRA_OEMAKE +EXTRA_OEMAKE = "CC='${CC}' LD='${CCLD}' V=1 ARCH=${TARGET_ARCH} CROSS_COMPILE=${TARGET_PREFIX} SKIP_STRIP=y" + +PACKAGES =+ "${PN}-httpd ${PN}-udhcpd ${PN}-udhcpc ${PN}-syslog ${PN}-mdev ${PN}-hwclock" + +FILES_${PN}-httpd = "${sysconfdir}/init.d/busybox-httpd /srv/www" +FILES_${PN}-syslog = "${sysconfdir}/init.d/syslog* ${sysconfdir}/syslog-startup.conf* ${sysconfdir}/syslog.conf* ${systemd_unitdir}/system/syslog.service ${sysconfdir}/default/busybox-syslog" +FILES_${PN}-mdev = "${sysconfdir}/init.d/mdev ${sysconfdir}/mdev.conf ${sysconfdir}/mdev/*" +FILES_${PN}-udhcpd = "${sysconfdir}/init.d/busybox-udhcpd" +FILES_${PN}-udhcpc = "${sysconfdir}/udhcpc.d ${datadir}/udhcpc" +FILES_${PN}-hwclock = "${sysconfdir}/init.d/hwclock.sh" + +INITSCRIPT_PACKAGES = "${PN}-httpd ${PN}-syslog ${PN}-udhcpd ${PN}-mdev ${PN}-hwclock" + +INITSCRIPT_NAME_${PN}-httpd = "busybox-httpd" +INITSCRIPT_NAME_${PN}-hwclock = "hwclock.sh" +INITSCRIPT_NAME_${PN}-mdev = "mdev" +INITSCRIPT_PARAMS_${PN}-mdev = "start 04 S ." +INITSCRIPT_NAME_${PN}-syslog = "syslog" +INITSCRIPT_NAME_${PN}-udhcpd = "busybox-udhcpd" + +SYSTEMD_PACKAGES = "${PN}-syslog" +SYSTEMD_SERVICE_${PN}-syslog = "busybox-syslog.service" + +CONFFILES_${PN}-syslog = "${sysconfdir}/syslog-startup.conf.${BPN}" +CONFFILES_${PN}-mdev = "${sysconfdir}/mdev.conf" + +RRECOMMENDS_${PN} = "${PN}-syslog ${PN}-udhcpc" + +inherit cml1 systemd update-rc.d ptest + +# internal helper +def busybox_cfg(feature, tokens, cnf, rem): + if type(tokens) == type(""): + tokens = [tokens] + rem.extend(['/^[# ]*' + token + '[ =]/d' for token in tokens]) + if feature: + cnf.extend([token + '=y' for token in tokens]) + else: + cnf.extend(['# ' + token + ' is not set' for token in tokens]) + +# Map distro features to config settings +def features_to_busybox_settings(d): + cnf, rem = ([], []) + busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'ipv6', True, False, d), 'CONFIG_FEATURE_IPV6', cnf, rem) + busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'largefile', True, False, d), 'CONFIG_LFS', cnf, rem) + busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'largefile', True, False, d), 'CONFIG_FDISK_SUPPORT_LARGE_DISKS', cnf, rem) + busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'nls', True, False, d), 'CONFIG_LOCALE_SUPPORT', cnf, rem) + busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'ipv4', True, False, d), 'CONFIG_FEATURE_IFUPDOWN_IPV4', cnf, rem) + busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'ipv6', True, False, d), 'CONFIG_FEATURE_IFUPDOWN_IPV6', cnf, rem) + busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'wifi', True, False, d), 'CONFIG_RFKILL', cnf, rem) + busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'bluetooth', True, False, d), 'CONFIG_RFKILL', cnf, rem) + return "\n".join(cnf), "\n".join(rem) + +# X, Y = ${@features_to_uclibc_settings(d)} +# unfortunately doesn't seem to work with bitbake, workaround: +def features_to_busybox_conf(d): + cnf, rem = features_to_busybox_settings(d) + return cnf +def features_to_busybox_del(d): + cnf, rem = features_to_busybox_settings(d) + return rem + +configmangle = '/CONFIG_EXTRA_CFLAGS/d; \ + ' +OE_FEATURES := "${@features_to_busybox_conf(d)}" +OE_DEL := "${@features_to_busybox_del(d)}" +DO_IPv4 := "${@bb.utils.contains('DISTRO_FEATURES', 'ipv4', 1, 0, d)}" +DO_IPv6 := "${@bb.utils.contains('DISTRO_FEATURES', 'ipv6', 1, 0, d)}" + +python () { + if "${OE_DEL}": + d.setVar('configmangle_append', "${OE_DEL}" + "\n") + if "${OE_FEATURES}": + d.setVar('configmangle_append', + "/^### DISTRO FEATURES$/a\\\n%s\n\n" % + ("\\n".join((d.expand("${OE_FEATURES}").split("\n"))))) + d.setVar('configmangle_append', + "/^### CROSS$/a\\\n%s\n" % + ("\\n".join(["CONFIG_EXTRA_CFLAGS=\"${CFLAGS} ${HOST_CC_ARCH}\"" + ]) + )) +} + +do_prepare_config () { + sed -e '/CONFIG_STATIC/d' \ + < ${WORKDIR}/defconfig > ${S}/.config + echo "# CONFIG_STATIC is not set" >> .config + for i in 'CROSS' 'DISTRO FEATURES'; do echo "### $i"; done >> \ + ${S}/.config + sed -i -e '${configmangle}' ${S}/.config + if test ${DO_IPv4} -eq 0 && test ${DO_IPv6} -eq 0; then + # disable networking applets + mv ${S}/.config ${S}/.config.oe-tmp + awk 'BEGIN{net=0} + /^# Networking Utilities/{net=1} + /^#$/{if(net){net=net+1}} + {if(net==2&&$0 !~ /^#/&&$1){print("# "$1" is not set")}else{print}}' \ + ${S}/.config.oe-tmp > ${S}/.config + fi + sed -i 's/CONFIG_IFUPDOWN_UDHCPC_CMD_OPTIONS="-R -n"/CONFIG_IFUPDOWN_UDHCPC_CMD_OPTIONS="-R -b"/' ${S}/.config +} + +# returns all the elements from the src uri that are .cfg files +def find_cfgs(d): + sources=src_patches(d, True) + sources_list=[] + for s in sources: + if s.endswith('.cfg'): + sources_list.append(s) + + return sources_list + +do_configure () { + do_prepare_config + merge_config.sh -m .config ${@" ".join(find_cfgs(d))} + cml1_do_configure +} + +do_compile() { + unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS + if [ "${BUSYBOX_SPLIT_SUID}" = "1" -a x`grep "CONFIG_FEATURE_INDIVIDUAL=y" .config` = x ]; then + # split the .config into two parts, and make two busybox binaries + cp .config .config.orig + oe_runmake busybox.cfg.suid + oe_runmake busybox.cfg.nosuid + for i in `cat busybox.cfg.suid busybox.cfg.nosuid`; do + echo "# $i is not set" >> .config.disable.apps + done + merge_config.sh -m .config.orig .config.disable.apps + cp .config .config.nonapps + for s in suid nosuid; do + cat busybox.cfg.$s | while read item; do + grep -w "$item" .config.orig + done > .config.app.$s + merge_config.sh -m .config.nonapps .config.app.$s + oe_runmake busybox_unstripped + mv busybox_unstripped busybox.$s + oe_runmake busybox.links + mv busybox.links busybox.links.$s + done + # copy .config.orig back to .config, because the install process may check this file + cp .config.orig .config + # cleanup + rm .config.orig .config.app.suid .config.app.nosuid .config.disable.apps .config.nonapps + else + oe_runmake busybox_unstripped + cp busybox_unstripped busybox + oe_runmake busybox.links + fi +} + +do_install () { + sed -i "s:^/bin/:BASE_BINDIR/:" busybox.links* + sed -i "s:^/sbin/:BASE_SBINDIR/:" busybox.links* + sed -i "s:^/usr/bin/:BINDIR/:" busybox.links* + sed -i "s:^/usr/sbin/:SBINDIR/:" busybox.links* + + sed -i "s:^BASE_BINDIR/:${base_bindir}/:" busybox.links* + sed -i "s:^BASE_SBINDIR/:${base_sbindir}/:" busybox.links* + sed -i "s:^BINDIR/:${bindir}/:" busybox.links* + sed -i "s:^SBINDIR/:${sbindir}/:" busybox.links* + + install -d ${D}${sysconfdir}/init.d + + if ! grep -q "CONFIG_FEATURE_INDIVIDUAL=y" ${B}/.config; then + # Install ${base_bindir}/busybox, and the ${base_bindir}/sh link so the postinst script + # can run. Let update-alternatives handle the rest. + install -d ${D}${base_bindir} + if [ "${BUSYBOX_SPLIT_SUID}" = "1" ]; then + install -m 4755 ${B}/busybox.suid ${D}${base_bindir} + install -m 0755 ${B}/busybox.nosuid ${D}${base_bindir} + install -m 0644 ${S}/busybox.links.suid ${D}${sysconfdir} + install -m 0644 ${S}/busybox.links.nosuid ${D}${sysconfdir} + if grep -q "CONFIG_FEATURE_SH_IS_ASH=y" ${B}/.config; then + ln -sf busybox.nosuid ${D}${base_bindir}/sh + fi + # Keep a default busybox for people who want to invoke busybox directly. + # This is also useful for the on device upgrade. Because we want + # to use the busybox command in postinst. + ln -sf busybox.nosuid ${D}${base_bindir}/busybox + else + if grep -q "CONFIG_FEATURE_SUID=y" ${B}/.config; then + install -m 4755 ${B}/busybox ${D}${base_bindir} + else + install -m 0755 ${B}/busybox ${D}${base_bindir} + fi + install -m 0644 ${S}/busybox.links ${D}${sysconfdir} + if grep -q "CONFIG_FEATURE_SH_IS_ASH=y" ${B}/.config; then + ln -sf busybox ${D}${base_bindir}/sh + fi + # We make this symlink here to eliminate the error when upgrading together + # with busybox-syslog. Without this symlink, the opkg may think of the + # busybox.nosuid as obsolete and remove it, resulting in dead links like + # ${base_bindir}/sed -> ${base_bindir}/busybox.nosuid. This will make upgrading busybox-syslog fail. + # This symlink will be safely deleted in postinst, thus no negative effect. + ln -sf busybox ${D}${base_bindir}/busybox.nosuid + fi + else + install -d ${D}${base_bindir} ${D}${base_sbindir} + install -d ${D}${libdir} ${D}${bindir} ${D}${sbindir} + cat busybox.links | while read FILE; do + NAME=`basename "$FILE"` + install -m 0755 "0_lib/$NAME" "${D}$FILE.${BPN}" + done + # add suid bit where needed + for i in `grep -E "APPLET.*BB_SUID_((MAYBE|REQUIRE))" include/applets.h | grep -v _BB_SUID_DROP | cut -f 3 -d '(' | cut -f 1 -d ','`; do + find ${D} -name $i.${BPN} -exec chmod a+s {} \; + done + install -m 0755 0_lib/libbusybox.so.${PV} ${D}${libdir}/libbusybox.so.${PV} + ln -sf sh.${BPN} ${D}${base_bindir}/sh + ln -sf ln.${BPN} ${D}${base_bindir}/ln + ln -sf test.${BPN} ${D}${bindir}/test + if [ -f ${D}/linuxrc.${BPN} ]; then + mv ${D}/linuxrc.${BPN} ${D}/linuxrc + fi + install -m 0644 ${S}/busybox.links ${D}${sysconfdir} + fi + + if grep -q "CONFIG_SYSLOGD=y" ${B}/.config; then + install -m 0755 ${WORKDIR}/syslog ${D}${sysconfdir}/init.d/syslog.${BPN} + install -m 644 ${WORKDIR}/syslog-startup.conf ${D}${sysconfdir}/syslog-startup.conf.${BPN} + install -m 644 ${WORKDIR}/syslog.conf ${D}${sysconfdir}/syslog.conf.${BPN} + fi + if grep "CONFIG_CROND=y" ${B}/.config; then + install -m 0755 ${WORKDIR}/busybox-cron ${D}${sysconfdir}/init.d/ + fi + if grep "CONFIG_HTTPD=y" ${B}/.config; then + install -m 0755 ${WORKDIR}/busybox-httpd ${D}${sysconfdir}/init.d/ + install -d ${D}/srv/www + fi + if grep "CONFIG_UDHCPD=y" ${B}/.config; then + install -m 0755 ${WORKDIR}/busybox-udhcpd ${D}${sysconfdir}/init.d/ + fi + if grep "CONFIG_HWCLOCK=y" ${B}/.config; then + install -m 0755 ${WORKDIR}/hwclock.sh ${D}${sysconfdir}/init.d/ + fi + if grep "CONFIG_UDHCPC=y" ${B}/.config; then + install -d ${D}${sysconfdir}/udhcpc.d + install -d ${D}${datadir}/udhcpc + install -m 0755 ${WORKDIR}/simple.script ${D}${sysconfdir}/udhcpc.d/50default + sed -i "s:/SBIN_DIR/:${base_sbindir}/:" ${D}${sysconfdir}/udhcpc.d/50default + install -m 0755 ${WORKDIR}/default.script ${D}${datadir}/udhcpc/default.script + fi + if grep "CONFIG_INETD=y" ${B}/.config; then + install -m 0755 ${WORKDIR}/inetd ${D}${sysconfdir}/init.d/inetd.${BPN} + sed -i "s:/usr/sbin/:${sbindir}/:" ${D}${sysconfdir}/init.d/inetd.${BPN} + install -m 0644 ${WORKDIR}/inetd.conf ${D}${sysconfdir}/ + fi + if grep "CONFIG_MDEV=y" ${B}/.config; then + install -m 0755 ${WORKDIR}/mdev ${D}${sysconfdir}/init.d/mdev + if grep "CONFIG_FEATURE_MDEV_CONF=y" ${B}/.config; then + install -m 644 ${WORKDIR}/mdev.conf ${D}${sysconfdir}/mdev.conf + install -d ${D}${sysconfdir}/mdev + install -m 0755 ${WORKDIR}/find-touchscreen.sh ${D}${sysconfdir}/mdev + install -m 0755 ${WORKDIR}/mdev-mount.sh ${D}${sysconfdir}/mdev + fi + fi + if grep "CONFIG_INIT=y" ${B}/.config; then + install -D -m 0777 ${WORKDIR}/rcS ${D}${sysconfdir}/init.d/rcS + install -D -m 0777 ${WORKDIR}/rcK ${D}${sysconfdir}/init.d/rcK + install -D -m 0755 ${WORKDIR}/runlevel ${D}${base_sbindir}/runlevel + if grep "CONFIG_FEATURE_USE_INITTAB=y" ${B}/.config; then + install -D -m 0777 ${WORKDIR}/inittab ${D}${sysconfdir}/inittab + tmp="${SERIAL_CONSOLES}" + for i in $tmp + do + j=`echo ${i} | sed s/\;/\ /g` + label=`echo ${i} | sed -e 's/tty//' -e 's/^.*;//' -e 's/;.*//'` + echo "tty$label::respawn:${base_sbindir}/getty ${j}" >> ${D}${sysconfdir}/inittab + done + fi + fi + + if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then + if grep -q "CONFIG_SYSLOGD=y" ${B}/.config; then + install -d ${D}${systemd_unitdir}/system + sed 's,@base_sbindir@,${base_sbindir},g' < ${WORKDIR}/busybox-syslog.service.in \ + > ${D}${systemd_unitdir}/system/busybox-syslog.service + if [ -f ${WORKDIR}/busybox-syslog.default ] ; then + install -d ${D}${sysconfdir}/default + install -m 0644 ${WORKDIR}/busybox-syslog.default ${D}${sysconfdir}/default/busybox-syslog + fi + ln -sf /dev/null ${D}${systemd_unitdir}/system/syslog.service + fi + if grep -q "CONFIG_KLOGD=y" ${B}/.config; then + install -d ${D}${systemd_unitdir}/system + sed 's,@base_sbindir@,${base_sbindir},g' < ${WORKDIR}/busybox-klogd.service.in \ + > ${D}${systemd_unitdir}/system/busybox-klogd.service + fi + fi + + # Remove the sysvinit specific configuration file for systemd systems to avoid confusion + if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'false', 'true', d)}; then + rm -f ${D}${sysconfdir}/syslog-startup.conf.${BPN} + fi +} + +do_install_ptest () { + cp -r ${B}/testsuite ${D}${PTEST_PATH}/ + cp ${B}/.config ${D}${PTEST_PATH}/ + ln -s /bin/busybox ${D}${PTEST_PATH}/busybox +} + +inherit update-alternatives + +ALTERNATIVE_PRIORITY = "50" + +ALTERNATIVE_${PN}-syslog += "syslog-conf" +ALTERNATIVE_LINK_NAME[syslog-conf] = "${sysconfdir}/syslog.conf" + +python () { + if bb.utils.contains('DISTRO_FEATURES', 'sysvinit', True, False, d): + pn = d.getVar('PN', True) + d.appendVar('ALTERNATIVE_%s-syslog' % (pn), ' syslog-init') + d.setVarFlag('ALTERNATIVE_LINK_NAME', 'syslog-init', '%s/init.d/syslog' % (d.getVar('sysconfdir', True))) + d.setVarFlag('ALTERNATIVE_TARGET', 'syslog-init', '%s/init.d/syslog.%s' % (d.getVar('sysconfdir', True), d.getVar('BPN', True))) + d.appendVar('ALTERNATIVE_%s-syslog' % (pn), ' syslog-startup-conf') + d.setVarFlag('ALTERNATIVE_LINK_NAME', 'syslog-startup-conf', '%s/syslog-startup.conf' % (d.getVar('sysconfdir', True))) + d.setVarFlag('ALTERNATIVE_TARGET', 'syslog-startup-conf', '%s/syslog-startup.conf.%s' % (d.getVar('sysconfdir', True), d.getVar('BPN', True))) +} + +python do_package_prepend () { + # We need to load the full set of busybox provides from the /etc/busybox.links + # Use this to see the update-alternatives with the right information + + dvar = d.getVar('D', True) + pn = d.getVar('PN', True) + def set_alternative_vars(links, target): + links = d.expand(links) + target = d.expand(target) + f = open('%s%s' % (dvar, links), 'r') + for alt_link_name in f: + alt_link_name = alt_link_name.strip() + alt_name = os.path.basename(alt_link_name) + # Match coreutils + if alt_name == '[': + alt_name = 'lbracket' + d.appendVar('ALTERNATIVE_%s' % (pn), ' ' + alt_name) + d.setVarFlag('ALTERNATIVE_LINK_NAME', alt_name, alt_link_name) + if os.path.exists('%s%s' % (dvar, target)): + d.setVarFlag('ALTERNATIVE_TARGET', alt_name, target) + f.close() + return + + if os.path.exists('%s/etc/busybox.links' % (dvar)): + set_alternative_vars("${sysconfdir}/busybox.links", "${base_bindir}/busybox") + else: + set_alternative_vars("${sysconfdir}/busybox.links.nosuid", "${base_bindir}/busybox.nosuid") + set_alternative_vars("${sysconfdir}/busybox.links.suid", "${base_bindir}/busybox.suid") +} + +pkg_postinst_${PN} () { + # This part of code is dedicated to the on target upgrade problem. + # It's known that if we don't make appropriate symlinks before update-alternatives calls, + # there will be errors indicating missing commands such as 'sed'. + # These symlinks will later be updated by update-alternatives calls. + test -n 2 > /dev/null || alias test='busybox test' + if test "x$D" = "x"; then + # Remove busybox.nosuid if it's a symlink, because this situation indicates + # that we're installing or upgrading to a one-binary busybox. + if test -h ${base_bindir}/busybox.nosuid; then + rm -f ${base_bindir}/busybox.nosuid + fi + for suffix in "" ".nosuid" ".suid"; do + if test -e ${sysconfdir}/busybox.links$suffix; then + while read link; do + if test ! -e "$link"; then + # we can use busybox here because even if we are using splitted busybox + # we've made a symlink from /bin/busybox to /bin/busybox.nosuid. + busybox rm -f $link + busybox ln -s "${base_bindir}/busybox$suffix" $link + fi + done < ${sysconfdir}/busybox.links$suffix + fi + done + fi +} + +pkg_prerm_${PN} () { + # This is so you can make busybox commit suicide - removing busybox with no other packages + # providing its files, this will make update-alternatives work, but the update-rc.d part + # for syslog, httpd and/or udhcpd will fail if there is no other package providing sh + tmpdir=`mktemp -d /tmp/busyboxrm-XXXXXX` + ln -s ${base_bindir}/busybox $tmpdir/[ + ln -s ${base_bindir}/busybox $tmpdir/test + ln -s ${base_bindir}/busybox $tmpdir/head + ln -s ${base_bindir}/busybox $tmpdir/sh + ln -s ${base_bindir}/busybox $tmpdir/basename + ln -s ${base_bindir}/busybox $tmpdir/echo + ln -s ${base_bindir}/busybox $tmpdir/mv + ln -s ${base_bindir}/busybox $tmpdir/ln + ln -s ${base_bindir}/busybox $tmpdir/dirname + ln -s ${base_bindir}/busybox $tmpdir/rm + ln -s ${base_bindir}/busybox $tmpdir/sed + ln -s ${base_bindir}/busybox $tmpdir/sort + ln -s ${base_bindir}/busybox $tmpdir/grep + ln -s ${base_bindir}/busybox $tmpdir/tail + export PATH=$PATH:$tmpdir +} + +pkg_prerm_${PN}-syslog () { + # remove syslog + if test "x$D" = "x"; then + if test "$1" = "upgrade" -o "$1" = "remove"; then + ${sysconfdir}/init.d/syslog stop + fi + fi +} diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/0001-Use-CC-when-linking-instead-of-LD-and-use-CFLAGS-and.patch b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/0001-Use-CC-when-linking-instead-of-LD-and-use-CFLAGS-and.patch new file mode 100644 index 000000000..2bf2b91c7 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/0001-Use-CC-when-linking-instead-of-LD-and-use-CFLAGS-and.patch @@ -0,0 +1,114 @@ +From a9333eb6a7b8dbda735947cd5bc981ff9352a2c9 Mon Sep 17 00:00:00 2001 +From: Nathan Phillip Brink <ohnobinki@ohnopublishing.net> +Date: Thu, 10 Mar 2011 00:27:08 -0500 +Subject: [PATCH 1/2] Use $(CC) when linking instead of $(LD) and use $(CFLAGS) + and $(EXTRA_CFLAGS) when linking. + +This fixes the issue where LDFLAGS escaped with -Wl are ignored during +compilation. It also simplifies using CFLAGS or EXTRA_CFLAGS (such as +-m32 on x86_64 or -flto) which apply to both compilation and linking +situations. + +Signed-off-by: Nathan Phillip Brink <ohnobinki@ohnopublishing.net> +--- +Upstream-Status: Pending + + Makefile | 7 ++++--- + scripts/Makefile.build | 8 ++++---- + scripts/Makefile.lib | 13 +++---------- + 3 files changed, 11 insertions(+), 17 deletions(-) + +Index: busybox-1.23.2/Makefile +=================================================================== +--- busybox-1.23.2.orig/Makefile ++++ busybox-1.23.2/Makefile +@@ -309,7 +309,8 @@ CHECKFLAGS := -D__linux__ -Dlinux -D + MODFLAGS = -DMODULE + CFLAGS_MODULE = $(MODFLAGS) + AFLAGS_MODULE = $(MODFLAGS) +-LDFLAGS_MODULE = -r ++LDFLAGS_RELOCATABLE = -r -nostdlib ++LDFLAGS_MODULE = $(LDFLAGS_RELOCATABLE) + CFLAGS_KERNEL = + AFLAGS_KERNEL = + +@@ -331,7 +332,7 @@ KERNELVERSION = $(VERSION).$(PATCHLEVEL) + export VERSION PATCHLEVEL SUBLEVEL KERNELRELEASE KERNELVERSION \ + ARCH CONFIG_SHELL HOSTCC HOSTCFLAGS CROSS_COMPILE AS LD CC \ + CPP AR NM STRIP OBJCOPY OBJDUMP MAKE AWK GENKSYMS PERL UTS_MACHINE \ +- HOSTCXX HOSTCXXFLAGS LDFLAGS_MODULE CHECK CHECKFLAGS ++ HOSTCXX HOSTCXXFLAGS LDFLAGS_RELOCATABLE LDFLAGS_MODULE CHECK CHECKFLAGS + + export CPPFLAGS NOSTDINC_FLAGS LINUXINCLUDE OBJCOPYFLAGS LDFLAGS + export CFLAGS CFLAGS_KERNEL CFLAGS_MODULE +@@ -610,7 +611,7 @@ quiet_cmd_busybox__ ?= LINK $@ + cmd_busybox__ ?= $(srctree)/scripts/trylink \ + "$@" \ + "$(CC)" \ +- "$(CFLAGS) $(CFLAGS_busybox)" \ ++ "$(CFLAGS) $(CFLAGS_busybox) $(EXTRA_CFLAGS)" \ + "$(LDFLAGS) $(EXTRA_LDFLAGS)" \ + "$(core-y)" \ + "$(libs-y)" \ +Index: busybox-1.23.2/scripts/Makefile.build +=================================================================== +--- busybox-1.23.2.orig/scripts/Makefile.build ++++ busybox-1.23.2/scripts/Makefile.build +@@ -174,7 +174,7 @@ cmd_modversions = \ + | $(GENKSYMS) -a $(ARCH) \ + > $(@D)/.tmp_$(@F:.o=.ver); \ + \ +- $(LD) $(LDFLAGS) -r -o $@ $(@D)/.tmp_$(@F) \ ++ $(CC) $(ld_flags_partial) $(LDFLAGS_RELOCATABLE) -o $@ $(@D)/.tmp_$(@F) \ + -T $(@D)/.tmp_$(@F:.o=.ver); \ + rm -f $(@D)/.tmp_$(@F) $(@D)/.tmp_$(@F:.o=.ver); \ + else \ +@@ -257,7 +257,7 @@ quiet_cmd_link_o_target = LD $@ + # If the list of objects to link is empty, just create an empty built-in.o + # -nostdlib is added to make "make LD=gcc ..." work (some people use that) + cmd_link_o_target = $(if $(strip $(obj-y)),\ +- $(LD) -nostdlib $(ld_flags) -r -o $@ $(filter $(obj-y), $^),\ ++ $(CC) $(ld_flags_partial) $(LDFLAGS_RELOCATABLE) -o $@ $(filter $(obj-y), $^),\ + rm -f $@; $(AR) rcs $@) + + $(builtin-target): $(obj-y) FORCE +@@ -292,10 +292,10 @@ $($(subst $(obj)/,,$(@:.o=-objs))) \ + $($(subst $(obj)/,,$(@:.o=-y)))), $^) + + quiet_cmd_link_multi-y = LD $@ +-cmd_link_multi-y = $(LD) $(ld_flags) -r -o $@ $(link_multi_deps) ++cmd_link_multi-y = $(CC) $(ld_flags_partial) $(LDFLAGS_RELOCATABLE) -o $@ $(link_multi_deps) + + quiet_cmd_link_multi-m = LD [M] $@ +-cmd_link_multi-m = $(LD) $(ld_flags) $(LDFLAGS_MODULE) -o $@ $(link_multi_deps) ++cmd_link_multi-m = $(CC) $(ld_flags) $(LDFLAGS_MODULE) -o $@ $(link_multi_deps) + + # We would rather have a list of rules like + # foo.o: $(foo-objs) +Index: busybox-1.23.2/scripts/Makefile.lib +=================================================================== +--- busybox-1.23.2.orig/scripts/Makefile.lib ++++ busybox-1.23.2/scripts/Makefile.lib +@@ -121,7 +121,8 @@ cpp_flags = -Wp,-MD,$(depfile) $(NO + # yet ld_flags is fed to ld. + #ld_flags = $(LDFLAGS) $(EXTRA_LDFLAGS) + # Remove the -Wl, prefix from linker options normally passed through gcc +-ld_flags = $(filter-out -Wl$(comma)%,$(LDFLAGS) $(EXTRA_LDFLAGS)) ++ld_flags = $(filter-out -Wl$(comma)%,$(LDFLAGS) $(EXTRA_LDFLAGS) $(CFLAGS) $(EXTRA_CFLAGS)) ++ld_flags_partial = $($(filter-out -shared%, $(filter-out -pie%,$(ld_flags)))) + + + # Finds the multi-part object the current object will be linked into +@@ -151,10 +152,8 @@ $(obj)/%:: $(src)/%_shipped + # Linking + # --------------------------------------------------------------------------- + +-# TODO: LDFLAGS usually is supposed to contain gcc's flags, not ld's. +-# but here we feed them to ld! +-quiet_cmd_ld = LD $@ +-cmd_ld = $(LD) $(LDFLAGS) $(EXTRA_LDFLAGS) $(LDFLAGS_$(@F)) \ ++quiet_cmd_ld = CC $@ ++cmd_ld = $(CC) $(ld_flags) $(LDFLAGS_$(@F)) \ + $(filter-out FORCE,$^) -o $@ + + # Objcopy diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-1.24.1-truncate-open-mode.patch b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-1.24.1-truncate-open-mode.patch new file mode 100644 index 000000000..cdc91082b --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-1.24.1-truncate-open-mode.patch @@ -0,0 +1,81 @@ +Upstream-Status: Backport + + http://busybox.net/downloads/fixes-1.24.1/ + https://git.busybox.net/busybox/commit/?id=e111a1640494fe87fc913f94fae3bb805de0fc99 + https://git.busybox.net/busybox/commit/?h=1_24_stable&id=be729c1d3b5c923f10871dd68ea94156d0f8c803 + +Signed-off-by: Andre McCurdy <armccurdy@gmail.com> + +From be729c1d3b5c923f10871dd68ea94156d0f8c803 Mon Sep 17 00:00:00 2001 +From: Ari Sundholm <ari@tuxera.com> +Date: Mon, 4 Jan 2016 15:40:37 +0200 +Subject: [PATCH] truncate: always set mode when opening file to avoid fortify + errors + +Busybox crashes due to no mode being given when opening: +$ ./busybox truncate -s 1M foo +*** invalid open64 call: O_CREAT without mode ***: ./busybox terminated +======= Backtrace: ========= +/lib/x86_64-linux-gnu/libc.so.6(+0x7338f)[0x7f66d921338f] +/lib/x86_64-linux-gnu/libc.so.6(__fortify_fail+0x5c)[0x7f66d92aac9c] +/lib/x86_64-linux-gnu/libc.so.6(+0xeb6aa)[0x7f66d928b6aa] +./busybox[0x4899f9] +======= Memory map: ======== +00400000-004d0000 r-xp 00000000 00:1a 137559 /home/ari/busybox/busybox +006cf000-006d0000 r--p 000cf000 00:1a 137559 /home/ari/busybox/busybox +006d0000-006d1000 rw-p 000d0000 00:1a 137559 /home/ari/busybox/busybox +006d1000-006d4000 rw-p 00000000 00:00 0 +014e7000-01508000 rw-p 00000000 00:00 0 [heap] +7f66d8f8a000-7f66d8fa0000 r-xp 00000000 08:07 1579008 /lib/x86_64-linux-gnu/libgcc_s.so.1 +7f66d8fa0000-7f66d919f000 ---p 00016000 08:07 1579008 /lib/x86_64-linux-gnu/libgcc_s.so.1 +7f66d919f000-7f66d91a0000 rw-p 00015000 08:07 1579008 /lib/x86_64-linux-gnu/libgcc_s.so.1 +7f66d91a0000-7f66d935b000 r-xp 00000000 08:07 1578994 /lib/x86_64-linux-gnu/libc-2.19.so +7f66d935b000-7f66d955a000 ---p 001bb000 08:07 1578994 /lib/x86_64-linux-gnu/libc-2.19.so +7f66d955a000-7f66d955e000 r--p 001ba000 08:07 1578994 /lib/x86_64-linux-gnu/libc-2.19.so +7f66d955e000-7f66d9560000 rw-p 001be000 08:07 1578994 /lib/x86_64-linux-gnu/libc-2.19.so +7f66d9560000-7f66d9565000 rw-p 00000000 00:00 0 +7f66d9565000-7f66d966a000 r-xp 00000000 08:07 1579020 /lib/x86_64-linux-gnu/libm-2.19.so +7f66d966a000-7f66d9869000 ---p 00105000 08:07 1579020 /lib/x86_64-linux-gnu/libm-2.19.so +7f66d9869000-7f66d986a000 r--p 00104000 08:07 1579020 /lib/x86_64-linux-gnu/libm-2.19.so +7f66d986a000-7f66d986b000 rw-p 00105000 08:07 1579020 /lib/x86_64-linux-gnu/libm-2.19.so +7f66d986b000-7f66d988e000 r-xp 00000000 08:07 1578981 /lib/x86_64-linux-gnu/ld-2.19.so +7f66d9a64000-7f66d9a67000 rw-p 00000000 00:00 0 +7f66d9a8a000-7f66d9a8d000 rw-p 00000000 00:00 0 +7f66d9a8d000-7f66d9a8e000 r--p 00022000 08:07 1578981 /lib/x86_64-linux-gnu/ld-2.19.so +7f66d9a8e000-7f66d9a8f000 rw-p 00023000 08:07 1578981 /lib/x86_64-linux-gnu/ld-2.19.so +7f66d9a8f000-7f66d9a90000 rw-p 00000000 00:00 0 +7ffc47761000-7ffc47782000 rw-p 00000000 00:00 0 [stack] +7ffc477ab000-7ffc477ad000 r-xp 00000000 00:00 0 [vdso] +ffffffffff600000-ffffffffff601000 r-xp 00000000 00:00 0 [vsyscall] +Aborted (core dumped) +$ + +Fix this by simply always setting the mode, as it doesn't hurt even +when O_CREAT is not specified. + +This bug is a regression introduced in fc3e40e, as xopen(), which +was originally used, would automatically set the mode. + +Signed-off-by: Ari Sundholm <ari@tuxera.com> +Signed-off-by: Mike Frysinger <vapier@gentoo.org> +(cherry picked from commit e111a1640494fe87fc913f94fae3bb805de0fc99) +--- + coreutils/truncate.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/coreutils/truncate.c b/coreutils/truncate.c +index e5fa656..4c997bf 100644 +--- a/coreutils/truncate.c ++++ b/coreutils/truncate.c +@@ -64,7 +64,7 @@ int truncate_main(int argc UNUSED_PARAM, char **argv) + + argv += optind; + while (*argv) { +- int fd = open(*argv, flags); ++ int fd = open(*argv, flags, 0666); + if (fd < 0) { + if (errno != ENOENT || !(opts & OPT_NOCREATE)) { + bb_perror_msg("%s: open", *argv); +-- +2.6.2 + diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-1.24.1-unzip-regression.patch b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-1.24.1-unzip-regression.patch new file mode 100644 index 000000000..e3c502091 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-1.24.1-unzip-regression.patch @@ -0,0 +1,143 @@ +Upstream-Status: Backport + + http://busybox.net/downloads/fixes-1.24.1/ + http://git.busybox.net/busybox/commit/?id=092fabcf1df5d46cd22be4ffcd3b871f6180eb9c + http://git.busybox.net/busybox/commit/?h=1_24_stable&id=092fabcf1df5d46cd22be4ffcd3b871f6180eb9c + +Signed-off-by: Andre McCurdy <armccurdy@gmail.com> + +From 092fabcf1df5d46cd22be4ffcd3b871f6180eb9c Mon Sep 17 00:00:00 2001 +From: Denys Vlasenko <vda.linux@googlemail.com> +Date: Fri, 30 Oct 2015 23:41:53 +0100 +Subject: [PATCH] [g]unzip: fix recent breakage. + +Also, do emit error message we so painstakingly pass from gzip internals + +Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com> +(cherry picked from commit 6bd3fff51aa74e2ee2d87887b12182a3b09792ef) +Signed-off-by: Mike Frysinger <vapier@gentoo.org> +--- + archival/libarchive/decompress_gunzip.c | 33 +++++++++++++++++++++------------ + testsuite/unzip.tests | 1 + + 2 files changed, 22 insertions(+), 12 deletions(-) + +diff --git a/archival/libarchive/decompress_gunzip.c b/archival/libarchive/decompress_gunzip.c +index c76fd31..357c9bf 100644 +--- a/archival/libarchive/decompress_gunzip.c ++++ b/archival/libarchive/decompress_gunzip.c +@@ -309,8 +309,7 @@ static int huft_build(const unsigned *b, const unsigned n, + huft_t *q; /* points to current table */ + huft_t r; /* table entry for structure assignment */ + huft_t *u[BMAX]; /* table stack */ +- unsigned v[N_MAX]; /* values in order of bit length */ +- unsigned v_end; ++ unsigned v[N_MAX + 1]; /* values in order of bit length. last v[] is never used */ + int ws[BMAX + 1]; /* bits decoded stack */ + int w; /* bits decoded */ + unsigned x[BMAX + 1]; /* bit offsets, then code stack */ +@@ -365,15 +364,17 @@ static int huft_build(const unsigned *b, const unsigned n, + *xp++ = j; + } + +- /* Make a table of values in order of bit lengths */ ++ /* Make a table of values in order of bit lengths. ++ * To detect bad input, unused v[i]'s are set to invalid value UINT_MAX. ++ * In particular, last v[i] is never filled and must not be accessed. ++ */ ++ memset(v, 0xff, sizeof(v)); + p = b; + i = 0; +- v_end = 0; + do { + j = *p++; + if (j != 0) { + v[x[j]++] = i; +- v_end = x[j]; + } + } while (++i < n); + +@@ -435,7 +436,9 @@ static int huft_build(const unsigned *b, const unsigned n, + + /* set up table entry in r */ + r.b = (unsigned char) (k - w); +- if (p >= v + v_end) { // Was "if (p >= v + n)" but v[] can be shorter! ++ if (/*p >= v + n || -- redundant, caught by the second check: */ ++ *p == UINT_MAX /* do we access uninited v[i]? (see memset(v))*/ ++ ) { + r.e = 99; /* out of values--invalid code */ + } else if (*p < s) { + r.e = (unsigned char) (*p < 256 ? 16 : 15); /* 256 is EOB code */ +@@ -520,8 +523,9 @@ static NOINLINE int inflate_codes(STATE_PARAM_ONLY) + e = t->e; + if (e > 16) + do { +- if (e == 99) +- abort_unzip(PASS_STATE_ONLY);; ++ if (e == 99) { ++ abort_unzip(PASS_STATE_ONLY); ++ } + bb >>= t->b; + k -= t->b; + e -= 16; +@@ -557,8 +561,9 @@ static NOINLINE int inflate_codes(STATE_PARAM_ONLY) + e = t->e; + if (e > 16) + do { +- if (e == 99) ++ if (e == 99) { + abort_unzip(PASS_STATE_ONLY); ++ } + bb >>= t->b; + k -= t->b; + e -= 16; +@@ -824,8 +829,9 @@ static int inflate_block(STATE_PARAM smallint *e) + + b_dynamic >>= 4; + k_dynamic -= 4; +- if (nl > 286 || nd > 30) ++ if (nl > 286 || nd > 30) { + abort_unzip(PASS_STATE_ONLY); /* bad lengths */ ++ } + + /* read in bit-length-code lengths */ + for (j = 0; j < nb; j++) { +@@ -906,12 +912,14 @@ static int inflate_block(STATE_PARAM smallint *e) + bl = lbits; + + i = huft_build(ll, nl, 257, cplens, cplext, &inflate_codes_tl, &bl); +- if (i != 0) ++ if (i != 0) { + abort_unzip(PASS_STATE_ONLY); ++ } + bd = dbits; + i = huft_build(ll + nl, nd, 0, cpdist, cpdext, &inflate_codes_td, &bd); +- if (i != 0) ++ if (i != 0) { + abort_unzip(PASS_STATE_ONLY); ++ } + + /* set up data for inflate_codes() */ + inflate_codes_setup(PASS_STATE bl, bd); +@@ -999,6 +1007,7 @@ inflate_unzip_internal(STATE_PARAM transformer_state_t *xstate) + error_msg = "corrupted data"; + if (setjmp(error_jmp)) { + /* Error from deep inside zip machinery */ ++ bb_error_msg(error_msg); + n = -1; + goto ret; + } +diff --git a/testsuite/unzip.tests b/testsuite/unzip.tests +index ca0a458..d8738a3 100755 +--- a/testsuite/unzip.tests ++++ b/testsuite/unzip.tests +@@ -34,6 +34,7 @@ rm foo.zip + testing "unzip (bad archive)" "uudecode; unzip bad.zip 2>&1; echo \$?" \ + "Archive: bad.zip + inflating: ]3j½r«IK-%Ix ++unzip: corrupted data + unzip: inflate error + 1 + " \ +-- +2.6.2 + diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-1.24.1-unzip.patch b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-1.24.1-unzip.patch new file mode 100644 index 000000000..718672695 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-1.24.1-unzip.patch @@ -0,0 +1,118 @@ +Upstream-Status: Backport + + http://busybox.net/downloads/fixes-1.24.1/ + http://git.busybox.net/busybox/commit/?id=1de25a6e87e0e627aa34298105a3d17c60a1f44e + http://git.busybox.net/busybox/commit/?h=1_24_stable&id=6767af17f11144c7cd3cfe9ef799d7f89a78fe65 + +Signed-off-by: Andre McCurdy <armccurdy@gmail.com> + +From 1de25a6e87e0e627aa34298105a3d17c60a1f44e Mon Sep 17 00:00:00 2001 +From: Denys Vlasenko <vda.linux@googlemail.com> +Date: Mon, 26 Oct 2015 19:33:05 +0100 +Subject: [PATCH] unzip: test for bad archive SEGVing + +function old new delta +huft_build 1296 1300 +4 + +Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com> +--- + archival/libarchive/decompress_gunzip.c | 11 +++++++---- + testsuite/unzip.tests | 23 ++++++++++++++++++++++- + 2 files changed, 29 insertions(+), 5 deletions(-) + +diff --git a/archival/libarchive/decompress_gunzip.c b/archival/libarchive/decompress_gunzip.c +index 7b6f459..30bf451 100644 +--- a/archival/libarchive/decompress_gunzip.c ++++ b/archival/libarchive/decompress_gunzip.c +@@ -305,11 +305,12 @@ static int huft_build(const unsigned *b, const unsigned n, + unsigned i; /* counter, current code */ + unsigned j; /* counter */ + int k; /* number of bits in current code */ +- unsigned *p; /* pointer into c[], b[], or v[] */ ++ const unsigned *p; /* pointer into c[], b[], or v[] */ + huft_t *q; /* points to current table */ + huft_t r; /* table entry for structure assignment */ + huft_t *u[BMAX]; /* table stack */ + unsigned v[N_MAX]; /* values in order of bit length */ ++ unsigned v_end; + int ws[BMAX + 1]; /* bits decoded stack */ + int w; /* bits decoded */ + unsigned x[BMAX + 1]; /* bit offsets, then code stack */ +@@ -324,7 +325,7 @@ static int huft_build(const unsigned *b, const unsigned n, + + /* Generate counts for each bit length */ + memset(c, 0, sizeof(c)); +- p = (unsigned *) b; /* cast allows us to reuse p for pointing to b */ ++ p = b; + i = n; + do { + c[*p]++; /* assume all entries <= BMAX */ +@@ -365,12 +366,14 @@ static int huft_build(const unsigned *b, const unsigned n, + } + + /* Make a table of values in order of bit lengths */ +- p = (unsigned *) b; ++ p = b; + i = 0; ++ v_end = 0; + do { + j = *p++; + if (j != 0) { + v[x[j]++] = i; ++ v_end = x[j]; + } + } while (++i < n); + +@@ -432,7 +435,7 @@ static int huft_build(const unsigned *b, const unsigned n, + + /* set up table entry in r */ + r.b = (unsigned char) (k - w); +- if (p >= v + n) { ++ if (p >= v + v_end) { // Was "if (p >= v + n)" but v[] can be shorter! + r.e = 99; /* out of values--invalid code */ + } else if (*p < s) { + r.e = (unsigned char) (*p < 256 ? 16 : 15); /* 256 is EOB code */ +diff --git a/testsuite/unzip.tests b/testsuite/unzip.tests +index 8677a03..ca0a458 100755 +--- a/testsuite/unzip.tests ++++ b/testsuite/unzip.tests +@@ -7,7 +7,7 @@ + + . ./testing.sh + +-# testing "test name" "options" "expected result" "file input" "stdin" ++# testing "test name" "commands" "expected result" "file input" "stdin" + # file input will be file called "input" + # test can create a file "actual" instead of writing to stdout + +@@ -30,6 +30,27 @@ testing "unzip (subdir only)" "unzip -q foo.zip foo/ && test -d foo && test ! -f + rmdir foo + rm foo.zip + ++# File containing some damaged encrypted stream ++testing "unzip (bad archive)" "uudecode; unzip bad.zip 2>&1; echo \$?" \ ++"Archive: bad.zip ++ inflating: ]3j½r«IK-%Ix ++unzip: inflate error ++1 ++" \ ++"" "\ ++begin-base64 644 bad.zip ++UEsDBBQAAgkIAAAAIQA5AAAANwAAADwAAAAQAAcAXTNqwr1ywqtJGxJLLSVJ ++eCkBD0AdKBk8JzQsIj01JC0/ORJQSwMEFAECCAAAAAAhADoAAAAPAAAANgAA ++AAwAAQASw73Ct1DCokohPXQiNjoUNTUiHRwgLT4WHlBLAQIQABQAAggIAAAA ++oQA5AAAANwAAADwAAAAQQAcADAAAACwAMgCAAAAAAABdM2rCvXLCq0kbEkst ++JUl4KQEPQB0oGSY4Cz4QNgEnJSYIPVBLAQIAABQAAggAAAAAIQAqAAAADwAA ++BDYAAAAMAAEADQAAADIADQAAAEEAAAASw73Ct1DKokohPXQiNzA+FAI1HCcW ++NzITNFBLBQUKAC4JAA04Cw0EOhZQSwUGAQAABAIAAgCZAAAAeQAAAAIALhM= ++==== ++" ++ ++rm * ++ + # Clean up scratch directory. + + cd .. +-- +2.6.2 + diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-cross-menuconfig.patch b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-cross-menuconfig.patch new file mode 100644 index 000000000..bda86859d --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-cross-menuconfig.patch @@ -0,0 +1,71 @@ +From: Jason Wessel <jason.wessel@windriver.com> +Date: Sun, 3 Mar 2013 12:31:40 -0600 +Subject: [PATCH] menuconfig,check-lxdiaglog.sh: Allow specification of ncurses location + +Upstream-Status: Submitted + +[ based on: https://lkml.org/lkml/2013/3/3/103 ] + +This patch syncs up with the way the menuconfig ncurses / curses +is detected and the HOST_EXTRACFLAGS works in the Linux kernel +and it allows the menuconfig to work with a sysroot version +of the curses libraries. + +--- + +In some cross build environments such as the Yocto Project build +environment it provides an ncurses library that is compiled +differently than the host's version. This causes display corruption +problems when the host's curses includes are used instead of the +includes from the provided compiler are overridden. There is a second +case where there is no curses libraries at all on the host system and +menuconfig will just fail entirely. + +The solution is simply to allow an override variable in +check-lxdialog.sh for environments such as the Yocto Project. Adding +a CROSS_CURSES_LIB and CROSS_CURSES_INC solves the issue and allowing +compiling and linking against the right headers and libraries. + +Signed-off-by: Jason Wessel <jason.wessel@windriver.com> +cc: Michal Marek <mmarek@suse.cz> +cc: linux-kbuild@vger.kernel.org +--- + scripts/kconfig/lxdialog/Makefile | 2 +- + scripts/kconfig/lxdialog/check-lxdialog.sh | 8 ++++++++ + 2 files changed, 9 insertions(+), 1 deletion(-) + +--- a/scripts/kconfig/lxdialog/check-lxdialog.sh ++++ b/scripts/kconfig/lxdialog/check-lxdialog.sh +@@ -4,6 +4,10 @@ + # What library to link + ldflags() + { ++ if [ x"$CROSS_CURSES_LIB" != x ]; then ++ echo "$CROSS_CURSES_LIB" ++ exit ++ fi + for ext in so a dylib ; do + for lib in ncursesw ncurses curses ; do + $cc -print-file-name=lib${lib}.${ext} | grep -q / +@@ -19,6 +23,10 @@ ldflags() + # Where is ncurses.h? + ccflags() + { ++ if [ x"$CROSS_CURSES_INC" != x ]; then ++ echo "$CROSS_CURSES_INC" ++ exit ++ fi + if [ -f /usr/include/ncursesw/ncurses.h ]; then + echo '-I/usr/include/ncursesw -DCURSES_LOC="<ncurses.h>"' + elif [ -f /usr/include/ncursesw/curses.h ]; then +--- a/scripts/kconfig/lxdialog/Makefile ++++ b/scripts/kconfig/lxdialog/Makefile +@@ -5,7 +5,7 @@ check-lxdialog := $(srctree)/$(src)/che + + # Use reursively expanded variables so we do not call gcc unless + # we really need to do so. (Do not call gcc as part of make mrproper) +-HOST_EXTRACFLAGS = $(shell $(CONFIG_SHELL) $(check-lxdialog) -ccflags) ++HOST_EXTRACFLAGS += $(shell $(CONFIG_SHELL) $(check-lxdialog) -ccflags) + HOST_LOADLIBES = $(shell $(CONFIG_SHELL) $(check-lxdialog) -ldflags $(HOSTCC)) + + HOST_EXTRACFLAGS += -DLOCALE diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-udhcpc-no_deconfig.patch b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-udhcpc-no_deconfig.patch new file mode 100644 index 000000000..4c9ce3b71 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/busybox-udhcpc-no_deconfig.patch @@ -0,0 +1,137 @@ +From 53626cd06a3ef05ed847daea802ef0aa9661caa7 Mon Sep 17 00:00:00 2001 +From: Anders Darander <anders@chargestorm.se> +Date: Thu, 3 Nov 2011 08:51:31 +0100 +Subject: [PATCH] busybox-udhcpc-no_deconfig.patch + +Upstream-Status: Pending + +Add a new option -D to the udhcpc client that allows for +dhcp renewal to occur without having to down the interface +in the process. + +Signed-off-by: Greg Moffatt <greg.moffatt@windriver.com> + +Updated to latest Busybox 1.17.3 + +Signed-off-by: Mark Hatle <mark.hatle@windriver.com> + +Updated to Busybox 1.18.4 +option spec is changed + +Signed-off-by: Qing He <qing.he@intel.com> + +Updated to Busybox 1.19.3 + +Signed-off-by: Anders Darander <anders@chargestorm.se> + +Fixed options -b, -a and -P. + +Signed-off-by: Andreas Oberritter <obi@opendreambox.org> +--- + networking/udhcp/dhcpc.c | 29 +++++++++++++++++++++-------- + 1 files changed, 21 insertions(+), 8 deletions(-) + +Index: busybox-1.20.2/networking/udhcp/dhcpc.c +=================================================================== +--- busybox-1.20.2.orig/networking/udhcp/dhcpc.c ++++ busybox-1.20.2/networking/udhcp/dhcpc.c +@@ -29,6 +29,9 @@ + #include <netpacket/packet.h> + #include <linux/filter.h> + ++/* option whether to down the interface when reconfiguring */ ++static int allow_deconfig = 1; ++ + /* "struct client_config_t client_config" is in bb_common_bufsiz1 */ + + +@@ -81,8 +84,9 @@ enum { + OPT_x = 1 << 18, + OPT_f = 1 << 19, + OPT_B = 1 << 20, ++ OPT_D = 1 << 21, + /* The rest has variable bit positions, need to be clever */ +- OPTBIT_B = 20, ++ OPTBIT_D = 21, + USE_FOR_MMU( OPTBIT_b,) + IF_FEATURE_UDHCPC_ARPING(OPTBIT_a,) + IF_FEATURE_UDHCP_PORT( OPTBIT_P,) +@@ -1040,7 +1044,8 @@ static void perform_renew(void) + state = RENEW_REQUESTED; + break; + case RENEW_REQUESTED: /* impatient are we? fine, square 1 */ +- udhcp_run_script(NULL, "deconfig"); ++ if (allow_deconfig) ++ udhcp_run_script(NULL, "deconfig"); + case REQUESTING: + case RELEASED: + change_listen_mode(LISTEN_RAW); +@@ -1064,7 +1069,8 @@ static void perform_release(uint32_t ser + bb_info_msg("Unicasting a release of %s to %s", + inet_ntoa(temp_addr), buffer); + send_release(server_addr, requested_ip); /* unicast */ +- udhcp_run_script(NULL, "deconfig"); ++ if (allow_deconfig) ++ udhcp_run_script(NULL, "deconfig"); + } + bb_info_msg("Entering released state"); + +@@ -1215,7 +1221,7 @@ int udhcpc_main(int argc UNUSED_PARAM, c + /* O,x: list; -T,-t,-A take numeric param */ + opt_complementary = "O::x::T+:t+:A+" IF_UDHCP_VERBOSE(":vv") ; + IF_LONG_OPTS(applet_long_options = udhcpc_longopts;) +- opt = getopt32(argv, "CV:H:h:F:i:np:qRr:s:T:t:SA:O:ox:fB" ++ opt = getopt32(argv, "CV:H:h:F:i:np:qRr:s:T:t:SA:O:ox:fBD" + USE_FOR_MMU("b") + IF_FEATURE_UDHCPC_ARPING("a") + IF_FEATURE_UDHCP_PORT("P:") +@@ -1316,6 +1322,9 @@ int udhcpc_main(int argc UNUSED_PARAM, c + logmode |= LOGMODE_SYSLOG; + } + ++ if (opt & OPT_D) ++ allow_deconfig = 0; ++ + /* Make sure fd 0,1,2 are open */ + bb_sanitize_stdio(); + /* Equivalent of doing a fflush after every \n */ +@@ -1330,7 +1339,8 @@ int udhcpc_main(int argc UNUSED_PARAM, c + srand(monotonic_us()); + + state = INIT_SELECTING; +- udhcp_run_script(NULL, "deconfig"); ++ if (allow_deconfig) ++ udhcp_run_script(NULL, "deconfig"); + change_listen_mode(LISTEN_RAW); + packet_num = 0; + timeout = 0; +@@ -1484,7 +1494,8 @@ int udhcpc_main(int argc UNUSED_PARAM, c + } + /* Timed out, enter init state */ + bb_info_msg("Lease lost, entering init state"); +- udhcp_run_script(NULL, "deconfig"); ++ if (allow_deconfig) ++ udhcp_run_script(NULL, "deconfig"); + state = INIT_SELECTING; + client_config.first_secs = 0; /* make secs field count from 0 */ + /*timeout = 0; - already is */ +@@ -1667,7 +1678,8 @@ int udhcpc_main(int argc UNUSED_PARAM, c + send_decline(/*xid,*/ server_addr, packet.yiaddr); + + if (state != REQUESTING) +- udhcp_run_script(NULL, "deconfig"); ++ if (allow_deconfig) ++ udhcp_run_script(NULL, "deconfig"); + change_listen_mode(LISTEN_RAW); + state = INIT_SELECTING; + client_config.first_secs = 0; /* make secs field count from 0 */ +@@ -1711,7 +1723,8 @@ int udhcpc_main(int argc UNUSED_PARAM, c + bb_info_msg("Received DHCP NAK"); + udhcp_run_script(&packet, "nak"); + if (state != REQUESTING) +- udhcp_run_script(NULL, "deconfig"); ++ if (allow_deconfig) ++ udhcp_run_script(NULL, "deconfig"); + change_listen_mode(LISTEN_RAW); + sleep(3); /* avoid excessive network traffic */ + state = INIT_SELECTING; diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/defconfig b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/defconfig new file mode 100644 index 000000000..ffea6be87 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/defconfig @@ -0,0 +1,1069 @@ +# +# Automatically generated make config: don't edit +# Busybox version: 1.24.1 +# Tue Oct 31 11:00:00 2015 +# +CONFIG_HAVE_DOT_CONFIG=y + +# +# Busybox Settings +# + +# +# General Configuration +# +# CONFIG_DESKTOP is not set +# CONFIG_EXTRA_COMPAT is not set +# CONFIG_INCLUDE_SUSv2 is not set +# CONFIG_USE_PORTABLE_CODE is not set +CONFIG_PLATFORM_LINUX=y +CONFIG_FEATURE_BUFFERS_USE_MALLOC=y +# CONFIG_FEATURE_BUFFERS_GO_ON_STACK is not set +# CONFIG_FEATURE_BUFFERS_GO_IN_BSS is not set +CONFIG_SHOW_USAGE=y +# CONFIG_FEATURE_VERBOSE_USAGE is not set +CONFIG_FEATURE_COMPRESS_USAGE=y +# CONFIG_FEATURE_INSTALLER is not set +# CONFIG_INSTALL_NO_USR is not set +# CONFIG_LOCALE_SUPPORT is not set +# CONFIG_UNICODE_SUPPORT is not set +# CONFIG_UNICODE_USING_LOCALE is not set +# CONFIG_FEATURE_CHECK_UNICODE_IN_ENV is not set +CONFIG_SUBST_WCHAR=0 +CONFIG_LAST_SUPPORTED_WCHAR=0 +# CONFIG_UNICODE_COMBINING_WCHARS is not set +# CONFIG_UNICODE_WIDE_WCHARS is not set +# CONFIG_UNICODE_BIDI_SUPPORT is not set +# CONFIG_UNICODE_NEUTRAL_TABLE is not set +# CONFIG_UNICODE_PRESERVE_BROKEN is not set +# CONFIG_PAM is not set +CONFIG_FEATURE_USE_SENDFILE=y +CONFIG_LONG_OPTS=y +CONFIG_FEATURE_DEVPTS=y +# CONFIG_FEATURE_CLEAN_UP is not set +CONFIG_FEATURE_UTMP=y +# CONFIG_FEATURE_WTMP is not set +CONFIG_FEATURE_PIDFILE=y +CONFIG_PID_FILE_PATH="/var/run" +CONFIG_FEATURE_SUID=y +CONFIG_FEATURE_SUID_CONFIG=y +CONFIG_FEATURE_SUID_CONFIG_QUIET=y +# CONFIG_SELINUX is not set +# CONFIG_FEATURE_PREFER_APPLETS is not set +CONFIG_BUSYBOX_EXEC_PATH="/proc/self/exe" +CONFIG_FEATURE_SYSLOG=y +# CONFIG_FEATURE_HAVE_RPC is not set + +# +# Build Options +# +# CONFIG_STATIC is not set +# CONFIG_PIE is not set +# CONFIG_NOMMU is not set +# CONFIG_BUILD_LIBBUSYBOX is not set +# CONFIG_FEATURE_INDIVIDUAL is not set +# CONFIG_FEATURE_SHARED_BUSYBOX is not set +CONFIG_LFS=y +CONFIG_CROSS_COMPILER_PREFIX="" +CONFIG_SYSROOT="" +CONFIG_EXTRA_CFLAGS="" +CONFIG_EXTRA_LDFLAGS="" +CONFIG_EXTRA_LDLIBS="" + +# +# Debugging Options +# +# CONFIG_DEBUG is not set +# CONFIG_DEBUG_PESSIMIZE is not set +# CONFIG_UNIT_TEST is not set +# CONFIG_WERROR is not set +CONFIG_NO_DEBUG_LIB=y +# CONFIG_DMALLOC is not set +# CONFIG_EFENCE is not set + +# +# Installation Options ("make install" behavior) +# +CONFIG_INSTALL_APPLET_SYMLINKS=y +# CONFIG_INSTALL_APPLET_HARDLINKS is not set +# CONFIG_INSTALL_APPLET_SCRIPT_WRAPPERS is not set +# CONFIG_INSTALL_APPLET_DONT is not set +# CONFIG_INSTALL_SH_APPLET_SYMLINK is not set +# CONFIG_INSTALL_SH_APPLET_HARDLINK is not set +# CONFIG_INSTALL_SH_APPLET_SCRIPT_WRAPPER is not set +CONFIG_PREFIX="./_install" + +# +# Busybox Library Tuning +# +CONFIG_FEATURE_SYSTEMD=y +CONFIG_FEATURE_RTMINMAX=y +CONFIG_PASSWORD_MINLEN=6 +CONFIG_MD5_SMALL=1 +CONFIG_SHA3_SMALL=1 +CONFIG_FEATURE_FAST_TOP=y +# CONFIG_FEATURE_ETC_NETWORKS is not set +CONFIG_FEATURE_USE_TERMIOS=y +CONFIG_FEATURE_EDITING=y +CONFIG_FEATURE_EDITING_MAX_LEN=1024 +# CONFIG_FEATURE_EDITING_VI is not set +CONFIG_FEATURE_EDITING_HISTORY=15 +CONFIG_FEATURE_EDITING_SAVEHISTORY=y +# CONFIG_FEATURE_EDITING_SAVE_ON_EXIT is not set +# CONFIG_FEATURE_REVERSE_SEARCH is not set +CONFIG_FEATURE_TAB_COMPLETION=y +CONFIG_FEATURE_USERNAME_COMPLETION=y +CONFIG_FEATURE_EDITING_FANCY_PROMPT=y +# CONFIG_FEATURE_EDITING_ASK_TERMINAL is not set +CONFIG_FEATURE_NON_POSIX_CP=y +# CONFIG_FEATURE_VERBOSE_CP_MESSAGE is not set +CONFIG_FEATURE_COPYBUF_KB=4 +CONFIG_FEATURE_SKIP_ROOTFS=y +CONFIG_MONOTONIC_SYSCALL=y +CONFIG_IOCTL_HEX2STR_ERROR=y +CONFIG_FEATURE_HWIB=y + +# +# Applets +# + +# +# Archival Utilities +# +CONFIG_FEATURE_SEAMLESS_XZ=y +CONFIG_FEATURE_SEAMLESS_LZMA=y +CONFIG_FEATURE_SEAMLESS_BZ2=y +CONFIG_FEATURE_SEAMLESS_GZ=y +CONFIG_FEATURE_SEAMLESS_Z=y +CONFIG_AR=y +# CONFIG_FEATURE_AR_LONG_FILENAMES is not set +# CONFIG_FEATURE_AR_CREATE is not set +# CONFIG_UNCOMPRESS is not set +CONFIG_GUNZIP=y +CONFIG_BUNZIP2=y +# CONFIG_UNLZMA is not set +# CONFIG_FEATURE_LZMA_FAST is not set +# CONFIG_LZMA is not set +# CONFIG_UNXZ is not set +# CONFIG_XZ is not set +# CONFIG_BZIP2 is not set +CONFIG_CPIO=y +# CONFIG_FEATURE_CPIO_O is not set +# CONFIG_FEATURE_CPIO_P is not set +# CONFIG_DPKG is not set +# CONFIG_DPKG_DEB is not set +# CONFIG_FEATURE_DPKG_DEB_EXTRACT_ONLY is not set +CONFIG_GZIP=y +# CONFIG_FEATURE_GZIP_LONG_OPTIONS is not set +CONFIG_GZIP_FAST=0 +# CONFIG_FEATURE_GZIP_LEVELS is not set +# CONFIG_LZOP is not set +# CONFIG_LZOP_COMPR_HIGH is not set +# CONFIG_RPM is not set +# CONFIG_RPM2CPIO is not set +CONFIG_TAR=y +CONFIG_FEATURE_TAR_CREATE=y +CONFIG_FEATURE_TAR_AUTODETECT=y +CONFIG_FEATURE_TAR_FROM=y +CONFIG_FEATURE_TAR_OLDGNU_COMPATIBILITY=y +# CONFIG_FEATURE_TAR_OLDSUN_COMPATIBILITY is not set +CONFIG_FEATURE_TAR_GNU_EXTENSIONS=y +# CONFIG_FEATURE_TAR_LONG_OPTIONS is not set +# CONFIG_FEATURE_TAR_TO_COMMAND is not set +# CONFIG_FEATURE_TAR_UNAME_GNAME is not set +CONFIG_FEATURE_TAR_NOPRESERVE_TIME=y +# CONFIG_FEATURE_TAR_SELINUX is not set +CONFIG_UNZIP=y + +# +# Coreutils +# +CONFIG_BASENAME=y +CONFIG_CAT=y +CONFIG_DATE=y +# CONFIG_FEATURE_DATE_ISOFMT is not set +# CONFIG_FEATURE_DATE_NANO is not set +CONFIG_FEATURE_DATE_COMPAT=y +CONFIG_DD=y +CONFIG_FEATURE_DD_SIGNAL_HANDLING=y +# CONFIG_FEATURE_DD_THIRD_STATUS_LINE is not set +# CONFIG_FEATURE_DD_IBS_OBS is not set +# CONFIG_FEATURE_DD_STATUS is not set +# CONFIG_HOSTID is not set +CONFIG_ID=y +CONFIG_GROUPS=y +CONFIG_SHUF=y +CONFIG_SYNC=y +# CONFIG_FEATURE_SYNC_FANCY is not set +CONFIG_TEST=y +CONFIG_FEATURE_TEST_64=y +CONFIG_TOUCH=y +CONFIG_FEATURE_TOUCH_NODEREF=y +CONFIG_FEATURE_TOUCH_SUSV3=y +CONFIG_TR=y +CONFIG_FEATURE_TR_CLASSES=y +# CONFIG_FEATURE_TR_EQUIV is not set +# CONFIG_TRUNCATE is not set +CONFIG_UNLINK=y +# CONFIG_BASE64 is not set +CONFIG_WHO=y +CONFIG_USERS=y +# CONFIG_CAL is not set +# CONFIG_CATV is not set +CONFIG_CHGRP=y +CONFIG_CHMOD=y +CONFIG_CHOWN=y +# CONFIG_FEATURE_CHOWN_LONG_OPTIONS is not set +CONFIG_CHROOT=y +# CONFIG_CKSUM is not set +# CONFIG_COMM is not set +CONFIG_CP=y +# CONFIG_FEATURE_CP_LONG_OPTIONS is not set +CONFIG_CUT=y +CONFIG_DF=y +# CONFIG_FEATURE_DF_FANCY is not set +CONFIG_DIRNAME=y +# CONFIG_DOS2UNIX is not set +# CONFIG_UNIX2DOS is not set +CONFIG_DU=y +CONFIG_FEATURE_DU_DEFAULT_BLOCKSIZE_1K=y +CONFIG_ECHO=y +CONFIG_FEATURE_FANCY_ECHO=y +CONFIG_ENV=y +CONFIG_FEATURE_ENV_LONG_OPTIONS=y +# CONFIG_EXPAND is not set +# CONFIG_FEATURE_EXPAND_LONG_OPTIONS is not set +CONFIG_EXPR=y +CONFIG_EXPR_MATH_SUPPORT_64=y +CONFIG_FALSE=y +# CONFIG_FOLD is not set +# CONFIG_FSYNC is not set +CONFIG_HEAD=y +# CONFIG_FEATURE_FANCY_HEAD is not set +# CONFIG_INSTALL is not set +# CONFIG_FEATURE_INSTALL_LONG_OPTIONS is not set +CONFIG_LN=y +CONFIG_LOGNAME=y +CONFIG_LS=y +CONFIG_FEATURE_LS_FILETYPES=y +CONFIG_FEATURE_LS_FOLLOWLINKS=y +CONFIG_FEATURE_LS_RECURSIVE=y +CONFIG_FEATURE_LS_SORTFILES=y +CONFIG_FEATURE_LS_TIMESTAMPS=y +CONFIG_FEATURE_LS_USERNAME=y +CONFIG_FEATURE_LS_COLOR=y +# CONFIG_FEATURE_LS_COLOR_IS_DEFAULT is not set +CONFIG_MD5SUM=y +CONFIG_MKDIR=y +CONFIG_FEATURE_MKDIR_LONG_OPTIONS=y +CONFIG_MKFIFO=y +CONFIG_MKNOD=y +CONFIG_MV=y +# CONFIG_FEATURE_MV_LONG_OPTIONS is not set +# CONFIG_NICE is not set +CONFIG_NOHUP=y +CONFIG_OD=y +# CONFIG_PRINTENV is not set +CONFIG_PRINTF=y +CONFIG_PWD=y +CONFIG_READLINK=y +CONFIG_FEATURE_READLINK_FOLLOW=y +CONFIG_REALPATH=y +CONFIG_RM=y +CONFIG_RMDIR=y +# CONFIG_FEATURE_RMDIR_LONG_OPTIONS is not set +CONFIG_SEQ=y +# CONFIG_SHA1SUM is not set +# CONFIG_SHA256SUM is not set +# CONFIG_SHA512SUM is not set +# CONFIG_SHA3SUM is not set +CONFIG_SLEEP=y +CONFIG_FEATURE_FANCY_SLEEP=y +# CONFIG_FEATURE_FLOAT_SLEEP is not set +CONFIG_SORT=y +CONFIG_FEATURE_SORT_BIG=y +# CONFIG_SPLIT is not set +# CONFIG_FEATURE_SPLIT_FANCY is not set +CONFIG_STAT=y +CONFIG_FEATURE_STAT_FORMAT=y +CONFIG_STTY=y +# CONFIG_SUM is not set +# CONFIG_TAC is not set +CONFIG_TAIL=y +CONFIG_FEATURE_FANCY_TAIL=y +CONFIG_TEE=y +# CONFIG_FEATURE_TEE_USE_BLOCK_IO is not set +CONFIG_TRUE=y +CONFIG_TTY=y +CONFIG_UNAME=y +CONFIG_UNAME_OSNAME="GNU/Linux" +# CONFIG_UNEXPAND is not set +# CONFIG_FEATURE_UNEXPAND_LONG_OPTIONS is not set +CONFIG_UNIQ=y +CONFIG_USLEEP=y +# CONFIG_UUDECODE is not set +# CONFIG_UUENCODE is not set +CONFIG_WC=y +# CONFIG_FEATURE_WC_LARGE is not set +CONFIG_WHOAMI=y +CONFIG_YES=y + +# +# Common options +# +CONFIG_FEATURE_VERBOSE=y + +# +# Common options for cp and mv +# +# CONFIG_FEATURE_PRESERVE_HARDLINKS is not set + +# +# Common options for ls, more and telnet +# +CONFIG_FEATURE_AUTOWIDTH=y + +# +# Common options for df, du, ls +# +CONFIG_FEATURE_HUMAN_READABLE=y + +# +# Common options for md5sum, sha1sum, sha256sum, sha512sum, sha3sum +# +CONFIG_FEATURE_MD5_SHA1_SUM_CHECK=y + +# +# Console Utilities +# +CONFIG_CHVT=y +# CONFIG_FGCONSOLE is not set +CONFIG_CLEAR=y +CONFIG_DEALLOCVT=y +CONFIG_DUMPKMAP=y +# CONFIG_KBD_MODE is not set +CONFIG_LOADFONT=y +CONFIG_LOADKMAP=y +CONFIG_OPENVT=y +CONFIG_RESET=y +# CONFIG_RESIZE is not set +# CONFIG_FEATURE_RESIZE_PRINT is not set +CONFIG_SETCONSOLE=y +# CONFIG_FEATURE_SETCONSOLE_LONG_OPTIONS is not set +# CONFIG_SETFONT is not set +# CONFIG_FEATURE_SETFONT_TEXTUAL_MAP is not set +CONFIG_DEFAULT_SETFONT_DIR="" +# CONFIG_SETKEYCODES is not set +# CONFIG_SETLOGCONS is not set +# CONFIG_SHOWKEY is not set + +# +# Common options for loadfont and setfont +# +# CONFIG_FEATURE_LOADFONT_PSF2 is not set +# CONFIG_FEATURE_LOADFONT_RAW is not set + +# +# Debian Utilities +# +CONFIG_MKTEMP=y +# CONFIG_PIPE_PROGRESS is not set +CONFIG_RUN_PARTS=y +CONFIG_FEATURE_RUN_PARTS_LONG_OPTIONS=y +# CONFIG_FEATURE_RUN_PARTS_FANCY is not set +CONFIG_START_STOP_DAEMON=y +CONFIG_FEATURE_START_STOP_DAEMON_FANCY=y +CONFIG_FEATURE_START_STOP_DAEMON_LONG_OPTIONS=y +CONFIG_WHICH=y + +# +# Editors +# +CONFIG_AWK=y +CONFIG_FEATURE_AWK_LIBM=y +CONFIG_FEATURE_AWK_GNU_EXTENSIONS=y +CONFIG_CMP=y +CONFIG_DIFF=y +# CONFIG_FEATURE_DIFF_LONG_OPTIONS is not set +CONFIG_FEATURE_DIFF_DIR=y +# CONFIG_ED is not set +CONFIG_PATCH=y +CONFIG_SED=y +CONFIG_VI=y +CONFIG_FEATURE_VI_MAX_LEN=1024 +CONFIG_FEATURE_VI_8BIT=y +CONFIG_FEATURE_VI_COLON=y +CONFIG_FEATURE_VI_YANKMARK=y +CONFIG_FEATURE_VI_SEARCH=y +# CONFIG_FEATURE_VI_REGEX_SEARCH is not set +CONFIG_FEATURE_VI_USE_SIGNALS=y +# CONFIG_FEATURE_VI_DOT_CMD is not set +# CONFIG_FEATURE_VI_READONLY is not set +# CONFIG_FEATURE_VI_SETOPTS is not set +# CONFIG_FEATURE_VI_SET is not set +CONFIG_FEATURE_VI_WIN_RESIZE=y +# CONFIG_FEATURE_VI_ASK_TERMINAL is not set +CONFIG_FEATURE_VI_UNDO=y +CONFIG_FEATURE_VI_UNDO_QUEUE=y +CONFIG_FEATURE_VI_UNDO_QUEUE_MAX=256 +CONFIG_FEATURE_ALLOW_EXEC=y + +# +# Finding Utilities +# +CONFIG_FIND=y +CONFIG_FEATURE_FIND_PRINT0=y +CONFIG_FEATURE_FIND_MTIME=y +CONFIG_FEATURE_FIND_MMIN=y +CONFIG_FEATURE_FIND_PERM=y +CONFIG_FEATURE_FIND_TYPE=y +CONFIG_FEATURE_FIND_XDEV=y +CONFIG_FEATURE_FIND_MAXDEPTH=y +CONFIG_FEATURE_FIND_NEWER=y +# CONFIG_FEATURE_FIND_INUM is not set +CONFIG_FEATURE_FIND_EXEC=y +CONFIG_FEATURE_FIND_EXEC_PLUS=y +CONFIG_FEATURE_FIND_USER=y +CONFIG_FEATURE_FIND_GROUP=y +CONFIG_FEATURE_FIND_NOT=y +CONFIG_FEATURE_FIND_DEPTH=y +CONFIG_FEATURE_FIND_PAREN=y +CONFIG_FEATURE_FIND_SIZE=y +CONFIG_FEATURE_FIND_PRUNE=y +# CONFIG_FEATURE_FIND_DELETE is not set +CONFIG_FEATURE_FIND_PATH=y +CONFIG_FEATURE_FIND_REGEX=y +# CONFIG_FEATURE_FIND_CONTEXT is not set +# CONFIG_FEATURE_FIND_LINKS is not set +CONFIG_GREP=y +CONFIG_FEATURE_GREP_EGREP_ALIAS=y +CONFIG_FEATURE_GREP_FGREP_ALIAS=y +CONFIG_FEATURE_GREP_CONTEXT=y +CONFIG_XARGS=y +# CONFIG_FEATURE_XARGS_SUPPORT_CONFIRMATION is not set +# CONFIG_FEATURE_XARGS_SUPPORT_QUOTES is not set +# CONFIG_FEATURE_XARGS_SUPPORT_TERMOPT is not set +# CONFIG_FEATURE_XARGS_SUPPORT_ZERO_TERM is not set +CONFIG_FEATURE_XARGS_SUPPORT_REPL_STR=y + +# +# Init Utilities +# +# CONFIG_BOOTCHARTD is not set +# CONFIG_FEATURE_BOOTCHARTD_BLOATED_HEADER is not set +# CONFIG_FEATURE_BOOTCHARTD_CONFIG_FILE is not set +CONFIG_HALT=y +# CONFIG_FEATURE_CALL_TELINIT is not set +CONFIG_TELINIT_PATH="" +# CONFIG_INIT is not set +# CONFIG_FEATURE_USE_INITTAB is not set +# CONFIG_FEATURE_KILL_REMOVED is not set +CONFIG_FEATURE_KILL_DELAY=0 +# CONFIG_FEATURE_INIT_SCTTY is not set +# CONFIG_FEATURE_INIT_SYSLOG is not set +# CONFIG_FEATURE_EXTRA_QUIET is not set +# CONFIG_FEATURE_INIT_COREDUMPS is not set +# CONFIG_FEATURE_INITRD is not set +CONFIG_INIT_TERMINAL_TYPE="" +CONFIG_MESG=y +# CONFIG_FEATURE_MESG_ENABLE_ONLY_GROUP is not set + +# +# Login/Password Management Utilities +# +# CONFIG_ADD_SHELL is not set +# CONFIG_REMOVE_SHELL is not set +# CONFIG_FEATURE_SHADOWPASSWDS is not set +# CONFIG_USE_BB_PWD_GRP is not set +# CONFIG_USE_BB_SHADOW is not set +CONFIG_USE_BB_CRYPT=y +# CONFIG_USE_BB_CRYPT_SHA is not set +# CONFIG_ADDUSER is not set +# CONFIG_FEATURE_ADDUSER_LONG_OPTIONS is not set +# CONFIG_FEATURE_CHECK_NAMES is not set +CONFIG_LAST_ID=60000 +CONFIG_FIRST_SYSTEM_ID=100 +CONFIG_LAST_SYSTEM_ID=999 +# CONFIG_ADDGROUP is not set +# CONFIG_FEATURE_ADDGROUP_LONG_OPTIONS is not set +# CONFIG_FEATURE_ADDUSER_TO_GROUP is not set +# CONFIG_DELUSER is not set +# CONFIG_DELGROUP is not set +# CONFIG_FEATURE_DEL_USER_FROM_GROUP is not set +# CONFIG_GETTY is not set +# CONFIG_LOGIN is not set +# CONFIG_LOGIN_SESSION_AS_CHILD is not set +# CONFIG_LOGIN_SCRIPTS is not set +# CONFIG_FEATURE_NOLOGIN is not set +# CONFIG_FEATURE_SECURETTY is not set +# CONFIG_PASSWD is not set +# CONFIG_FEATURE_PASSWD_WEAK_CHECK is not set +# CONFIG_CRYPTPW is not set +# CONFIG_CHPASSWD is not set +CONFIG_FEATURE_DEFAULT_PASSWD_ALGO="" +# CONFIG_SU is not set +# CONFIG_FEATURE_SU_SYSLOG is not set +# CONFIG_FEATURE_SU_CHECKS_SHELLS is not set +# CONFIG_SULOGIN is not set +# CONFIG_VLOCK is not set + +# +# Linux Ext2 FS Progs +# +CONFIG_CHATTR=y +CONFIG_FSCK=y +# CONFIG_LSATTR is not set +# CONFIG_TUNE2FS is not set + +# +# Linux Module Utilities +# +# CONFIG_MODINFO is not set +# CONFIG_MODPROBE_SMALL is not set +# CONFIG_FEATURE_MODPROBE_SMALL_OPTIONS_ON_CMDLINE is not set +# CONFIG_FEATURE_MODPROBE_SMALL_CHECK_ALREADY_LOADED is not set +CONFIG_INSMOD=y +CONFIG_RMMOD=y +CONFIG_LSMOD=y +# CONFIG_FEATURE_LSMOD_PRETTY_2_6_OUTPUT is not set +CONFIG_MODPROBE=y +# CONFIG_FEATURE_MODPROBE_BLACKLIST is not set +CONFIG_DEPMOD=y + +# +# Options common to multiple modutils +# +# CONFIG_FEATURE_2_4_MODULES is not set +# CONFIG_FEATURE_INSMOD_TRY_MMAP is not set +# CONFIG_FEATURE_INSMOD_VERSION_CHECKING is not set +# CONFIG_FEATURE_INSMOD_KSYMOOPS_SYMBOLS is not set +# CONFIG_FEATURE_INSMOD_LOADINKMEM is not set +# CONFIG_FEATURE_INSMOD_LOAD_MAP is not set +# CONFIG_FEATURE_INSMOD_LOAD_MAP_FULL is not set +CONFIG_FEATURE_CHECK_TAINTED_MODULE=y +CONFIG_FEATURE_MODUTILS_ALIAS=y +CONFIG_FEATURE_MODUTILS_SYMBOLS=y +CONFIG_DEFAULT_MODULES_DIR="/lib/modules" +CONFIG_DEFAULT_DEPMOD_FILE="modules.dep" + +# +# Linux System Utilities +# +# CONFIG_BLOCKDEV is not set +# CONFIG_FATATTR is not set +CONFIG_FSTRIM=y +# CONFIG_MDEV is not set +# CONFIG_FEATURE_MDEV_CONF is not set +# CONFIG_FEATURE_MDEV_RENAME is not set +# CONFIG_FEATURE_MDEV_RENAME_REGEXP is not set +# CONFIG_FEATURE_MDEV_EXEC is not set +# CONFIG_FEATURE_MDEV_LOAD_FIRMWARE is not set +CONFIG_MOUNT=y +# CONFIG_FEATURE_MOUNT_FAKE is not set +# CONFIG_FEATURE_MOUNT_VERBOSE is not set +# CONFIG_FEATURE_MOUNT_HELPERS is not set +# CONFIG_FEATURE_MOUNT_LABEL is not set +# CONFIG_FEATURE_MOUNT_NFS is not set +# CONFIG_FEATURE_MOUNT_CIFS is not set +CONFIG_FEATURE_MOUNT_FLAGS=y +CONFIG_FEATURE_MOUNT_FSTAB=y +# CONFIG_FEATURE_MOUNT_OTHERTAB is not set +# CONFIG_REV is not set +# CONFIG_UEVENT is not set +# CONFIG_ACPID is not set +# CONFIG_FEATURE_ACPID_COMPAT is not set +# CONFIG_BLKID is not set +# CONFIG_FEATURE_BLKID_TYPE is not set +CONFIG_DMESG=y +CONFIG_FEATURE_DMESG_PRETTY=y +CONFIG_FBSET=y +CONFIG_FEATURE_FBSET_FANCY=y +CONFIG_FEATURE_FBSET_READMODE=y +# CONFIG_FDFLUSH is not set +# CONFIG_FDFORMAT is not set +CONFIG_FDISK=y +# CONFIG_FDISK_SUPPORT_LARGE_DISKS is not set +CONFIG_FEATURE_FDISK_WRITABLE=y +# CONFIG_FEATURE_AIX_LABEL is not set +# CONFIG_FEATURE_SGI_LABEL is not set +# CONFIG_FEATURE_SUN_LABEL is not set +# CONFIG_FEATURE_OSF_LABEL is not set +# CONFIG_FEATURE_GPT_LABEL is not set +# CONFIG_FEATURE_FDISK_ADVANCED is not set +# CONFIG_FINDFS is not set +CONFIG_FLOCK=y +# CONFIG_FREERAMDISK is not set +# CONFIG_FSCK_MINIX is not set +# CONFIG_MKFS_EXT2 is not set +# CONFIG_MKFS_MINIX is not set +# CONFIG_FEATURE_MINIX2 is not set +# CONFIG_MKFS_REISER is not set +# CONFIG_MKFS_VFAT is not set +# CONFIG_GETOPT is not set +# CONFIG_FEATURE_GETOPT_LONG is not set +CONFIG_HEXDUMP=y +# CONFIG_FEATURE_HEXDUMP_REVERSE is not set +# CONFIG_HD is not set +CONFIG_HWCLOCK=y +CONFIG_FEATURE_HWCLOCK_LONG_OPTIONS=y +CONFIG_FEATURE_HWCLOCK_ADJTIME_FHS=y +# CONFIG_IPCRM is not set +# CONFIG_IPCS is not set +CONFIG_LOSETUP=y +# CONFIG_LSPCI is not set +# CONFIG_LSUSB is not set +CONFIG_MKSWAP=y +# CONFIG_FEATURE_MKSWAP_UUID is not set +CONFIG_MORE=y +CONFIG_PIVOT_ROOT=y +CONFIG_RDATE=y +# CONFIG_RDEV is not set +# CONFIG_READPROFILE is not set +# CONFIG_RTCWAKE is not set +# CONFIG_SCRIPT is not set +# CONFIG_SCRIPTREPLAY is not set +# CONFIG_SETARCH is not set +CONFIG_SWAPONOFF=y +CONFIG_FEATURE_SWAPON_DISCARD=y +CONFIG_FEATURE_SWAPON_PRI=y +CONFIG_SWITCH_ROOT=y +CONFIG_UMOUNT=y +CONFIG_FEATURE_UMOUNT_ALL=y + +# +# Common options for mount/umount +# +CONFIG_FEATURE_MOUNT_LOOP=y +CONFIG_FEATURE_MOUNT_LOOP_CREATE=y +# CONFIG_FEATURE_MTAB_SUPPORT is not set +# CONFIG_VOLUMEID is not set +# CONFIG_FEATURE_VOLUMEID_BTRFS is not set +# CONFIG_FEATURE_VOLUMEID_CRAMFS is not set +# CONFIG_FEATURE_VOLUMEID_EXFAT is not set +# CONFIG_FEATURE_VOLUMEID_EXT is not set +# CONFIG_FEATURE_VOLUMEID_F2FS is not set +# CONFIG_FEATURE_VOLUMEID_FAT is not set +# CONFIG_FEATURE_VOLUMEID_HFS is not set +# CONFIG_FEATURE_VOLUMEID_ISO9660 is not set +# CONFIG_FEATURE_VOLUMEID_JFS is not set +# CONFIG_FEATURE_VOLUMEID_LINUXRAID is not set +# CONFIG_FEATURE_VOLUMEID_LINUXSWAP is not set +# CONFIG_FEATURE_VOLUMEID_LUKS is not set +# CONFIG_FEATURE_VOLUMEID_NILFS is not set +# CONFIG_FEATURE_VOLUMEID_NTFS is not set +# CONFIG_FEATURE_VOLUMEID_OCFS2 is not set +# CONFIG_FEATURE_VOLUMEID_REISERFS is not set +# CONFIG_FEATURE_VOLUMEID_ROMFS is not set +# CONFIG_FEATURE_VOLUMEID_SQUASHFS is not set +# CONFIG_FEATURE_VOLUMEID_SYSV is not set +# CONFIG_FEATURE_VOLUMEID_UDF is not set +# CONFIG_FEATURE_VOLUMEID_XFS is not set + +# +# Miscellaneous Utilities +# +# CONFIG_CONSPY is not set +# CONFIG_CROND is not set +# CONFIG_FEATURE_CROND_D is not set +# CONFIG_FEATURE_CROND_CALL_SENDMAIL is not set +CONFIG_FEATURE_CROND_DIR="" +# CONFIG_I2CGET is not set +# CONFIG_I2CSET is not set +# CONFIG_I2CDUMP is not set +# CONFIG_I2CDETECT is not set +CONFIG_LESS=y +CONFIG_FEATURE_LESS_MAXLINES=9999999 +CONFIG_FEATURE_LESS_BRACKETS=y +CONFIG_FEATURE_LESS_FLAGS=y +# CONFIG_FEATURE_LESS_TRUNCATE is not set +# CONFIG_FEATURE_LESS_MARKS is not set +# CONFIG_FEATURE_LESS_REGEXP is not set +# CONFIG_FEATURE_LESS_WINCH is not set +# CONFIG_FEATURE_LESS_ASK_TERMINAL is not set +# CONFIG_FEATURE_LESS_DASHCMD is not set +# CONFIG_FEATURE_LESS_LINENUMS is not set +# CONFIG_NANDWRITE is not set +# CONFIG_NANDDUMP is not set +CONFIG_RFKILL=y +# CONFIG_SETSERIAL is not set +# CONFIG_TASKSET is not set +# CONFIG_FEATURE_TASKSET_FANCY is not set +# CONFIG_UBIATTACH is not set +# CONFIG_UBIDETACH is not set +# CONFIG_UBIMKVOL is not set +# CONFIG_UBIRMVOL is not set +# CONFIG_UBIRSVOL is not set +# CONFIG_UBIUPDATEVOL is not set +# CONFIG_WALL is not set +# CONFIG_ADJTIMEX is not set +# CONFIG_BBCONFIG is not set +# CONFIG_FEATURE_COMPRESS_BBCONFIG is not set +# CONFIG_BEEP is not set +CONFIG_FEATURE_BEEP_FREQ=0 +CONFIG_FEATURE_BEEP_LENGTH_MS=0 +# CONFIG_CHAT is not set +# CONFIG_FEATURE_CHAT_NOFAIL is not set +# CONFIG_FEATURE_CHAT_TTY_HIFI is not set +# CONFIG_FEATURE_CHAT_IMPLICIT_CR is not set +# CONFIG_FEATURE_CHAT_SWALLOW_OPTS is not set +# CONFIG_FEATURE_CHAT_SEND_ESCAPES is not set +# CONFIG_FEATURE_CHAT_VAR_ABORT_LEN is not set +# CONFIG_FEATURE_CHAT_CLR_ABORT is not set +# CONFIG_CHRT is not set +# CONFIG_CRONTAB is not set +CONFIG_DC=y +# CONFIG_FEATURE_DC_LIBM is not set +# CONFIG_DEVFSD is not set +# CONFIG_DEVFSD_MODLOAD is not set +# CONFIG_DEVFSD_FG_NP is not set +# CONFIG_DEVFSD_VERBOSE is not set +# CONFIG_FEATURE_DEVFS is not set +# CONFIG_DEVMEM is not set +# CONFIG_EJECT is not set +# CONFIG_FEATURE_EJECT_SCSI is not set +# CONFIG_FBSPLASH is not set +# CONFIG_FLASHCP is not set +# CONFIG_FLASH_LOCK is not set +# CONFIG_FLASH_UNLOCK is not set +# CONFIG_FLASH_ERASEALL is not set +# CONFIG_IONICE is not set +# CONFIG_INOTIFYD is not set +# CONFIG_LAST is not set +# CONFIG_FEATURE_LAST_SMALL is not set +# CONFIG_FEATURE_LAST_FANCY is not set +# CONFIG_HDPARM is not set +# CONFIG_FEATURE_HDPARM_GET_IDENTITY is not set +# CONFIG_FEATURE_HDPARM_HDIO_SCAN_HWIF is not set +# CONFIG_FEATURE_HDPARM_HDIO_UNREGISTER_HWIF is not set +# CONFIG_FEATURE_HDPARM_HDIO_DRIVE_RESET is not set +# CONFIG_FEATURE_HDPARM_HDIO_TRISTATE_HWIF is not set +# CONFIG_FEATURE_HDPARM_HDIO_GETSET_DMA is not set +# CONFIG_MAKEDEVS is not set +# CONFIG_FEATURE_MAKEDEVS_LEAF is not set +# CONFIG_FEATURE_MAKEDEVS_TABLE is not set +# CONFIG_MAN is not set +CONFIG_MICROCOM=y +# CONFIG_MOUNTPOINT is not set +# CONFIG_MT is not set +# CONFIG_RAIDAUTORUN is not set +# CONFIG_READAHEAD is not set +# CONFIG_RUNLEVEL is not set +# CONFIG_RX is not set +# CONFIG_SETSID is not set +CONFIG_STRINGS=y +CONFIG_TIME=y +# CONFIG_TIMEOUT is not set +# CONFIG_TTYSIZE is not set +# CONFIG_VOLNAME is not set +# CONFIG_WATCHDOG is not set + +# +# Networking Utilities +# +# CONFIG_NAMEIF is not set +# CONFIG_FEATURE_NAMEIF_EXTENDED is not set +# CONFIG_NBDCLIENT is not set +CONFIG_NC=y +# CONFIG_NC_SERVER is not set +# CONFIG_NC_EXTRA is not set +# CONFIG_NC_110_COMPAT is not set +CONFIG_PING=y +CONFIG_PING6=y +CONFIG_FEATURE_FANCY_PING=y +CONFIG_WGET=y +CONFIG_FEATURE_WGET_STATUSBAR=y +CONFIG_FEATURE_WGET_AUTHENTICATION=y +CONFIG_FEATURE_WGET_LONG_OPTIONS=y +CONFIG_FEATURE_WGET_TIMEOUT=y +# CONFIG_FEATURE_WGET_OPENSSL is not set +# CONFIG_FEATURE_WGET_SSL_HELPER is not set +# CONFIG_WHOIS is not set +CONFIG_FEATURE_IPV6=y +# CONFIG_FEATURE_UNIX_LOCAL is not set +CONFIG_FEATURE_PREFER_IPV4_ADDRESS=y +# CONFIG_VERBOSE_RESOLUTION_ERRORS is not set +# CONFIG_ARP is not set +# CONFIG_ARPING is not set +# CONFIG_BRCTL is not set +# CONFIG_FEATURE_BRCTL_FANCY is not set +# CONFIG_FEATURE_BRCTL_SHOW is not set +# CONFIG_DNSD is not set +# CONFIG_ETHER_WAKE is not set +# CONFIG_FAKEIDENTD is not set +# CONFIG_FTPD is not set +# CONFIG_FEATURE_FTP_WRITE is not set +# CONFIG_FEATURE_FTPD_ACCEPT_BROKEN_LIST is not set +# CONFIG_FEATURE_FTP_AUTHENTICATION is not set +# CONFIG_FTPGET is not set +# CONFIG_FTPPUT is not set +# CONFIG_FEATURE_FTPGETPUT_LONG_OPTIONS is not set +CONFIG_HOSTNAME=y +# CONFIG_HTTPD is not set +# CONFIG_FEATURE_HTTPD_RANGES is not set +# CONFIG_FEATURE_HTTPD_SETUID is not set +# CONFIG_FEATURE_HTTPD_BASIC_AUTH is not set +# CONFIG_FEATURE_HTTPD_AUTH_MD5 is not set +# CONFIG_FEATURE_HTTPD_CGI is not set +# CONFIG_FEATURE_HTTPD_CONFIG_WITH_SCRIPT_INTERPR is not set +# CONFIG_FEATURE_HTTPD_SET_REMOTE_PORT_TO_ENV is not set +# CONFIG_FEATURE_HTTPD_ENCODE_URL_STR is not set +# CONFIG_FEATURE_HTTPD_ERROR_PAGES is not set +# CONFIG_FEATURE_HTTPD_PROXY is not set +# CONFIG_FEATURE_HTTPD_GZIP is not set +CONFIG_IFCONFIG=y +CONFIG_FEATURE_IFCONFIG_STATUS=y +# CONFIG_FEATURE_IFCONFIG_SLIP is not set +# CONFIG_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ is not set +CONFIG_FEATURE_IFCONFIG_HW=y +# CONFIG_FEATURE_IFCONFIG_BROADCAST_PLUS is not set +# CONFIG_IFENSLAVE is not set +# CONFIG_IFPLUGD is not set +CONFIG_IFUPDOWN=y +CONFIG_IFUPDOWN_IFSTATE_PATH="/var/run/ifstate" +# CONFIG_FEATURE_IFUPDOWN_IP is not set +# CONFIG_FEATURE_IFUPDOWN_IP_BUILTIN is not set +CONFIG_FEATURE_IFUPDOWN_IFCONFIG_BUILTIN=y +CONFIG_FEATURE_IFUPDOWN_IPV4=y +CONFIG_FEATURE_IFUPDOWN_IPV6=y +CONFIG_FEATURE_IFUPDOWN_MAPPING=y +CONFIG_FEATURE_IFUPDOWN_EXTERNAL_DHCP=y +# CONFIG_INETD is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_ECHO is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_DISCARD is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_TIME is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_DAYTIME is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_CHARGEN is not set +# CONFIG_FEATURE_INETD_RPC is not set +CONFIG_IP=y +CONFIG_FEATURE_IP_ADDRESS=y +CONFIG_FEATURE_IP_LINK=y +CONFIG_FEATURE_IP_ROUTE=y +CONFIG_FEATURE_IP_ROUTE_DIR="/etc/iproute2" +CONFIG_FEATURE_IP_TUNNEL=y +# CONFIG_FEATURE_IP_RULE is not set +# CONFIG_FEATURE_IP_SHORT_FORMS is not set +# CONFIG_FEATURE_IP_RARE_PROTOCOLS is not set +# CONFIG_IPADDR is not set +# CONFIG_IPLINK is not set +# CONFIG_IPROUTE is not set +# CONFIG_IPTUNNEL is not set +# CONFIG_IPRULE is not set +# CONFIG_IPCALC is not set +# CONFIG_FEATURE_IPCALC_FANCY is not set +# CONFIG_FEATURE_IPCALC_LONG_OPTIONS is not set +CONFIG_NETSTAT=y +# CONFIG_FEATURE_NETSTAT_WIDE is not set +# CONFIG_FEATURE_NETSTAT_PRG is not set +CONFIG_NSLOOKUP=y +# CONFIG_NTPD is not set +# CONFIG_FEATURE_NTPD_SERVER is not set +# CONFIG_FEATURE_NTPD_CONF is not set +# CONFIG_PSCAN is not set +CONFIG_ROUTE=y +# CONFIG_SLATTACH is not set +# CONFIG_TCPSVD is not set +CONFIG_TELNET=y +# CONFIG_FEATURE_TELNET_TTYPE is not set +CONFIG_FEATURE_TELNET_AUTOLOGIN=y +# CONFIG_TELNETD is not set +# CONFIG_FEATURE_TELNETD_STANDALONE is not set +# CONFIG_FEATURE_TELNETD_INETD_WAIT is not set +CONFIG_TFTP=y +# CONFIG_TFTPD is not set + +# +# Common options for tftp/tftpd +# +CONFIG_FEATURE_TFTP_GET=y +CONFIG_FEATURE_TFTP_PUT=y +# CONFIG_FEATURE_TFTP_BLOCKSIZE is not set +# CONFIG_FEATURE_TFTP_PROGRESS_BAR is not set +# CONFIG_TFTP_DEBUG is not set +CONFIG_TRACEROUTE=y +# CONFIG_TRACEROUTE6 is not set +# CONFIG_FEATURE_TRACEROUTE_VERBOSE is not set +# CONFIG_FEATURE_TRACEROUTE_SOURCE_ROUTE is not set +# CONFIG_FEATURE_TRACEROUTE_USE_ICMP is not set +# CONFIG_TUNCTL is not set +# CONFIG_FEATURE_TUNCTL_UG is not set +# CONFIG_UDHCPC6 is not set +CONFIG_UDHCPD=y +# CONFIG_DHCPRELAY is not set +CONFIG_DUMPLEASES=y +# CONFIG_FEATURE_UDHCPD_WRITE_LEASES_EARLY is not set +# CONFIG_FEATURE_UDHCPD_BASE_IP_ON_MAC is not set +CONFIG_DHCPD_LEASES_FILE="/var/lib/misc/udhcpd.leases" +CONFIG_UDHCPC=y +CONFIG_FEATURE_UDHCPC_ARPING=y +CONFIG_FEATURE_UDHCPC_SANITIZEOPT=y +# CONFIG_FEATURE_UDHCP_PORT is not set +CONFIG_UDHCP_DEBUG=0 +# CONFIG_FEATURE_UDHCP_RFC3397 is not set +# CONFIG_FEATURE_UDHCP_8021Q is not set +CONFIG_UDHCPC_DEFAULT_SCRIPT="/usr/share/udhcpc/default.script" +CONFIG_UDHCPC_SLACK_FOR_BUGGY_SERVERS=80 +CONFIG_IFUPDOWN_UDHCPC_CMD_OPTIONS="-R -n" +# CONFIG_UDPSVD is not set +# CONFIG_VCONFIG is not set +# CONFIG_ZCIP is not set + +# +# Print Utilities +# +# CONFIG_LPD is not set +# CONFIG_LPR is not set +# CONFIG_LPQ is not set + +# +# Mail Utilities +# +# CONFIG_MAKEMIME is not set +CONFIG_FEATURE_MIME_CHARSET="" +# CONFIG_POPMAILDIR is not set +# CONFIG_FEATURE_POPMAILDIR_DELIVERY is not set +# CONFIG_REFORMIME is not set +# CONFIG_FEATURE_REFORMIME_COMPAT is not set +# CONFIG_SENDMAIL is not set + +# +# Process Utilities +# +# CONFIG_IOSTAT is not set +# CONFIG_LSOF is not set +# CONFIG_MPSTAT is not set +# CONFIG_NMETER is not set +# CONFIG_PMAP is not set +# CONFIG_POWERTOP is not set +# CONFIG_PSTREE is not set +# CONFIG_PWDX is not set +# CONFIG_SMEMCAP is not set +CONFIG_TOP=y +CONFIG_FEATURE_TOP_CPU_USAGE_PERCENTAGE=y +CONFIG_FEATURE_TOP_CPU_GLOBAL_PERCENTS=y +# CONFIG_FEATURE_TOP_SMP_CPU is not set +# CONFIG_FEATURE_TOP_DECIMALS is not set +# CONFIG_FEATURE_TOP_SMP_PROCESS is not set +# CONFIG_FEATURE_TOPMEM is not set +CONFIG_UPTIME=y +# CONFIG_FEATURE_UPTIME_UTMP_SUPPORT is not set +CONFIG_FREE=y +CONFIG_FUSER=y +CONFIG_KILL=y +CONFIG_KILLALL=y +# CONFIG_KILLALL5 is not set +# CONFIG_PGREP is not set +CONFIG_PIDOF=y +# CONFIG_FEATURE_PIDOF_SINGLE is not set +# CONFIG_FEATURE_PIDOF_OMIT is not set +# CONFIG_PKILL is not set +CONFIG_PS=y +CONFIG_FEATURE_PS_WIDE=y +CONFIG_FEATURE_PS_LONG=y +# CONFIG_FEATURE_PS_TIME is not set +# CONFIG_FEATURE_PS_ADDITIONAL_COLUMNS is not set +# CONFIG_FEATURE_PS_UNUSUAL_SYSTEMS is not set +CONFIG_RENICE=y +CONFIG_BB_SYSCTL=y +# CONFIG_FEATURE_SHOW_THREADS is not set +CONFIG_WATCH=y + +# +# Runit Utilities +# +# CONFIG_RUNSV is not set +# CONFIG_RUNSVDIR is not set +# CONFIG_FEATURE_RUNSVDIR_LOG is not set +# CONFIG_SV is not set +CONFIG_SV_DEFAULT_SERVICE_DIR="" +# CONFIG_SVLOGD is not set +# CONFIG_CHPST is not set +# CONFIG_SETUIDGID is not set +# CONFIG_ENVUIDGID is not set +# CONFIG_ENVDIR is not set +# CONFIG_SOFTLIMIT is not set +# CONFIG_CHCON is not set +# CONFIG_FEATURE_CHCON_LONG_OPTIONS is not set +# CONFIG_GETENFORCE is not set +# CONFIG_GETSEBOOL is not set +# CONFIG_LOAD_POLICY is not set +# CONFIG_MATCHPATHCON is not set +# CONFIG_RESTORECON is not set +# CONFIG_RUNCON is not set +# CONFIG_FEATURE_RUNCON_LONG_OPTIONS is not set +# CONFIG_SELINUXENABLED is not set +# CONFIG_SETENFORCE is not set +# CONFIG_SETFILES is not set +# CONFIG_FEATURE_SETFILES_CHECK_OPTION is not set +# CONFIG_SETSEBOOL is not set +# CONFIG_SESTATUS is not set + +# +# Shells +# +CONFIG_ASH=y +CONFIG_ASH_BASH_COMPAT=y +# CONFIG_ASH_IDLE_TIMEOUT is not set +CONFIG_ASH_JOB_CONTROL=y +CONFIG_ASH_ALIAS=y +CONFIG_ASH_GETOPTS=y +CONFIG_ASH_BUILTIN_ECHO=y +CONFIG_ASH_BUILTIN_PRINTF=y +CONFIG_ASH_BUILTIN_TEST=y +CONFIG_ASH_HELP=y +# CONFIG_ASH_CMDCMD is not set +# CONFIG_ASH_MAIL is not set +CONFIG_ASH_OPTIMIZE_FOR_SIZE=y +# CONFIG_ASH_RANDOM_SUPPORT is not set +CONFIG_ASH_EXPAND_PRMT=y +# CONFIG_CTTYHACK is not set +# CONFIG_HUSH is not set +# CONFIG_HUSH_BASH_COMPAT is not set +# CONFIG_HUSH_BRACE_EXPANSION is not set +# CONFIG_HUSH_HELP is not set +# CONFIG_HUSH_INTERACTIVE is not set +# CONFIG_HUSH_SAVEHISTORY is not set +# CONFIG_HUSH_JOB is not set +# CONFIG_HUSH_TICK is not set +# CONFIG_HUSH_IF is not set +# CONFIG_HUSH_LOOPS is not set +# CONFIG_HUSH_CASE is not set +# CONFIG_HUSH_FUNCTIONS is not set +# CONFIG_HUSH_LOCAL is not set +# CONFIG_HUSH_RANDOM_SUPPORT is not set +# CONFIG_HUSH_EXPORT_N is not set +# CONFIG_HUSH_MODE_X is not set +# CONFIG_MSH is not set +CONFIG_FEATURE_SH_IS_ASH=y +# CONFIG_FEATURE_SH_IS_HUSH is not set +# CONFIG_FEATURE_SH_IS_NONE is not set +# CONFIG_FEATURE_BASH_IS_ASH is not set +# CONFIG_FEATURE_BASH_IS_HUSH is not set +CONFIG_FEATURE_BASH_IS_NONE=y +CONFIG_SH_MATH_SUPPORT=y +# CONFIG_SH_MATH_SUPPORT_64 is not set +CONFIG_FEATURE_SH_EXTRA_QUIET=y +# CONFIG_FEATURE_SH_STANDALONE is not set +# CONFIG_FEATURE_SH_NOFORK is not set +CONFIG_FEATURE_SH_HISTFILESIZE=y + +# +# System Logging Utilities +# +CONFIG_SYSLOGD=y +CONFIG_FEATURE_ROTATE_LOGFILE=y +CONFIG_FEATURE_REMOTE_LOG=y +CONFIG_FEATURE_SYSLOGD_DUP=y +CONFIG_FEATURE_SYSLOGD_CFG=y +CONFIG_FEATURE_SYSLOGD_READ_BUFFER_SIZE=256 +CONFIG_FEATURE_IPC_SYSLOG=y +CONFIG_FEATURE_IPC_SYSLOG_BUFFER_SIZE=64 +CONFIG_LOGREAD=y +CONFIG_FEATURE_LOGREAD_REDUCED_LOCKING=y +CONFIG_FEATURE_KMSG_SYSLOG=y +CONFIG_KLOGD=y + +# +# klogd should not be used together with syslog to kernel printk buffer +# +CONFIG_FEATURE_KLOGD_KLOGCTL=y +CONFIG_LOGGER=y diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/fail_on_no_media.patch b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/fail_on_no_media.patch new file mode 100644 index 000000000..820acc268 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/fail_on_no_media.patch @@ -0,0 +1,32 @@ +Upstream-Status: Denied +[https://www.mail-archive.com/busybox@busybox.net/msg22354.html] + +The current behaviour of busybox is to try all fstype when automounting +even when no media exists. The util-linux mount command bails when no +media exists, so change the behaviour of busybox to do the same. + +It could also be argued that the KERN_INFO message from btrfs could be +removed, but that would be harder to accomplish. + +Signed-off-by: Saul Wold <sgw@linux.intel.com> + + +Index: busybox-1.20.2/util-linux/mount.c +=================================================================== +--- busybox-1.20.2.orig/util-linux/mount.c ++++ busybox-1.20.2/util-linux/mount.c +@@ -598,7 +598,13 @@ static int mount_it_now(struct mntent *m + break; + errno = errno_save; + } +- ++ /* ++ * Break if there is no media, no point retrying for all ++ * fs types since there is no media available ++ */ ++ if (rc == -1 && errno == ENOMEDIUM) { ++ bb_perror_msg_and_die("mounting %s on %s failed", mp->mnt_fsname, mp->mnt_dir); ++ } + if (!rc || (vfsflags & MS_RDONLY) || (errno != EACCES && errno != EROFS)) + break; + if (!(vfsflags & MS_SILENT)) diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/getopts.cfg b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/getopts.cfg new file mode 100644 index 000000000..8db0a4a8f --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/getopts.cfg @@ -0,0 +1,3 @@ +CONFIG_GETOPT=y +CONFIG_LONG_OPTS=y +CONFIG_FEATURE_GETOPT_LONG=y diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/init.cfg b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/init.cfg new file mode 100644 index 000000000..006d4c633 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/init.cfg @@ -0,0 +1,3 @@ +CONFIG_INIT=y +CONFIG_FEATURE_USE_INITTAB=y + diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/login-utilities.cfg b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/login-utilities.cfg new file mode 100644 index 000000000..cc9b2db50 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/login-utilities.cfg @@ -0,0 +1,13 @@ +CONFIG_FEATURE_SHADOWPASSWDS=y +CONFIG_ADDUSER=y +CONFIG_FEATURE_ADDUSER_LONG_OPTIONS=y +CONFIG_ADDGROUP=y +CONFIG_FEATURE_ADDGROUP_LONG_OPTIONS=y +CONFIG_DELUSER=y +CONFIG_DELGROUP=y +CONFIG_GETTY=y +CONFIG_LOGIN=y +CONFIG_PASSWD=y +CONFIG_SU=y +CONFIG_SULOGIN=y +CONFIG_VLOCK=y diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/mdev.cfg b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/mdev.cfg new file mode 100644 index 000000000..6aefe90e4 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/mdev.cfg @@ -0,0 +1,11 @@ +CONFIG_MDEV=y +CONFIG_FEATURE_MDEV_CONF=y +CONFIG_FEATURE_MDEV_RENAME=y +CONFIG_FEATURE_MDEV_RENAME_REGEXP=y +CONFIG_FEATURE_MDEV_EXEC=y +CONFIG_FEATURE_MDEV_LOAD_FIRMWARE=y + +CONFIG_SETSID=y +CONFIG_CTTYHACK=y + +CONFIG_FEATURE_SHADOWPASSWDS=y diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/mount-via-label.cfg b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/mount-via-label.cfg new file mode 100644 index 000000000..2fe7ab2e5 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/mount-via-label.cfg @@ -0,0 +1,9 @@ +CONFIG_BLKID=y +CONFIG_FEATURE_BLKID_TYPE=y +CONFIG_FEATURE_MOUNT_LABEL=y +CONFIG_VOLUMEID=y +CONFIG_FEATURE_VOLUMEID_BTRFS=y +CONFIG_FEATURE_VOLUMEID_EXT=y +CONFIG_FEATURE_VOLUMEID_F2FS=y +CONFIG_FEATURE_VOLUMEID_FAT=y +CONFIG_FEATURE_VOLUMEID_SQUASHFS=y diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/musl.cfg b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/musl.cfg new file mode 100644 index 000000000..facfe8544 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/musl.cfg @@ -0,0 +1,12 @@ +# CONFIG_EXTRA_COMPAT is not set +# CONFIG_SELINUX is not set +# CONFIG_FEATURE_HAVE_RPC is not set +# CONFIG_WERROR is not set +# CONFIG_FEATURE_SYSTEMD is not set +# CONFIG_FEATURE_VI_REGEX_SEARCH is not set +# CONFIG_PAM is not set +# CONFIG_FEATURE_INETD_RPC is not set +# CONFIG_SELINUXENABLED is not set +# CONFIG_FEATURE_MOUNT_NFS is not set +# CONFIG_FEATURE_UTMP is not set + diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/recognize_connmand.patch b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/recognize_connmand.patch new file mode 100644 index 000000000..f42c74caa --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/recognize_connmand.patch @@ -0,0 +1,21 @@ +This adds connmand to the list of know dhcp clients + +Upstream-Status: Inappropriate [OE-Core] + +Signed-off-by: Saul Wold <sgw@linux.intel.com> + +Index: busybox-1.22.1/networking/ifupdown.c +=================================================================== +--- busybox-1.22.1.orig/networking/ifupdown.c ++++ busybox-1.22.1/networking/ifupdown.c +@@ -521,6 +521,10 @@ struct dhcp_client_t { + }; + + static const struct dhcp_client_t ext_dhcp_clients[] = { ++ { "connmand", ++ "true", ++ "true", ++ }, + { "dhcpcd", + "dhcpcd[[ -h %hostname%]][[ -i %vendor%]][[ -I %client%]][[ -l %leasetime%]] %iface%", + "dhcpcd -k %iface%", diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/resize.cfg b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/resize.cfg new file mode 100644 index 000000000..a1d9c95b2 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/resize.cfg @@ -0,0 +1,2 @@ +CONFIG_RESIZE=y +CONFIG_FEATURE_RESIZE_PRINT=y diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/sha1sum.cfg b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/sha1sum.cfg new file mode 100644 index 000000000..20e72d926 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/sha1sum.cfg @@ -0,0 +1 @@ +CONFIG_SHA1SUM=y diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/sha256sum.cfg b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/sha256sum.cfg new file mode 100644 index 000000000..ce652ae4c --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox/sha256sum.cfg @@ -0,0 +1 @@ +CONFIG_SHA256SUM=y diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox_1.24.1.bb b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox_1.24.1.bb new file mode 100644 index 000000000..bdaa5a564 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox_1.24.1.bb @@ -0,0 +1,50 @@ +require busybox.inc + +SRC_URI = "http://www.busybox.net/downloads/busybox-${PV}.tar.bz2;name=tarball \ + file://busybox-udhcpc-no_deconfig.patch \ + file://find-touchscreen.sh \ + file://busybox-cron \ + file://busybox-httpd \ + file://busybox-udhcpd \ + file://default.script \ + file://simple.script \ + file://hwclock.sh \ + file://mount.busybox \ + file://syslog \ + file://syslog-startup.conf \ + file://syslog.conf \ + file://busybox-syslog.default \ + file://mdev \ + file://mdev.conf \ + file://mdev-mount.sh \ + file://umount.busybox \ + file://defconfig \ + file://busybox-syslog.service.in \ + file://busybox-klogd.service.in \ + file://fail_on_no_media.patch \ + file://run-ptest \ + file://inetd.conf \ + file://inetd \ + file://login-utilities.cfg \ + file://recognize_connmand.patch \ + file://busybox-cross-menuconfig.patch \ + file://0001-Use-CC-when-linking-instead-of-LD-and-use-CFLAGS-and.patch \ + file://busybox-1.24.1-unzip.patch \ + file://busybox-1.24.1-unzip-regression.patch \ + file://busybox-1.24.1-truncate-open-mode.patch \ + file://mount-via-label.cfg \ + file://sha1sum.cfg \ + file://sha256sum.cfg \ + file://getopts.cfg \ + file://resize.cfg \ + ${@["", "file://init.cfg"][(d.getVar('VIRTUAL-RUNTIME_init_manager', True) == 'busybox')]} \ + ${@["", "file://mdev.cfg"][(d.getVar('VIRTUAL-RUNTIME_dev_manager', True) == 'busybox-mdev')]} \ + file://inittab \ + file://rcS \ + file://rcK \ + file://runlevel \ +" +SRC_URI_append_libc-musl = " file://musl.cfg " + +SRC_URI[tarball.md5sum] = "be98a40cadf84ce2d6b05fa41a275c6a" +SRC_URI[tarball.sha256sum] = "37d03132cc078937360b392170b7a1d0e5b322eee9f57c0b82292a8b1f0afe3d" diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/busybox_git.bb b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox_git.bb new file mode 100644 index 000000000..c29b89434 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/busybox_git.bb @@ -0,0 +1,52 @@ +require busybox.inc + +SRCREV = "1b7c17391de66502dd7a97c866e0a33681edbb1f" +# Lookout for PV bump too when SRCREV is changed +PV = "1.25.0+git${SRCPV}" + +S = "${WORKDIR}/git" + +SRC_URI = "git://busybox.net/busybox.git \ + file://busybox-udhcpc-no_deconfig.patch \ + file://find-touchscreen.sh \ + file://busybox-cron \ + file://busybox-httpd \ + file://busybox-udhcpd \ + file://default.script \ + file://simple.script \ + file://hwclock.sh \ + file://mount.busybox \ + file://syslog \ + file://syslog-startup.conf \ + file://syslog.conf \ + file://busybox-syslog.default \ + file://mdev \ + file://mdev.conf \ + file://mdev-mount.sh \ + file://umount.busybox \ + file://defconfig \ + file://busybox-syslog.service.in \ + file://busybox-klogd.service.in \ + file://fail_on_no_media.patch \ + file://run-ptest \ + file://inetd.conf \ + file://inetd \ + file://login-utilities.cfg \ + file://recognize_connmand.patch \ + file://busybox-cross-menuconfig.patch \ + file://0001-Use-CC-when-linking-instead-of-LD-and-use-CFLAGS-and.patch \ + file://mount-via-label.cfg \ + file://sha1sum.cfg \ + file://sha256sum.cfg \ + file://getopts.cfg \ + file://resize.cfg \ + ${@["", "file://init.cfg"][(d.getVar('VIRTUAL-RUNTIME_init_manager', True) == 'busybox')]} \ + ${@["", "file://mdev.cfg"][(d.getVar('VIRTUAL-RUNTIME_dev_manager', True) == 'busybox-mdev')]} \ + file://inittab \ + file://rcS \ + file://rcK \ + file://runlevel \ +" +SRC_URI_append_libc-musl = " file://musl.cfg " + +DEFAULT_PREFERENCE = "-1" diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-cron b/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-cron new file mode 100755 index 000000000..f0e6b1562 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-cron @@ -0,0 +1,39 @@ +#!/bin/sh +DAEMON=/usr/sbin/crond +NAME=crond +DESC="Busybox Periodic Command Scheduler" +ARGS="-c /etc/cron/crontabs" + +test -f $DAEMON || exit 0 + +set -e + +case "$1" in + start) + echo -n "starting $DESC: $NAME... " + start-stop-daemon -S -b -n $NAME -a $DAEMON -- $ARGS + echo "done." + ;; + stop) + echo -n "stopping $DESC: $NAME... " + start-stop-daemon -K -n $NAME + echo "done." + ;; + restart) + echo -n "restarting $DESC: $NAME... " + $0 stop + $0 start + echo "done." + ;; + reload) + echo -n "reloading $DESC: $NAME... " + killall -HUP $(basename ${DAEMON}) + echo "done." + ;; + *) + echo "Usage: $0 {start|stop|restart|reload}" + exit 1 + ;; +esac + +exit 0 diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-httpd b/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-httpd new file mode 100755 index 000000000..c8348e54a --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-httpd @@ -0,0 +1,44 @@ +#!/bin/sh +DAEMON=/usr/sbin/httpd +NAME=httpd +DESC="Busybox HTTP Daemon" +HTTPROOT="/srv/www" +ARGS="-h $HTTPROOT" + +test -f $DAEMON || exit 0 + +set -e + +case "$1" in + start) + echo -n "starting $DESC: $NAME... " + if [ ! -d $HTTPROOT ]; then + echo "$HTTPROOT is missing." + exit 1 + fi + start-stop-daemon -S -b -n $NAME -a $DAEMON -- $ARGS + echo "done." + ;; + stop) + echo -n "stopping $DESC: $NAME... " + start-stop-daemon -K -n $NAME + echo "done." + ;; + restart) + echo "restarting $DESC: $NAME... " + $0 stop + $0 start + echo "done." + ;; + reload) + echo -n "reloading $DESC: $NAME... " + killall -HUP $(basename ${DAEMON}) + echo "done." + ;; + *) + echo "Usage: $0 {start|stop|restart|reload}" + exit 1 + ;; +esac + +exit 0 diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-klogd.service.in b/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-klogd.service.in new file mode 100644 index 000000000..d7c77558f --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-klogd.service.in @@ -0,0 +1,8 @@ +[Unit] +Description=Kernel Logging Service + +[Service] +ExecStart=@base_sbindir@/klogd -n + +[Install] +WantedBy=multi-user.target diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-syslog.default b/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-syslog.default new file mode 100644 index 000000000..e516caf51 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-syslog.default @@ -0,0 +1,25 @@ +OPTIONS="-C" +# The above option means syslogd will log to 16K shm circular buffer. +# You could use `logread' to read it. + +# All available options are: +# -O FILE : Log to FILE (default:/var/log/messages) +# -l N : Log only messages more urgent than prio N (1-8) +# -S : Smaller output +# -s SIZE : Max size (KB) before rotation (default:200KB, 0=off) +# -b N : N rotated logs to keep (default:1, max=99, 0=purge) +# -R HOST[:PORT]: Log to HOST:PORT (default PORT:514) +# -L : Log locally and via network +# -D : Drop duplicates +# -C[size_kb] : Log to shared mem buffer (use logread to read it) +# -f FILE : Use FILE as config (default:/etc/syslog.conf) +# -m MIN : Minutes between mark lines (default:20, 0=off) +# -K : Log to kernel printk buffer (use dmesg to read it) + +# Example 1: +# Log to local file /var/log/mylog +# OPTIONS="-O /var/log/mylog" +# +# Example 2: +# Log to remote host +# OPTIONS="-R 192.168.1.1:601" diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-syslog.service.in b/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-syslog.service.in new file mode 100644 index 000000000..2e0432138 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-syslog.service.in @@ -0,0 +1,13 @@ +[Unit] +Description=System Logging Service +Wants=busybox-klogd.service + +[Service] +EnvironmentFile=-/etc/default/busybox-syslog +ExecStart=@base_sbindir@/syslogd -n $OPTIONS +Sockets=syslog.socket + +[Install] +WantedBy=multi-user.target +Also=busybox-klogd.service +Alias=syslog.service diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-udhcpd b/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-udhcpd new file mode 100755 index 000000000..c43903e8d --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/busybox-udhcpd @@ -0,0 +1,43 @@ +#!/bin/sh +DAEMON=/usr/sbin/udhcpd +NAME=udhcpd +DESC="Busybox UDHCP Server" +ARGS="/etc/udhcpd.conf" + +test -f $DAEMON || exit 1 + +set -e + +case "$1" in + start) + echo -n "starting $DESC: $NAME... " + if [ ! -f /etc/udhcpd.conf ]; then + echo "error: /etc/udhcpd.conf is missing." + exit 1 + fi + /sbin/start-stop-daemon -S -b -n $NAME -a $DAEMON -- $ARGS + echo "done." + ;; + stop) + echo -n "stopping $DESC: $NAME... " + /sbin/start-stop-daemon -K -n $NAME + echo "done." + ;; + restart) + echo "restarting $DESC: $NAME... " + $0 stop + $0 start + echo "done." + ;; + reload) + echo -n "reloading $DESC: $NAME... " + killall -HUP $(basename ${DAEMON}) + echo "done." + ;; + *) + echo "Usage: $0 {start|stop|restart|reload}" + exit 1 + ;; +esac + +exit 0 diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/default.script b/import-layers/yocto-poky/meta/recipes-core/busybox/files/default.script new file mode 100644 index 000000000..f2ac987a2 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/default.script @@ -0,0 +1,4 @@ +#!/bin/sh + +exec run-parts -a "$1" /etc/udhcpc.d + diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/find-touchscreen.sh b/import-layers/yocto-poky/meta/recipes-core/busybox/files/find-touchscreen.sh new file mode 100644 index 000000000..52c5e7a09 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/find-touchscreen.sh @@ -0,0 +1,6 @@ +#!/bin/sh + +if grep -q "input:.*-e0.*,3,.*a0,1,\|ads7846" /sys/class/$MDEV/device/modalias ; then + ln -sf /dev/$MDEV /dev/input/touchscreen0 +fi + diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/hwclock.sh b/import-layers/yocto-poky/meta/recipes-core/busybox/files/hwclock.sh new file mode 100644 index 000000000..be5f94d86 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/hwclock.sh @@ -0,0 +1,83 @@ +#!/bin/sh +### BEGIN INIT INFO +# Provides: hwclock +# Required-Start: +# Required-Stop: $local_fs +# Default-Start: S +# Default-Stop: 0 6 +# Short-Description: Set system clock +# Description: Set system clock to hardware clock, according to the UTC +# setting in /etc/default/rcS (see also rcS(5)). +### END INIT INFO +# +# WARNING: If your hardware clock is not in UTC/GMT, this script +# must know the local time zone. This information is +# stored in /etc/localtime. This might be a problem if +# your /etc/localtime is a symlink to something in +# /usr/share/zoneinfo AND /usr isn't in the root +# partition! The workaround is to define TZ either +# in /etc/default/rcS, or in the proper place below. + +[ ! -x /sbin/hwclock ] && exit 0 + +[ -f /etc/default/rcS ] && . /etc/default/rcS + +[ "$UTC" = "yes" ] && tz="--utc" || tz="--localtime" +case "$1" in + start) + if [ "$VERBOSE" != no ] + then + echo "System time was `date`." + echo "Setting the System Clock using the Hardware Clock as reference..." + fi + + if [ "$HWCLOCKACCESS" != no ] + then + if [ -z "$TZ" ] + then + hwclock $tz --hctosys + else + TZ="$TZ" hwclock $tz --hctosys + fi + fi + + if [ "$VERBOSE" != no ] + then + echo "System Clock set. System local time is now `date`." + fi + ;; + stop|restart|reload|force-reload) + # + # Updates the Hardware Clock with the System Clock time. + # This will *override* any changes made to the Hardware Clock. + # + # WARNING: If you disable this, any changes to the system + # clock will not be carried across reboots. + # + if [ "$VERBOSE" != no ] + then + echo "Saving the System Clock time to the Hardware Clock..." + fi + if [ "$HWCLOCKACCESS" != no ] + then + hwclock $tz --systohc + fi + if [ "$VERBOSE" != no ] + then + echo "Hardware Clock updated to `date`." + fi + exit 0 + ;; + show) + if [ "$HWCLOCKACCESS" != no ] + then + hwclock $tz --show + fi + ;; + *) + echo "Usage: hwclock.sh {start|stop|show|reload|restart}" >&2 + echo " start sets kernel (system) clock from hardware (RTC) clock" >&2 + echo " stop and reload set hardware (RTC) clock from kernel (system) clock" >&2 + exit 1 + ;; +esac diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/inetd b/import-layers/yocto-poky/meta/recipes-core/busybox/files/inetd new file mode 100644 index 000000000..cf50bcd54 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/inetd @@ -0,0 +1,33 @@ +#!/bin/sh +# +# start/stop inetd super server. + +if ! [ -x /usr/sbin/inetd ]; then + exit 0 +fi + +case "$1" in + start) + echo -n "Starting internet superserver:" + echo -n " inetd" ; start-stop-daemon -S -x /usr/sbin/inetd > /dev/null + echo "." + ;; + stop) + echo -n "Stopping internet superserver:" + echo -n " inetd" ; start-stop-daemon -K -x /usr/sbin/inetd > /dev/null + echo "." + ;; + restart) + echo -n "Restarting internet superserver:" + echo -n " inetd " + killall -HUP inetd + echo "." + ;; + *) + echo "Usage: /etc/init.d/inetd {start|stop|restart}" + exit 1 + ;; +esac + +exit 0 + diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/inetd.conf b/import-layers/yocto-poky/meta/recipes-core/busybox/files/inetd.conf new file mode 100644 index 000000000..b02fe850c --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/inetd.conf @@ -0,0 +1,20 @@ +# /etc/inetd.conf: see inetd(8) for further informations. +# +# Internet server configuration database +# +# If you want to disable an entry so it isn't touched during +# package updates just comment it out with a single '#' character. +# +# <service_name> <sock_type> <proto> <flags> <user> <server_path> <args> +# +#:INTERNAL: Internal services +#echo stream tcp nowait root internal +#echo dgram udp wait root internal +#chargen stream tcp nowait root internal +#chargen dgram udp wait root internal +#discard stream tcp nowait root internal +#discard dgram udp wait root internal +#daytime stream tcp nowait root internal +#daytime dgram udp wait root internal +#time stream tcp nowait root internal +#time dgram udp wait root internal diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/inittab b/import-layers/yocto-poky/meta/recipes-core/busybox/files/inittab new file mode 100644 index 000000000..bfec4a774 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/inittab @@ -0,0 +1,24 @@ +# This is run first except when booting in single-user mode. + +# Startup the system +null::sysinit:/bin/mount -t proc proc /proc +null::sysinit:/bin/mount -t sysfs sysfs /sys +null::sysinit:/bin/mount -t devtmpfs devtmpfs /dev +null::sysinit:/bin/mount -o remount,rw / +null::sysinit:/bin/mkdir -p /dev/pts +null::sysinit:/bin/mount -t devpts devpts /dev/pts +null::sysinit:/bin/mount -a + +::sysinit:/etc/init.d/rcS + +# Stuff to do before rebooting +::ctrlaltdel:/sbin/reboot +::shutdown:/etc/init.d/rcK +::shutdown:/sbin/swapoff -a +::shutdown:/bin/umount -a -r + +# Stuff to do when restarting the init process +::restart:/sbin/init + +# set hostname +null::sysinit:/bin/busybox hostname -F /etc/hostname diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/mdev b/import-layers/yocto-poky/meta/recipes-core/busybox/files/mdev new file mode 100755 index 000000000..96252477e --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/mdev @@ -0,0 +1,19 @@ +#!/bin/sh + +mount -t tmpfs tmpfs /dev -o size=64k,mode=0755 +mkdir /dev/pts /dev/shm +chmod 777 /dev/shm +mount -t devpts devpts /dev/pts +touch /dev/mdev.seq +echo "/sbin/mdev" > /proc/sys/kernel/hotplug +mdev -s + +# +# We might have mounted something over /dev, see if /dev/initctl is there. +# +if test ! -p /dev/initctl +then + rm -f /dev/initctl + mknod -m 600 /dev/initctl p +fi + diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/mdev-mount.sh b/import-layers/yocto-poky/meta/recipes-core/busybox/files/mdev-mount.sh new file mode 100644 index 000000000..b4385a157 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/mdev-mount.sh @@ -0,0 +1,63 @@ +#!/bin/sh +MDEV_AUTOMOUNT=y +MDEV_AUTOMOUNT_ROOT=/run/media +[ -f /etc/default/mdev ] && . /etc/default/mdev +if [ "${MDEV_AUTOMOUNT}" = "n" ] ; then + exit 0 +fi + +case "$ACTION" in + add|"") + ACTION="add" + # check if already mounted + if grep -q "^/dev/${MDEV} " /proc/mounts ; then + # Already mounted + exit 0 + fi + DEVBASE=`expr substr $MDEV 1 3` + if [ "${DEVBASE}" = "mmc" ] ; then + DEVBASE=`expr substr $MDEV 1 7` + fi + # check for "please don't mount it" file + if [ -f "/dev/nomount.${DEVBASE}" ] ; then + # blocked + exit 0 + fi + # check for full-disk partition + if [ "${DEVBASE}" = "${MDEV}" ] ; then + if [ -d /sys/block/${DEVBASE}/${DEVBASE}*1 ] ; then + # Partition detected, just quit + exit 0 + fi + if [ ! -f /sys/block/${DEVBASE}/size ] ; then + # No size at all + exit 0 + fi + if [ "`cat /sys/block/${DEVBASE}/size`" = "0" ] ; then + # empty device, bail out + exit 0 + fi + fi + # first allow fstab to determine the mountpoint + if ! mount /dev/$MDEV > /dev/null 2>&1 + then + MOUNTPOINT="${MDEV_AUTOMOUNT_ROOT}/$MDEV" + mkdir -p "$MOUNTPOINT" + mount -t auto /dev/$MDEV "$MOUNTPOINT" + fi + ;; + remove) + MOUNTPOINT=`grep "^/dev/$MDEV\s" /proc/mounts | cut -d' ' -f 2` + if [ ! -z "$MOUNTPOINT" ] + then + umount "$MOUNTPOINT" + rmdir "$MOUNTPOINT" + else + umount /dev/$MDEV + fi + ;; + *) + # Unexpected keyword + exit 1 + ;; +esac diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/mdev.conf b/import-layers/yocto-poky/meta/recipes-core/busybox/files/mdev.conf new file mode 100644 index 000000000..17e93da7c --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/mdev.conf @@ -0,0 +1,42 @@ +$MODALIAS=.* 0:0 660 @modprobe "$MODALIAS" + +console 0:0 0600 +cpu_dma_latency 0:0 0660 +fb0:0 44 0660 +full 0:0 0666 +initctl 0:0 0600 +ircomm[0-9].* 0:20 0660 +kmem 0:15 0640 +kmsg 0:0 0660 +log 0:0 0666 +loop[0-9].* 0:6 0640 +mem 0:15 0640 +network_latency 0:0 0660 +network_throughput 0:0 0660 +null 0:0 0666 +port 0:15 0640 +ptmx 0:5 0666 +ram[0-9].* 0:6 0640 +random 0:0 0666 +sda 0:6 0640 +tty 0:5 0666 +tty.* 0:0 0620 +urandom 0:0 0666 +usbdev.* 0:0 0660 */etc/mdev/usb.sh +vcs.* 0:5 0660 +zero 0:0 0666 + +snd/pcm.* 0:0 0660 +snd/control.* 0:0 0660 +snd/timer 0:0 0660 +snd/seq 0:0 0660 +snd/mini.* 0:00 0660 + +input/event.* 0:0 0660 @/etc/mdev/find-touchscreen.sh +input/mice 0:0 0660 +input/mouse.* 0:0 0660 + +tun[0-9]* 0:0 0660 =net/ + +[hs]d[a-z][0-9]? 0:0 660 */etc/mdev/mdev-mount.sh +mmcblk[0-9].* 0:0 660 */etc/mdev/mdev-mount.sh diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/mount.busybox b/import-layers/yocto-poky/meta/recipes-core/busybox/files/mount.busybox new file mode 100755 index 000000000..fef945b7b --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/mount.busybox @@ -0,0 +1,3 @@ +#!/bin/sh + +exec /bin/busybox mount $@ diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/rcK b/import-layers/yocto-poky/meta/recipes-core/busybox/files/rcK new file mode 100644 index 000000000..f8a63e132 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/rcK @@ -0,0 +1,26 @@ +#!/bin/sh + +# Stop all init scripts in /etc/rc6.d +# executing them in numerical order. +# +for i in /etc/rc6.d/K??*; do + + # Ignore dangling symlinks (if any). + [ ! -f "$i" ] && continue + + case "$i" in + *.sh) + # Source shell script for speed. + ( + trap - INT QUIT TSTP + set stop + . $i + ) + ;; + *) + # No sh extension, so fork subprocess. + $i stop + ;; + esac +done + diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/rcS b/import-layers/yocto-poky/meta/recipes-core/busybox/files/rcS new file mode 100644 index 000000000..bb03eb608 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/rcS @@ -0,0 +1,27 @@ +#!/bin/sh + +# Start all init scripts in /etc/rcS.d and /etc/rc5.d +# executing them in numerical order. +# + +for i in /etc/rcS.d/S??* /etc/rc5.d/S??* ;do + + # Ignore dangling symlinks (if any). + [ ! -f "$i" ] && continue + + case "$i" in + *.sh) + # Source shell script for speed. + ( + trap - INT QUIT TSTP + set start + . $i + ) + ;; + *) + # No sh extension, so fork subprocess. + $i start + ;; + esac +done + diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/run-ptest b/import-layers/yocto-poky/meta/recipes-core/busybox/files/run-ptest new file mode 100644 index 000000000..3608a8eb6 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/run-ptest @@ -0,0 +1,7 @@ +#!/bin/sh + +current_dir=$(readlink -f $0) +export bindir=$(dirname $current_dir) + +cd testsuite || exit 1 +./runtest -v | sed -r 's/^(SKIPPED|UNTESTED):/SKIP:/' diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/runlevel b/import-layers/yocto-poky/meta/recipes-core/busybox/files/runlevel new file mode 100644 index 000000000..866f3b594 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/runlevel @@ -0,0 +1,11 @@ +#!/bin/sh +# busybox init does not have LSB ( sysvinit ) like initlevels +# so lets fake it to 5 which is what we default anyway +# this helps with opkg post installs where it tries to invoke +# update-rc.d ad post install step. +# for package upgrades +# See code in update-rc.d around line 190 where it calls runlevel +# program +# +echo "5" + diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/simple.script b/import-layers/yocto-poky/meta/recipes-core/busybox/files/simple.script new file mode 100644 index 000000000..6ed029352 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/simple.script @@ -0,0 +1,88 @@ +#!/bin/sh + +# udhcpc script edited by Tim Riker <Tim@Rikers.org> + +[ -z "$1" ] && echo "Error: should be called from udhcpc" && exit 1 + +RESOLV_CONF="/etc/resolv.conf" +[ -n "$subnet" ] && NETMASK="netmask $subnet" + +# return 0 if root is mounted on a network filesystem +root_is_nfs() { + sed -n 's/^[^ ]* \([^ ]*\) \([^ ]*\) .*$/\1 \2/p' /proc/mounts | + grep -q "^/ \(nfs\|smbfs\|ncp\|coda\)$" +} + +have_bin_ip=0 +if [ -x /SBIN_DIR/ip ]; then + have_bin_ip=1 + BROADCAST="broadcast +" +fi + +[ -n "$broadcast" ] && BROADCAST="broadcast $broadcast" + +case "$1" in + deconfig) + if [ -x /SBIN_DIR/resolvconf ]; then + /SBIN_DIR/resolvconf -d "${interface}.udhcpc" + fi + if ! root_is_nfs ; then + if [ $have_bin_ip -eq 1 ]; then + /SBIN_DIR/ip addr flush dev $interface + /SBIN_DIR/ip link set dev $interface up + else + /SBIN_DIR/ifconfig $interface 0.0.0.0 + fi + fi + ;; + + renew|bound) + if [ $have_bin_ip -eq 1 ]; then + /SBIN_DIR/ip addr add dev $interface local $ip/$mask $BROADCAST + else + /SBIN_DIR/ifconfig $interface $ip $BROADCAST $NETMASK + fi + + if [ -n "$router" ] ; then + if ! root_is_nfs ; then + if [ $have_bin_ip -eq 1 ]; then + while /SBIN_DIR/ip route del default dev $interface 2>/dev/null ; do + : + done + else + while /SBIN_DIR/route del default gw 0.0.0.0 dev $interface 2>/dev/null ; do + : + done + fi + fi + + metric=10 + for i in $router ; do + if [ $have_bin_ip -eq 1 ]; then + /SBIN_DIR/ip route add default via $i metric $metric + else + /SBIN_DIR/route add default gw $i dev $interface metric $metric 2>/dev/null + fi + metric=$(($metric + 1)) + done + fi + + # Update resolver configuration file + R="" + [ -n "$domain" ] && R="domain $domain +" + for i in $dns; do + echo "$0: Adding DNS $i" + R="${R}nameserver $i +" + done + + if [ -x /SBIN_DIR/resolvconf ]; then + echo -n "$R" | /SBIN_DIR/resolvconf -a "${interface}.udhcpc" + else + echo -n "$R" > "$RESOLV_CONF" + fi + ;; +esac + +exit 0 diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/syslog b/import-layers/yocto-poky/meta/recipes-core/busybox/files/syslog new file mode 100644 index 000000000..89c4d12e9 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/syslog @@ -0,0 +1,77 @@ +#! /bin/sh +### BEGIN INIT INFO +# Provides: sysklogd +# Required-Start: $remote_fs $time +# Required-Stop: $remote_fs $time +# Default-Start: 2 3 4 5 +# Default-Stop: 0 1 6 +# Short-Description: System logger +### END INIT INFO + +set -e + +if [ -f /etc/syslog-startup.conf ]; then + . /etc/syslog-startup.conf + LOG_LOCAL=0 + LOG_REMOTE=0 + for D in $DESTINATION; do + if [ "$D" = "buffer" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -C$BUFFERSIZE" + LOG_LOCAL=1 + elif [ "$D" = "file" ]; then + if [ -n "$LOGFILE" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -O $LOGFILE" + fi + if [ -n "$ROTATESIZE" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -s $ROTATESIZE" + fi + if [ -n "$ROTATEGENS" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -b $ROTATEGENS" + fi + LOG_LOCAL=1 + elif [ "$D" = "remote" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -R $REMOTE" + LOG_REMOTE=1 + fi + done + if [ "$LOG_LOCAL" = "1" -a "$LOG_REMOTE" = "1" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -L" + fi + if [ "$REDUCE" = "yes" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -S" + fi + if [ "$DROPDUPLICATES" = "yes" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -D" + fi + if [ -n "$LOGLEVEL" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -l $LOGLEVEL" + fi +else + # default: log to 16K shm circular buffer + SYSLOG_ARGS="-C" +fi + +case "$1" in + start) + echo -n "Starting syslogd/klogd: " + start-stop-daemon -S -b -n syslogd -a /sbin/syslogd -- -n $SYSLOG_ARGS + start-stop-daemon -S -b -n klogd -a /sbin/klogd -- -n + echo "done" + ;; + stop) + echo -n "Stopping syslogd/klogd: " + start-stop-daemon -K -n syslogd + start-stop-daemon -K -n klogd + echo "done" + ;; + restart) + $0 stop + $0 start + ;; + *) + echo "Usage: syslog { start | stop | restart }" >&2 + exit 1 + ;; +esac + +exit 0 diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/syslog-startup.conf b/import-layers/yocto-poky/meta/recipes-core/busybox/files/syslog-startup.conf new file mode 100644 index 000000000..fda450aa0 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/syslog-startup.conf @@ -0,0 +1,13 @@ +# This configuration file is used by the busybox syslog init script, +# /etc/init.d/syslog[.busybox] to set syslog configuration at start time. + +DESTINATION=file # log destinations (buffer file remote) +LOGFILE=/var/log/messages # where to log (file) +REMOTE=loghost:514 # where to log (syslog remote) +REDUCE=no # reduce-size logging +DROPDUPLICATES=no # whether to drop duplicate log entries +#ROTATESIZE=0 # rotate log if grown beyond X [kByte] +#ROTATEGENS=3 # keep X generations of rotated logs +BUFFERSIZE=64 # size of circular buffer [kByte] +FOREGROUND=no # run in foreground (don't use!) +#LOGLEVEL=5 # local log level (between 1 and 8) diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/syslog.conf b/import-layers/yocto-poky/meta/recipes-core/busybox/files/syslog.conf new file mode 100644 index 000000000..75bb6309a --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/syslog.conf @@ -0,0 +1 @@ +# /etc/syslog.conf Configuration file for busybox's syslogd utility diff --git a/import-layers/yocto-poky/meta/recipes-core/busybox/files/umount.busybox b/import-layers/yocto-poky/meta/recipes-core/busybox/files/umount.busybox new file mode 100755 index 000000000..f3731626e --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-core/busybox/files/umount.busybox @@ -0,0 +1,3 @@ +#!/bin/sh + +exec /bin/busybox umount $@ |