From 87679199819b7b1ba7fb1ed880ae390a424570ed Mon Sep 17 00:00:00 2001 From: Arne Coucheron Date: Thu, 24 Feb 2011 06:03:54 +0100 Subject: [PATCH] click: Use custom script to handle compcache There's no zram support in kernel 2.6.29, and after the system-wide script got changed to handle zram, it broke handling of compcache, resulting in allocating way too much memory for swap. Change-Id: Iaf36c96cb1a7207ff5887ed784b99ae5b31bb9f0 --- click.mk | 1 + custom/handle_compcache | 31 +++++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 custom/handle_compcache diff --git a/click.mk b/click.mk index 0d5e144..5adf80d 100644 --- a/click.mk +++ b/click.mk @@ -69,6 +69,7 @@ PRODUCT_COPY_FILES += \ # precompiled files for /system/bin PRODUCT_COPY_FILES += \ device/htc/click/custom/compcache:system/bin/compcache \ + device/htc/click/custom/handle_compcache:system/bin/handle_compcache \ device/htc/click/custom/rzscontrol:system/bin/rzscontrol # Backup-Tool for install diff --git a/custom/handle_compcache b/custom/handle_compcache new file mode 100644 index 0000000..44ab0b7 --- /dev/null +++ b/custom/handle_compcache @@ -0,0 +1,31 @@ +#!/system/bin/sh +# +# Compcache handler +# Decides whether or not Compcache is enabled +# +MEMTOTAL=$( awk '{ if ($1 eq "MemTotal:") print $2 ;exit }'