wok-next view compcache/receipt @ rev 6079
Up putty (0.60-2010-08-29)
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sun Aug 29 09:30:16 2010 +0200 (2010-08-29) |
parents | 5716a37ccf43 |
children | d6292cae5538 |
line source
1 # SliTaz package receipt.
3 PACKAGE="compcache"
4 VERSION="0.6.2"
5 CATEGORY="system-tools"
6 SHORT_DESC="Compressed caching"
7 MAINTAINER="fabrice.thiroux@free.fr"
8 TARBALL="$PACKAGE-$VERSION.tar.gz"
9 WEB_SITE="http://code.google.com/p/compcache/"
10 WGET_URL="http://compcache.googlecode.com/files/$TARBALL"
11 DEPENDS="linux"
12 BUILD_DEPENDS="lzma"
14 # Rules to configure and make the package.
15 compile_rules()
16 {
18 KERNEL_VERSION=`grep ^VERSION= $WOK/linux/receipt | cut -d "=" -f2 | sed -e 's/"//g'`
19 if [ ! -d $WOK/linux/linux-$KERNEL_VERSION ]; then
20 tazwok cook linux
21 fi
22 cd $src
24 # Fix build with kernel 2.6.34
25 patch -p1 < ../stuff/compcache-0.6.2-linux-2.6.34.u || exit 1
27 find -name Makefile | xargs sed -i \
28 "s|/lib/modules/\$(shell uname -r)/build|$WOK/linux/linux-$KERNEL_VERSION|"
29 make KBUILD=$WOK/linux/linux-$KERNEL_VERSION KVER=$KERNEL_VERSION
30 }
32 # Rules to gen a SliTaz package suitable for Tazpkg.
33 genpkg_rules()
34 {
35 KERNEL_VERSION=`grep ^VERSION= $WOK/linux/receipt | cut -d "=" -f2 | sed -e 's/"//g'`
36 EXTRAVERSION=_$KERNEL_VERSION
38 mkdir -p $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/misc \
39 $fs/etc/init.d \
40 $fs/usr/bin
42 install -o root -m 644 $src/ramzswap.ko $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/misc
43 cp -a $src/sub-projects/rzscontrol/rzscontrol $fs/usr/bin
45 for i in $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/misc/*.ko ; do
46 lzma e $i $i.gz && rm -f $i
47 done
48 install -o root -m 755 ./stuff/compcache $fs/etc/init.d/
49 install -o root -m 644 ./stuff/compcache.conf $fs/etc/
50 }
52 post_install()
53 {
54 echo "Processing post-install commands..."
55 chroot "$1/" depmod -a ${EXTRAVERSION#_}-slitaz
56 }
58 post_remove()
59 {
60 echo "Processing post-remove commands..."
61 depmod -a
62 }