wok-next annotate zaptel/receipt @ rev 1187
Add bristuff
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Mon Aug 04 13:34:35 2008 +0000 (2008-08-04) |
parents | |
children | b4764dbfcef8 |
rev | line source |
---|---|
pascal@1187 | 1 # SliTaz package receipt. |
pascal@1187 | 2 |
pascal@1187 | 3 PACKAGE="zaptel" |
pascal@1187 | 4 VERSION= |
pascal@1187 | 5 CATEGORY="system" |
pascal@1187 | 6 SHORT_DESC="Zapata Telephony Interface Driver." |
pascal@1187 | 7 MAINTAINER="pascal.bellard@slitaz.org" |
pascal@1187 | 8 WEB_SITE="http://www.digium.com/" |
pascal@1187 | 9 WANTED="bristuff" |
pascal@1187 | 10 CONFIG_FILES="/etc/zaptel.conf" |
pascal@1187 | 11 |
pascal@1187 | 12 # Extract VERSION from WANTED package source |
pascal@1187 | 13 get_version() |
pascal@1187 | 14 { |
pascal@1187 | 15 eval $(grep ^ZAP_VER= $WOK/$WANTED/$WANTED-*/download.sh) |
pascal@1187 | 16 VERSION=$ZAP_VER |
pascal@1187 | 17 } |
pascal@1187 | 18 |
pascal@1187 | 19 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@1187 | 20 genpkg_rules() |
pascal@1187 | 21 { |
pascal@1187 | 22 if [ -d taz/$PACKAGE-/fs ]; then |
pascal@1187 | 23 get_version |
pascal@1187 | 24 sed -i "s/^VERSION=.*/VERSION=\"$VERSION\"/" receipt |
pascal@1187 | 25 mv taz/$PACKAGE- taz/$PACKAGE-$VERSION |
pascal@1187 | 26 fi |
pascal@1187 | 27 kver=$(grep "kernel version" ../linux/linux-*/.config) |
pascal@1187 | 28 kver=${kver##* } |
pascal@1187 | 29 EXTRAVERSION=_$kver |
pascal@1187 | 30 _pkg=$(cd $(dirname $src)/$WANTED-*/_pkg ; pwd) |
pascal@1187 | 31 while read file; do |
pascal@1187 | 32 dir=$(dirname $file) |
pascal@1187 | 33 [ -d $fs$dir ] || mkdir -p $fs$dir |
pascal@1187 | 34 eval cp -a "$_pkg$file" $fs$dir |
pascal@1187 | 35 done < $_pkg/../$PACKAGE.files-list |
pascal@1187 | 36 rm -f $fs/lib/modules/*/modules.* |
pascal@1187 | 37 } |
pascal@1187 | 38 |
pascal@1187 | 39 # Post install/remove commands for Tazpkg. |
pascal@1187 | 40 post_install() |
pascal@1187 | 41 { |
pascal@1187 | 42 depmod -a -b "$1/" |
pascal@1187 | 43 } |
pascal@1187 | 44 |
pascal@1187 | 45 post_remove() |
pascal@1187 | 46 { |
pascal@1187 | 47 depmod -a |
pascal@1187 | 48 } |
pascal@1187 | 49 |