Commit Graph

108 Commits

Author SHA1 Message Date
Jackie Huang 94025c05b5 busybox: fix sed auto insert newline testcase
backport the patch from busybox upstream to fix the
auto insert newline issue.

busybox defect:
https://bugs.busybox.net/show_bug.cgi?id=6584

(From OE-Core master rev: db00fa405c025c61844df2e9589fe635fc5df0e2)

(From OE-Core rev: 9266343cc00fefd3e7f33fa2e6b0da88b6abf622)

Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-12-12 17:00:14 +00:00
Saul Wold a253acca45 busybox: Add depmod (adds 2240 bytes)
This will allow packages that update kernel modules to run correctly

(From OE-Core master rev: 72c23255cc88b5e2cd6f783231e6f42bf5190df7)

(From OE-Core rev: bce32a41c7e700f49aaa0aacbeb6c83d91a8b255)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-12-12 16:59:54 +00:00
Eric Bénard 5454f92e57 busybox: update mdev.conf
busybox 1.21.1 's mdev has changed the way the device's name is
reported so now we get input/event0 instead of event0.
I think this commit is responsible of this new behaviour :
http://git.busybox.net/busybox/commit/util-linux/mdev.c?id=c3cf1e30a3022453311a7e9fe11d94c7a381640e

Update mdev.conf according to this behaviour so that sound
and input devices are correctly populated (and now
/etc/mdev/find-touchscreen.sh is executed).

Tested on an arm board.

(From OE-Core rev: 61b2950ebbc01f5e4fd7aece05bf371100c0c390)

Signed-off-by: Eric Bénard <eric@eukrea.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-26 16:37:56 +01:00
Hongxu Jia 44c65db250 busybox: move su to /bin for lsb command check test
In busybox, util-linux and shadow, su has been moved to /usr/bin/,
but lsb cmdchk needs su in /bin.

Move su to /bin could fix this issue.

[YOCTO#5175]

(From OE-Core rev: daff19fe6f0490dc7036602e8b0ca40a23b55556)

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-17 19:34:54 +01:00
Chen Qi 101662d357 busybox-syslog: add configuration file /etc/syslog.conf
By default, busybox has CONFIG_FEATURE_SYSLOGD_CFG enabled, but it
doesn't ship a configuration file.

This patch adds a configuration file (/etc/syslog.conf) to the
busybox-syslog package. This configuration file mainly serves as a
placeholder now.

The advantages of this change are:
1. Make the users aware of the fact that the /etc/syslog.conf file
   will actually be parsed by busybox's syslogd utility. And configuring
   that file will change the logging behaviour.
2. In a systemd based system, this file will prevent the same configuration
   file provided by the sysklogd package from messing things up.

[YOCTO #5066]

(From OE-Core rev: b7f6688f0700a1575037362af7a8ca94dccce471)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-06 23:03:21 +01:00
Chen Qi abfe9af9e5 busybox: configure system user id to range from 100 to 999
Previously, the range was 0 to 0. This made it impossible to use
busybox's adduser utility to add a system user. The following error
would appear.

      adduser: no uids left

This patch fixes this problem by giving it a reasonable range.

(From OE-Core rev: c4555007d04ccacbc192827b70a97f9a48500a22)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-30 16:23:46 +01:00
Paul Eggleton 3095ee5154 busybox: set default log buffer size to 64 at compile time
This provides a more reasonable log buffer size to avoid losing earlier
events, and 64K is not a problem for modern systems. When the buffer is
used on sysvinit-based systems, which it isn't by default, 64K is already
the runtime default size unless /etc/syslog-startup.conf is modified or
deleted, so this only really affects systems using systemd. This
completely removes the need for the busybox bbappend in meta-oe.

(From OE-Core rev: 6d6a3f805b0fad6f904afb52dc12bfb543e3eec5)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-30 16:23:43 +01:00
Paul Eggleton b18b210c1e busybox: enable shared memory logging for systemd
The default command-line options for launching busybox's syslogd are
"-C" if using sysvinit; but because we use /etc/default/busybox-syslog
when using systemd which the sysvinit initscript doesn't use, and no
/etc/default/busybox-syslog is installed by default in OE-Core, the
default arguments with systemd were no arguments at all with OE-Core
alone. Effectively merge in the bbappend from meta-oe that adds a
default file in order to set the default options to "-C" for systemd as
well.

(From OE-Core rev: a23aa8e7467cf2b7f4e8ff85a3aa841ff6b508e5)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:19 +01:00
Florin Sarbu 02521a40d3 busybox.inc: Avoid error when SYSLOG is not enabled
Add -f to rm of ${D}${sysconfdir}/syslog-startup.conf.${BPN} so as to
not error out when the busybox config used does not have SYSLOG enabled
and DISTRO_FEATURES does not contain sysvinit.

(From OE-Core rev: 4c5756149754d0b18b14595db335f8f5e14cc0a3)

Signed-off-by: Florin Sarbu <florin.sarbu@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-22 15:11:13 +01:00
Chen Qi 86d8d89c21 busybox: remove syslog-startup.conf if sysvinit not in DISTRO_FEATURES
sysvinit and systemd have different ideas about configuration files (or
environment files in systemd), so basically we can't use the same one in
both cases.

To avoid confusion, this patch removes syslog-startup.conf if 'sysvinit'
is not in DISTRO_FEATURES.

[YOCTO #4837]
[YOCTO #4860]

(From OE-Core rev: 89f62147a61108b4be40001e1fbe3be33bacf00b)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-12 13:09:52 +01:00
Hongxu Jia 16ce101c3f busybox: move /bin/su to /usr/bin/su to match util-linux and shadow
Both of util-linux and shadow have su binary in /usr/bin, fix busybox
to use the same path so they can be properly tracked by alternatives.

[YOCTO #4926]

(From OE-Core rev: e01735756a76d27b724b9e7829f78e8a335c1f60)

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-07-31 06:59:58 +01:00
Muhammad Shakeel fe378e1d46 busybox: Add syslog-init alternative only if SysV in enabled
If systemd is enabled then syslog is handled through a service file
and related files in /etc/init.d are removed. This removes following
warning:

WARNING: busybox: NOT adding alternative provide /etc/init.d/syslog:
/etc/init.d/syslog.busybox does not exist

(From OE-Core rev: 29c3ecee32d9bfb03099a4f10456fd0270e107fb)

Signed-off-by: Muhammad Shakeel <muhammad_shakeel@mentor.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-07-31 06:59:56 +01:00
Mark Hatle e9b5ef1c20 busybox: fix ip reference in simple.script
The ip is being installed into /sbin as of the latest busybox.

(From OE-Core rev: 222ae6001db286d66462c6334f7f054ca727b7be)

Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-07-18 21:23:42 +01:00
Chen Qi 131e5e7e8f busybox: upgrade to stable 1.21.1
Merged or backported patches are dropped.
The wget_dl_dir_fix.patch was submitted more than 1 year ago, it's
about the -P option behavior, and it's not accepted, so I dropped
this patch too.

(From OE-Core rev: a2f31a6a6accb8eee2084cb39edb8e9af4b4189f)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-07-05 15:44:13 +01:00
Chen Qi cb53421428 busybox: fix the on-target upgrade problem
We now can have a 'one-binary' version of busybox, or 'two-binary'
version of busybox, controlled by the 'BUSYBOX_SPLIT_SUID' variable.
This makes on-target upgrade a problem, as we have to support the
following four upgrading paths.

For convenience, in the following context, A is used to denote a
'two-binary' version of busybox while B is used to denote a 'one-binary'
version of busybox.

A --(upgrade)--> B
B --(upgrade)--> A
A --(upgrade)--> A
B --(upgrade)--> B

This patch makes effort to support the above four situations.

[YOCTO #4802]

(From OE-Core rev: 4e571e97750f3ac6a62cd0d2d10c08be98230630)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-07-05 15:34:21 +01:00
Björn Stenberg 67d95bffa9 busybox: Add ptest
Install busybox test suite and run it as ptest.

(From OE-Core rev: 0d29dc5b5f7742df60fdba90835ef77425963bde)

Signed-off-by: Anders Roxell <anders.roxell@enea.com>
Signed-off-by: Björn Stenberg <bjst@enea.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-06-25 17:44:58 +01:00
Chen Qi 680ff5552d busybox: add the ability to split the busybox binary
This patch enables us to split the busybox into two binaries, one
containing suid applications, and the other containing nosuid apps.

Add a variable, BUSYBOX_SPLIT_SUID, to control whether to split the
busybox binary into two parts. We default it to "1" to enable the
splitting, but users could still override it to disable the splitting.
After all, busybox has no internal support for this suid apps splitting,
so there might be users out there who want just one busybox binary.

The basic idea here is to build the busybox twice, each with the correct
configuration items. We extract the non-app part of the original .config
file, and merge this part with the suid-app part to form a .config which
contains only suid apps. The same strategy applies to the non-suid apps.

[YOCTO #4207]

(From OE-Core rev: e5a1442819dfb74e86a6f69da008ba6908c8bbc7)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-06-25 17:44:52 +01:00
Chen Qi 72d5bbe59e busybox: enable to list suid and non-suid app configs
This patch, written by Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>,
adds the ability to busybox to list configuration items of suid apps
and non-suid apps separately.

`make busybox.cfg.suid' generates a file containing config items of the
suid apps.

'make busybox.cfg.nosuid' generates a file containing config items of
the non-suid apps.

This patch helps to separate busybox into two binaries, the suid one and
the non-suid one.

[YOCTO #4207]

(From OE-Core rev: 832d1b5575c76f61623f2e0337554287d056422b)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-06-25 17:44:52 +01:00
Chen Qi 3d230db5c4 busybox: add a config fragment to enable login utilities
Create a config fragment to enable the login/passwd utilities of busybox.

[YOCTO #4207]

(From OE-Core rev: 2a37490d4d55a1a6e4c4d268231a9d8904d38f8b)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-06-25 17:44:51 +01:00
Chen Qi 726483741a busybox: add support for CONFIG_FEATURE_INDIVIDUAL
Previously, if CONFIG_FEATURE_INDIVIDUAL was enabled for busybox,
yocto-based systems could start correctly.

This is because if busybox is built as individual apps, '/bin/busybox'
may not be present, so setting the default ALTERNATIVE_TARGET to
'/bin/busybox' is not appropriate and could lead to errors.

This patch fixes this problem by checking the existence of '/bin/busybox'
before setting the ALTERNATIVE_TARGET to '/bin/busybox'.

After this change, if busybox is built as individual apps, we'll have
links like '/bin/ls -> /bin/ls.busybox', otherwise, we'll have links
like '/bin/ls -> /bin/busybox'.

Note there's a grep expression change in this patch. The old expression
doesn't work well, it has an unwanted underscore, so I changed it to make
it work.

[YOCTO #4570]

(From OE-Core rev: 87efa83191f0b4f4cec3a821b6dfe425c781c077)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-06-25 17:44:51 +01:00
Chen Qi 6984890b2e busybox: remove the postinst part of the recipe
Remove the pkg_postinst_${PN} from this recipe, as it's redundant.
It basically wants to do the same thing as the update-alternatives
does. But it doesn't do it well.

(From OE-Core rev: 5b961afc784747eb8240540e542a789849118596)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-06-25 17:44:51 +01:00
Jonathan Liu 4380876084 busybox: backport sulogin empty root password fix
This allows system maintenance login if the root password is empty.

(From OE-Core rev: 28bb8fe5c144e02c28bff54b5b81c8da33b9f58b)

Signed-off-by: Jonathan Liu <net147@gmail.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-05-24 14:14:46 +01:00
Mike Looijmans 39537e01a5 busybox-mdev: Startup at level S03 instead of S06
The udev hotplug deamon starts at 03, so mdev should start at the same
point.

This fixes the bug that when modutils (runs at 04) initializes devices
that the mdev hotplug will often not pick them up, resulting in missing
device nodes and similar problems.

(From OE-Core rev: 18d3e5eb9102a984d00837f8fec16fda522c511a)

Signed-off-by: Mike Looijmans <mike.looijmans@topic.nl>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-05-16 00:09:49 +03:00
Richard Purdie 566628d8cd class/lib: Fix up various file access methods
There are various bits of cruft that have built up around our file accesses. This patch
cleans some of them up, specifically:

 * Remove pointless "from __builtin__ import file"
 * Use open(), not file()
 * Wrap file usage in a with container to ensure files are closed
 * Add missing .close() calls in some cases

(From OE-Core rev: a43e0a8ecd0441131e929daf998c3cd454d9c8f3)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-05-09 22:28:04 +01:00
Ross Burton 09b89187b8 busybox: hard-code the syslog service file
Previously this was using ${PN}-syslog.service, which changes with multilib.

(From OE-Core rev: ee36f997e68f5a995baf361191cef7a46ff51203)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-04-18 00:37:58 +01:00
Laurentiu Palcu ef0e1cc32d busybox: fix mount issue
When the mount command is not given the filesystem type to mount, then
it will try all the known filesystems. However, when a filesystem is not
supported by the kernel, the mount function call will return ENODEV.

The following patch, ecd90bc6aa,
introduced a problem because it bailed out on ENODEV too. Instead it should
have only bailed out on ENOMEDIUM.

[YOCTO #4308]

(From OE-Core rev: 82320d2074572477f26887eddc51dc2a1dfea403)

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-04-18 00:37:57 +01:00
Ting Liu aa1d7fa9ce busybox: Add inetd related files
Add back inetd and inetd.conf files which are needed if
CONFIG_INETD is enabled in the defconfig. Grabbed these
files from oe-classic

This patch is based on the previous patch for denzil:
http://patches.openembedded.org/patch/33235/

(From OE-Core rev: 929c738787b6f513ce235ed5f7753408a570d632)

Signed-off-by: Ting Liu <b28495@freescale.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-04-15 15:57:30 +01:00
Ting Liu fc30d72a73 busybox: detects customized configs when do_install
After using 'bitbake -c menuconfig busybox' to customize defconfig,
do_install fail to detect the changes. Grep configs in ${B}/.config
instead of ${WORKDIR}/defconfig.

(From OE-Core rev: 5c088c2d3b23026752649d077ee44fe3dbe26aa4)

Signed-off-by: Ting Liu <b28495@freescale.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-04-15 15:57:30 +01:00
Saul Wold ecd90bc6aa busybox: fail on no media
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.

(From OE-Core rev: e5403f55a1e9b1747535450fd95f499c85211771)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-04-10 12:56:52 +01:00
Ross Burton ce10e5f34a busybox: order and group initscript variables logically
(From OE-Core rev: 94acb39385a14d54503db08351a717449e2d4b50)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-26 22:43:04 +00:00
Ross Burton c2aab97e96 busybox: add strictatime support to mount
systemd uses strictatime when mounting tmpfs.  Luckily this is already supported
upstream, so backport the patch from git.

(From OE-Core rev: 7379a5a2035ef670329551783c372d9310ddd983)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-26 22:43:02 +00:00
Radu Moisan 58a6a7c056 busybox: enable systemd integration for syslogd
(From OE-Core rev: cf3618f9a57e46fb78d5be35d473e2dd5290e961)

Signed-off-by: Radu Moisan <radu.moisan@intel.com>
Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-26 22:43:01 +00:00
Ross Burton 03e13d8d6d busybox: enable swapon -p (91 byte increase)
systemd needs "swapon -p", so as the impact is minimal enable it unversally.

(From OE-Core rev: acc5e9b4f43a382e56c0af1fae492cd0aaa80230)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-15 01:53:03 +00:00
Chen Qi b1c887277c hwclock.sh: check for the existence of /etc/default/rcS
/etc/default/rcS might be missing if the init manager is not sysvinit.
So we have to check for the existence of this file before sourcing it.

[YOCTO #3697]

(From OE-Core rev: 416519ec595f59ebeafb95bed2546635cad41559)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-22 06:09:22 -08:00
Chen Qi 56dc1720ca busybox: add config fragments
Add config fragments to busybox.

The implementation makes use of merge_config.sh script in kern-tools-native.
The use case is similar to the yocto kernel's configuration fragments.

We also add kern-tools-native to busybox's DEPENDS variable to ensure
that merge_config.sh is available when required.

[YOCTO #3379]

(From OE-Core rev: bbcd8b344598850ea2c8d3ad375c519713581fde)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-13 16:52:31 +00:00
Kang Kai 8f63fefa56 busybox: update test case du-k-works
busybox test case du-k-work fails on ext3/4 image whose size less than
512M. Add patch testsuite-du-du-k-works-fix-false-positive.patch to fix
it and it has been merged by upstream.

[Yocto 2896]

(From OE-Core rev: ffe4f8a859d5e71e3e33363d61f0470a32c48d66)

(From OE-Core rev: 19eb2971c6e8c4a2847897919ec7a2cd9b1697b1)

Signed-off-by: Kang Kai <kai.kang@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-01 15:54:29 +00:00
Chen Qi 7f6edde6af hwclock.sh: improve hwclock.sh script to use UTC variable
Make UTC variable in /etc/default/rcS has effect on hwclock.sh.
This variable declares whether the Hardware Clock is kept in UTC
or local time. Default its value to "yes" and change the comment.

[YOCTO #3341]

(From OE-Core rev: 2bda4bbda3f3033cfb324778ef88f2aedad4a83b)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-11-02 16:18:30 +00:00
Andy Ross 2e24eb2cb7 busybox: add /usr/bin/stat applet
The busybox defconfig lacks a stat tool, the functionality of which
cannot be reproduced in a way accessible to a shell script running in
a minimal configuration.  Enable, and modify the installation path to
/usr/bin/stat to match the coreutils tool for proper alternatives
handling.

(From OE-Core rev: ef7e1239b95dbef4e461007d6d0612c27a7919ec)

Signed-off-by: Andy Ross <andy.ross@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-10-27 09:47:07 +01:00
Elizabeth Flanagan 094c4a0878 bzip2 and busybox: Incorrect LICENSE
The license for bzip2 is not quite BSD. I have an email out to the
maintainer to see if we can utilize a common BSD license (or something
else) however, for now, we should revert bzip2 back to a special
license.

As busybox also utilizes a lightly modified bzip2, this also
effects busybox.

(From OE-Core rev: a0b132798d2c1adf79414787b8317327a554f852)

Signed-off-by: Elizabeth Flanagan <elizabeth.flanagan@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-10-03 10:04:08 +01:00
Richard Purdie c63ff82422 busybox: Add missing INITSCRIPT_NAME_${PN}-hwclock
Fix failures like:

Configuring busybox-hwclock.
usage: update-rc.d [-n] [-f] [-r <root>] <basename> remove
       update-rc.d [-n] [-r <root>] [-s] <basename> defaults [NN | sNN kNN]
       update-rc.d [-n] [-r <root>] [-s] <basename> start|stop NN runlvl [runlvl] [...] .
                -n: not really
                -f: force
                -v: verbose
                -r: alternate root path (default is /)
                -s: invoke start methods if appropriate to current runlevel
Collected errors:
 * pkg_run_script: package "busybox-hwclock" postinst script returned status 1.
 * opkg_configure: busybox-hwclock.postinst returned 1.

(From OE-Core rev: 43b4ffc11874803db37c43b521ce27c51c677c8b)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-10-02 17:27:49 +01:00
Richard Purdie 0b09e50810 busybox: Fix misplaced quote
(From OE-Core rev: 938d07871bedd91f0d95ed6fe338ecbfafa5ebfe)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-09-26 18:28:36 +01:00
Radu Moisan 6b641bbbec busybox: Add sign-off-by and upstream-status
(From OE-Core rev: 30354f7270365be7534f37481fc3d365a419048c)

Signed-off-by: Radu Moisan <radu.moisan@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-09-04 14:08:35 +01:00
Radu Moisan d48585caf9 busybox: Upgrade to upstream 1.20.2
Updated defconfig file from generated .config
Disabled CONFIG_LSOF,CONFIG_CROSS_COMPILER_PREFIX, and CONFIG_EXTRA_CFLAGS
for backwards compatibility.
Added busybox-1.20.2-kernel_ver.patch from upstream.

(From OE-Core rev: e5f2cc805509a23e160c6f05e6776d6d32e3ce98)

Signed-off-by: Radu Moisan <radu.moisan@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-08-23 11:43:34 +01:00
Andrei Gherzan be141470dc busybox: Package hwclock.sh initscript separately
We package this separately to be able to pull this in only if this makes
sense for the MACHINE.

(From OE-Core rev: b97e37e1444ef32e7837dcc79e3fad36c4284b65)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-08-17 18:04:25 +01:00
Roy.Li ba218e743b busybox: fix du-k-works test case
[YOCTO #2896]

The du-k-works test seems to assume that du -k on a directory with two files
totaling 80 kilobytes should report either 80k or 88k. In ext4 filesystm however,
both busybox' du -k and coreutils' du -k reports a size of 84k which causes the
test to fail.

Intergrate the patch from:
http://git.busybox.net/busybox/commit/?id=a5ee090e8651692545514a81a16c6cde3a2dc577

(From OE-Core rev: a022fb6b69388f28f3130e71125b64e4c154d504)

Signed-off-by: Roy.Li <rongqing.li@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-08-06 15:18:45 +01:00
Jesse Zhang a4b1e34848 busybox: udhcpc shouldn't be a service
udhcpc is invoked from the networking service, so it shouldn't exist
standalone. If /etc/init.d/busybox-udhcpc is present, it will cause
udhcpc to be started two times.

And since the script doesn't support the stop action, it will cause
udhcpc to be started even when system is being shutdown.

Remove /etc/init.d/busybox-udhcpc to resolve the issues.

[YOCTO #2840]

(From OE-Core rev: 8329c4679ec0ce319d2a81d755a0da5b05474688)

Signed-off-by: Jesse Zhang <sen.zhang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-08-02 15:35:57 +01:00
Roy.Li 2ccbf35ed1 busybox:udhcpc: fix the root_is_nfs() function
[YOCTO #2788]

The system will be hung when udhcpc starts, if nfs is mounted
at "/" directory and default route is different after starting
udhcpc.

The cause is that root_is_nfs() does not work after kernel-2.6.37,
since the device name has been changed from /dev/root to
${IPADDR}:${NFSDIR} on /proc/mounts. which leads to remove
the default routes to nfs server,

Now we use a loose match to check if rootfs is nfs.

(From OE-Core rev: 9921cb0104ea36daf909c110bb6767e5fd307da0)

Signed-off-by: Roy.Li <rongqing.li@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-07-26 14:40:49 +01:00
Yao Zhao 30c618a3f5 busybox: fix the problem that mkfs.minix.tests fails on big endian platform
patch mkfs.minix.tests to have correct md5sum on big endian platform.

(From OE-Core rev: b37e1ea5f29d03efbe136ee7f4fa261a1936ac8f)

Signed-off-by: Yao Zhao <yao.zhao@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-07-26 14:40:48 +01:00
Amy Fong 23df8e0a06 busybox: busybox wget -P option ignored
busybox wget testing fails

In cases where busybox wget is invoked with -P <...> and the url ends
in "/", the download directory is ignored (ie the file index.html is
implied), this change enables the -P option for those urls.

(From OE-Core rev: 95fd02de0aee0a1907b51f9ccda260d483e6e292)

Signed-off-by: Amy Fong <amy.fong@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-07-19 17:18:11 +01:00
Richard Purdie bfd279de32 Convert tab indentation in python functions into four-space
(From OE-Core rev: 604d46c686d06d62d5a07b9c7f4fa170f99307d8)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-07-19 10:24:50 +01:00