wok-next view linux-zram/receipt @ rev 19595

Up linux (4.9.4)
author Aleksej Bobylev <al.bobylev@gmail.com>
date Sat Jan 21 17:27:31 2017 +0200 (2017-01-21)
parents 119e586fb823
children
line source
1 # SliTaz package receipt.
3 PACKAGE="linux-zram"
4 VERSION="4.9.4"
5 CATEGORY="base-system"
6 SHORT_DESC="The Linux Kernel compressed caching support"
7 MAINTAINER="devel@slitaz.org"
8 LICENSE="GPL2"
9 WEB_SITE="https://www.kernel.org/"
10 CONFIG_FILES="/etc/compcache.conf"
11 PROVIDE="compcache"
13 WANTED="linux"
14 DEPENDS="linux"
16 # Rules to gen a SliTaz package suitable for Tazpkg.
17 genpkg_rules()
18 {
19 . $wanted_stuff/tools/copy_modules.sh
21 mkdir -p $fs/etc/init.d
22 install -o root -m 755 $stuff/compcache $fs/etc/init.d/
23 install -o root -m 644 $stuff/compcache.conf $fs/etc/
24 }
26 # Post install/remove commands for Tazpkg.
27 post_install()
28 {
29 chroot "$1/" depmod -a $VERSION-slitaz &&
30 RAM=$(cat /proc/meminfo | grep MemTotal | sed s/[^0-9]//g) &&
31 echo "SIZE_KB="$(($RAM/2)) > /etc/compcache.conf
32 [ -z "$quiet" ] && cat <<EOT
34 You can add compressed swap according /etc/compcache.conf configuration with:
35 # /etc/init.d/compcache start
36 Or add compcache to the RUN_DAEMONS list of /etc/rcS.conf.
37 EOT
38 }