wok-next view linmodem-agrsm/receipt @ rev 10246

Up: bazaar to 2.3.1.
author Christopher Rogers <slaxemulator@gmail.com>
date Sat May 21 02:01:43 2011 +0000 (2011-05-21)
parents fbe92309d288
children 58ded5428ea5
line source
1 # SliTaz package receipt.
3 PACKAGE="linmodem-agrsm"
4 SOURCE="agrsm-11c11040"
5 VERSION="2.1.80~20091225"
6 CATEGORY="network"
7 MAINTAINER="jozee@slitaz.org"
8 SHORT_DESC="Agere Modem Drivers for 11c11040 chipsets"
9 BUILD_DEPENDS="linux lzma"
10 WEB_SITE="http://linmodems.technion.ac.il/packages/ltmodem/11c11040"
11 TARBALL="$SOURCE-$VERSION.tar.bz2"
12 WGET_URL="$WEB_SITE/$TARBALL"
13 TAGS=""
15 # Rules to configure and make the package.
17 compile_rules() {
19 KERNEL_VERSION=`grep ^VERSION= $WOK/linux/receipt | cut -d "=" -f2 | sed -e 's/"//g'`
20 [ -d $WOK/linux/taz ] || tazwok cook linux
21 cd $src
22 sed -i -e 's/\([^_]\)usb_buffer_free/\1usb_free_coherent/' \
23 -e 's/\([^_]\)usb_buffer_alloc/\1usb_alloc_coherent/' agrsoftmodem.c
24 make KERNEL_DIR=$WOK/linux/linux-$KERNEL_VERSION KRELEASE=$KERNEL_VERSION
26 }
28 # Rules to gen a SliTaz package suitable for Tazpkg.
29 genpkg_rules()
30 {
31 KERNEL_VERSION=`grep ^VERSION= $WOK/linux/receipt | cut -d "=" -f2 | sed -e 's/"//g'`
32 EXTRAVERSION=_$KERNEL_VERSION
34 mkdir -p $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/drivers/net
36 # Compress and install module
37 lzma e $src/agrmodem.ko $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/drivers/net/agrmodem.ko.gz
38 lzma e $src/agrserial.ko $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/drivers/net/agrserial.ko.gz
39 chown root $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/drivers/net/agrmodem.ko.gz
40 chmod 0644 $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/drivers/net/agrmodem.ko.gz
41 chown root $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/drivers/net/agrserial.ko.gz
42 chmod 0644 $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/drivers/net/agrserial.ko.gz
43 }
45 post_install()
46 {
47 echo "Processing post-install commands..."
48 chroot "$1/" depmod -a ${EXTRAVERSION#_}-slitaz
49 }
51 post_remove()
52 {
53 echo "Processing post-remove commands..."
54 depmod -a
55 }