The merge_config.sh in kernel-tools-native uses "trap" syntax that isn't POSIX compliant, so when running under dash this produces an error, which means busybox won't configure. In tracing this I discovered that copy of this tool in the kernel was fix in late 2012 by a certain Darren Hart. The changes in the kernel should probably be backported to the yocto-kernel-tools repository as we've had two reports of Ubuntu users with sh->dash failing to build busybox.
I'll take this. I maintain the kern-tools, and already started fixing this yesterday.
Thanks, please backport the patch to 1.4 (and maybe 1.3) so people using Ubuntu 10.04 can use it without problems. I had some customers complaining about it.
I'll send the changes to the stable branches for testing. There are a few patches we carry for extra functionality used by the kernel fragment processing (which I'll send upstream for the next kernel cycle), so it's not a completely straight backport. Do we have any issues reported on 1.3 ? We only started using merge_config.sh for busybox in 1.4: > git tag --contains 56dc1720caa48344238d352c7b6e9b0f0d41aa54 1.4_M4.final 1.4_M4.rc1 1.4_M5.final 1.4_M5.rc1 1.4_M5.rc2 1.4_M5.rc3 1.4_M6.rc1 dylan-9.0.0 So I'll start with 1.4 and see if we get a tangible issue reported in 1.3. Merging it back further increases the risk, and testing .. so I'll take the cautious route and wait on it.
Agreed, every report of this I've seen was against master or 1.4 - 1.3 is safe from the busybox aspect at least.
But it is a risk as it is used by linux-yocto recipe in 1.3 so if it has same issue there it'd be better to port the fix for it as well.
Remember merge_config.sh is in the mainline kernel, let's do this properly and fix upstream first. I actually tested this on bash and dash when I wrote it.... hrm, not sure where the gap was here.
Upstream commit shows this is indeed tested on dash. How is this failing for people? Is it just that we haven't pulled in the upstream signal name fix? $ git show 041b78c commit 041b78c89b1fe68f44c45e8b6cc6c9f8ea8f0e4c Author: Darren Hart <dvhart@linux.intel.com> Date: Tue Jan 10 15:41:10 2012 -0800 merge_config.sh: use signal names compatible with dash and bash The SIGHUP SIGINT and SIGTERM names caused failures when running merge_config.sh with the dash shell. Dropping the "SIG" component makes the script work in both bash and dash. Signed-off-by: Darren Hart <dvhart@linux.intel.com> Acked-by: John Stultz <john.stultz@linaro.org> Cc: Michal Marek <mmarek@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Michal Marek <mmarek@suse.cz> diff --git a/scripts/kconfig/merge_config.sh b/scripts/kconfig/merge_config.sh index 890276b..b91015d 100644 --- a/scripts/kconfig/merge_config.sh +++ b/scripts/kconfig/merge_config.sh @@ -24,7 +24,7 @@ clean_up() { rm -f $TMP_FILE exit } -trap clean_up SIGHUP SIGINT SIGTERM +trap clean_up HUP INT TERM usage() { echo "Usage: $0 [OPTIONS] [CONFIG [...]]"
Darren: that's what I meant, I'll just pick up the mainline fixes, there's nothing I need to fix, just backports. My changes will go upstream as well, but they aren't the problem. I need to have it out of tree for now, for two reasons: busybox can't depend on the kernel, and we don't want duplicate code. I'll just make sure that I'm always trolling for the few fixes and get them into kern-tools. Our packaging is like the kconfig-frontends, where it is pulled out and packaged for other needs.
changes have been ported and local changes rebased. testing busy box and kernel for use case regressions.
Changes are done and pushed to the kern-tools repo. busybox and 3.8/3.4 kernel tested against master and 1.4. Changes will be sent tomorrow, with 1.3 changes to follow.
Fix has been merged into master: http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=f259554b4e91eecbb009622a64e43c5619aedb92 and also dylan (for 1.4.1): http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?h=dylan&id=3faa5039c8147d0bf9e352dc5ad1e9e12cf2086a For danny the merge is still pending AFAICT.