wok-6.x view v4l-dvb/receipt @ rev 5648
mirror-tools: may use local hg copy
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sat May 29 13:32:42 2010 +0200 (2010-05-29) |
parents | 3f8e04bc567f |
children | 782eb7d921f3 |
line source
1 # SliTaz package receipt.
3 PACKAGE="v4l-dvb"
4 VERSION="development"
5 CATEGORY="multimedia"
6 MAINTAINER="jozee@slitaz.org"
7 SHORT_DESC="v4l-dvb development repository"
8 DEPENDS=""
9 BUILD_DEPENDS="python mercurial coreutils-operations"
10 WEB_SITE="http://linuxtv.org/hg/v4l-dvb/"
11 TAGS="webcam"
13 # Rules to configure and make the package.
14 compile_rules() {
15 TARBALL=$SOURCES_REPOSITORY/$PACKAGE-hg-$VERSION.tar.gz
16 if [ -d $PACKAGE-$VERSION ]; then
17 true
18 elif [ -f $TARBALL ]; then
19 tar xzf $TARBALL
20 else
21 hg clone $WEB_SITE $PACKAGE-$VERSION &&
22 tar czf $TARBALL $PACKAGE-$VERSION
23 fi
24 cd $src
25 sed -i 's/0 | xargs -0n 255 ln -sf --target-directory=\./ | while read file; do ln -sf $file . ; done/' v4l/Makefile
26 grep -rl /sbin/depmod * | xargs sed -i 's|/sbin/depmod|/bin/echo|'
27 sed -i 's|/sbin/lsmod|/bin/lsmod|' v4l/Makefile
28 KERNEL_VERSION=`grep ^VERSION= $WOK/linux/receipt | cut -d "=" -f2 | sed -e 's/"//g'`
29 IFS="." ; set -- $KERNEL_VERSION ; unset IFS
30 cat > v4l/.version << EOF
31 VERSION=$1
32 PATCHLEVEL:=$2
33 SUBLEVEL:=$3
34 KERNELRELEASE:=$KERNEL_VERSION-slitaz
35 EOF
36 make SRCDIR="$WOK/linux/linux-$KERNEL_VERSION" CONFIG_MEDIA_TUNER_CUSTOMISE=n CONFIG_RADIO_ADAPTERS=n CONFIG_RADIO_MIROPCM20=n CONFIG_MANTIS_CORE=n
37 make DESTDIR="$PWD/_pkg" install
38 }
40 # Rules to gen a SliTaz package suitable for Tazpkg.
41 genpkg_rules()
42 {
43 KERNEL_VERSION=`grep ^VERSION= $WOK/linux/receipt | cut -d "=" -f2 | sed -e 's/"//g'`
44 EXTRAVERSION=_$KERNEL_VERSION
46 mkdir -p $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/
48 find $_pkg/lib/modules/$KERNEL_VERSION-slitaz -name "*.ko" -exec lzma e '{}' '{}'.gz \; 2> /dev/null
49 find $_pkg/lib/modules/$KERNEL_VERSION-slitaz -name "*.ko" -exec rm '{}' \;
50 cp -a $_pkg/lib/modules/$KERNEL_VERSION-slitaz/kernel/drivers $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/
51 }
53 post_install()
54 {
55 echo "Processing post-install commands..."
56 chroot "$1/" depmod -a ${EXTRAVERSION#_}-slitaz
57 }
59 post_remove()
60 {
61 echo "Processing post-remove commands..."
62 depmod -a
63 }