]> code.ossystems Code Review - openembedded-core.git/commitdiff
bash: Disable custom memory allocator
authorAníbal Limón <anibal.limon@linux.intel.com>
Fri, 9 Oct 2015 22:21:44 +0000 (17:21 -0500)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 12 Oct 2015 13:35:42 +0000 (14:35 +0100)
Bash is failing trying to allocate memory [1] using the custom
memory allocator if we disable it the issue is fixed.

The major distributions also disabled by default [2], so we
don't have a good reason to use it.

The underlying issue is due to bash’s malloc using brk() calls
to allocate memory, which fail when address randomization is
enabled in kernel. sbrk() based custom allocators are obsolete.
There may be some performance impact of this however correctness
is more important.

[YOCTO #8452]

[1] https://bugzilla.yoctoproject.org/show_bug.cgi?id=8452#c0
[2] https://bugzilla.yoctoproject.org/show_bug.cgi?id=8452#c5

Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
meta/recipes-extended/bash/bash.inc

index c06f157b8a68d508d17af98258df6d2f8dfd4ad8..020409fb6dc900b27dd876189e0c385c91a0407c 100644 (file)
@@ -7,7 +7,7 @@ DEPENDS = "ncurses bison-native"
 inherit autotools gettext texinfo update-alternatives ptest
 
 EXTRA_AUTORECONF += "--exclude=autoheader"
-EXTRA_OECONF = "--enable-job-control"
+EXTRA_OECONF = "--enable-job-control --without-bash-malloc"
 
 # If NON_INTERACTIVE_LOGIN_SHELLS is defined, all login shells read the
 # startup files, even if they are not interactive.