diff options
author | Waldemar Brodkorb <wbx@openadk.org> | 2015-03-07 09:16:52 +0100 |
---|---|---|
committer | Waldemar Brodkorb <wbx@openadk.org> | 2015-03-07 09:16:52 +0100 |
commit | 2e8dfd38c5a575dab56c52f36fee51f345b20518 (patch) | |
tree | 99b9ffa77090605e625bf781d9456ebed232ca9f /package | |
parent | 444a1474b8aaac4807514ae526d52a473f66b998 (diff) |
disable mallopt calls, some uClibc configurations doesn't work well with it.
Diffstat (limited to 'package')
-rw-r--r-- | package/busybox/Makefile | 2 | ||||
-rw-r--r-- | package/busybox/patches/011-remove-non-posix-mallopt.patch | 39 |
2 files changed, 40 insertions, 1 deletions
diff --git a/package/busybox/Makefile b/package/busybox/Makefile index 088a29397..83f29985e 100644 --- a/package/busybox/Makefile +++ b/package/busybox/Makefile @@ -5,7 +5,7 @@ include $(ADK_TOPDIR)/rules.mk PKG_NAME:= busybox PKG_VERSION:= 1.23.0 -PKG_RELEASE:= 2 +PKG_RELEASE:= 3 PKG_HASH:= 483ab594dd962ddbb332fd24e36ffdd6e36ac2182fbff055c56e1ca49fda09e4 PKG_DESCR:= core utilities for embedded systems PKG_SECTION:= base/apps diff --git a/package/busybox/patches/011-remove-non-posix-mallopt.patch b/package/busybox/patches/011-remove-non-posix-mallopt.patch new file mode 100644 index 000000000..e18a25d2f --- /dev/null +++ b/package/busybox/patches/011-remove-non-posix-mallopt.patch @@ -0,0 +1,39 @@ +diff -Nur busybox-1.23.0.orig/libbb/appletlib.c busybox-1.23.0/libbb/appletlib.c +--- busybox-1.23.0.orig/libbb/appletlib.c 2014-11-20 01:08:23.000000000 +0100 ++++ busybox-1.23.0/libbb/appletlib.c 2015-03-07 09:10:56.000000000 +0100 +@@ -28,13 +28,6 @@ + */ + #include "busybox.h" + +-#if !(defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) \ +- || defined(__APPLE__) \ +- ) +-# include <malloc.h> /* for mallopt */ +-#endif +- +- + /* Declare <applet>_main() */ + #define PROTOTYPES + #include "applets.h" +@@ -792,21 +785,6 @@ + int main(int argc UNUSED_PARAM, char **argv) + #endif + { +- /* Tweak malloc for reduced memory consumption */ +-#ifdef M_TRIM_THRESHOLD +- /* M_TRIM_THRESHOLD is the maximum amount of freed top-most memory +- * to keep before releasing to the OS +- * Default is way too big: 256k +- */ +- mallopt(M_TRIM_THRESHOLD, 8 * 1024); +-#endif +-#ifdef M_MMAP_THRESHOLD +- /* M_MMAP_THRESHOLD is the request size threshold for using mmap() +- * Default is too big: 256k +- */ +- mallopt(M_MMAP_THRESHOLD, 32 * 1024 - 256); +-#endif +- + #if !BB_MMU + /* NOMMU re-exec trick sets high-order bit in first byte of name */ + if (argv[0][0] & 0x80) { |